function tripal_featuremap_admin

2.x tripal_featuremap.admin.inc tripal_featuremap_admin()
3.x tripal_featuremap.admin.inc tripal_featuremap_admin()
1.x tripal_featuremap.admin.inc tripal_featuremap_admin()

Administrative settings form

Related topics

1 string reference to 'tripal_featuremap_admin'
tripal_featuremap_menu in legacy/tripal_featuremap/tripal_featuremap.module
Implements hook_menu().

File

legacy/tripal_featuremap/includes/tripal_featuremap.admin.inc, line 47
Administration of feature maps

Code

function tripal_featuremap_admin() {
  $form = array();

  // If your module is using the Chado Node: Title & Path API to allow custom titles
  // for your node type then you need to add the configuration form for this functionality.
  $details = array(
    'module' => 'tripal_featuremap', // the name of the MODULE implementing the content type
    'content_type' => 'chado_featuremap', // the name of the content type
    // An array of options to use under "Page Titles"
    // the key should be the token and the value should be the human-readable option
    'options' => array(
      // there should always be one options matching the unique constraint.
      '[featuremap.name]' => 'Unique Contraint: The name of the map'
    ),
    // the token indicating the unique constraint in the options array
    'unique_option' => '[featuremap.name]'
  );
  // This call adds the configuration form to your current form
  // This sub-form handles it's own validation & submit
  chado_add_admin_form_set_title($form, $form_state, $details);

  // URL ALIAS
  $details = array(
    'module' => 'tripal_featuremap',
    'content_type' => 'chado_featuremap',
    'options' => array(
      '/featuremap/[featuremap.featuremap_id]' => 'Feature Map ID',
      '/featuremap/[featuremap.name]' => 'Unique Contraint: The name of the Feature Map'
    ),
  );

  // This call adds the configuration form to your current form
  // This sub-form handles it's own validation & submit
  chado_add_admin_form_set_url($form, $form_state, $details);

  return system_settings_form($form);
}