function forena_fields_form_submit in Forena Reports 7.3
Same name and namespace in other branches
- 6.2 forena.admin.inc \forena_fields_form_submit()
- 6 forena.admin.inc \forena_fields_form_submit()
- 7 forena.admin.inc \forena_fields_form_submit()
- 7.2 forena.admin.inc \forena_fields_form_submit()
File
- ./
forena.admin.inc, line 1420
Code
function forena_fields_form_submit($form, &$form_state) {
$values = $form_state['values'];
$name = $values['report_name'];
$r = forena_get_report_editor($name);
/*now build the fields*/
$fields = $values['fields'];
$r
->setFields($fields);
if (forena_save_report($name, $r
->asXML(), TRUE) == 1) {
drupal_set_message(t('Your report, %s has been saved.', array(
'%s' => $name,
)));
}
else {
drupal_set_message(t('There was an error saving your report, %s to the database.', array(
'%s' => $name,
)));
}
}