function uc_cart_checkout_panes_form in Ubercart 5
Same name and namespace in other branches
- 6.2 uc_cart/uc_cart.admin.inc \uc_cart_checkout_panes_form()
1 string reference to 'uc_cart_checkout_panes_form'
- uc_cart_menu in uc_cart/
uc_cart.module - Implementation of hook_menu().
File
- uc_cart/
uc_cart.module, line 1041
Code
function uc_cart_checkout_panes_form() {
$panes = _checkout_pane_list();
$form['panes'] = array(
'#theme' => 'uc_pane_sort_table',
'#pane_prefix' => 'uc_pane',
);
foreach ($panes as $pane) {
$form['panes'][$pane['id']]['uc_pane_' . $pane['id'] . '_enabled'] = array(
'#type' => 'checkbox',
'#default_value' => $pane['enabled'],
);
$form['panes'][$pane['id']]['title'] = array(
'#value' => $pane['title'],
);
$form['panes'][$pane['id']]['uc_pane_' . $pane['id'] . '_weight'] = array(
'#type' => 'weight',
'#default_value' => $pane['weight'],
);
$null = NULL;
$pane_settings = $pane['callback']('settings', $null, NULL);
if (is_array($pane_settings)) {
$form['pane_' . $pane['id']] = array(
'#type' => 'fieldset',
'#title' => t('!pane settings', array(
'!pane' => $pane['title'],
)),
'#collapsible' => TRUE,
'#collapsed' => TRUE,
);
$form['pane_' . $pane['id']] = array_merge($form['pane_' . $pane['id']], $pane_settings);
}
}
return system_settings_form($form);
}