You are here

function hostmaster_task_import in Hostmaster (Aegir) 5.x

File

./hostmaster.forms.inc, line 280

Code

function hostmaster_task_import() {
  drupal_set_title(st('Import your existing sites'));
  $form = array();
  $sites = hosting_get_sites_by_status(HOSTING_OWN_PLATFORM, HOSTING_SITE_IMPORTED);
  if ($list = hosting_site_list('platform', HOSTING_OWN_PLATFORM)) {
    $form['intro']['#value'] = t('<p>Below is a list of sites which were imported into the Hosting framework. Each of these pre-existing sites have had an import task created for them, and will be imported by the task queue.</p>');
    $form['list']['#value'] = $list;
  }
  else {
    $form['intro']['#value'] = t('<p>Hosting has not found any sites to import.</p>') . t('<p>In the future, any additional platforms you create will also automatically have existing sites imported, and at any time you can request an verify task on any existing platform to find and import any sites that may have been added manually.</p>');
  }
  return hostmaster_form($form);
}