function get_tripal_analysis_admin_form_reindex_set
1.x tripal_analysis.admin.inc | get_tripal_analysis_admin_form_reindex_set(&$form) |
The "Reindex Analysis Nodes" form
Parameters
$form: The administrative form as it is currently
Return value
A form API array describing an administrative form
Related topics
File
- tripal_analysis/
includes/ tripal_analysis.admin.inc, line 148 - Contains functions displaying administrative pages and forms
Code
function get_tripal_analysis_admin_form_reindex_set(&$form) {
// define the fieldsets
$form['reindex'] = array(
'#type' => 'fieldset',
'#title' => t('Reindex Analysis Features')
);
// get the list of libraries
$sql = "SELECT * FROM {analysis} ORDER BY name";
$lib_rset = chado_query($sql);
// iterate through all of the libraries
$lib_boxes = array();
while ($analysis = db_fetch_object($lib_rset)) {
$lib_boxes[$analysis->analysis_id] = "$analysis->name";
}
$form['reindex']['description'] = array(
'#type' => 'item',
'#value' => t("This option allows for reindexing of only those features that belong to the selected analyses below. All other features will be unaffected. To reindex all features in the site see the Feature Administration page."),
'#weight' => 1,
);
$form['reindex']['re-analyses'] = array(
'#title' => t('Libraries'),
'#type' => t('checkboxes'),
'#description' => t("Check the analyses whoee features you want to reindex. Note: this list contains all analyses, even those that may not be synced."),
'#required' => FALSE,
'#prefix' => '<div id="lib_boxes">',
'#suffix' => '</div>',
'#options' => $lib_boxes,
'#weight' => 2,
);
$form['reindex']['re-button'] = array(
'#type' => 'submit',
'#value' => t('Reindex Features'),
'#weight' => 3,
);
}