function commerce_bpc_settings_form_submit in Commerce Bulk Product Creation 7
Same name and namespace in other branches
- 7.2 commerce_bpc.settings.inc \commerce_bpc_settings_form_submit()
Form submission handler for commerce_bpc_settings_form().
1 string reference to 'commerce_bpc_settings_form_submit'
- commerce_bpc_settings_form in ./
commerce_bpc.admin.inc - BPC-specific wrapper for system_settings_form.
File
- ./
commerce_bpc.admin.inc, line 294 - Page generation callbacks the Commerce Bulk Product Creation settings pages.
Code
function commerce_bpc_settings_form_submit($form, &$form_state) {
form_state_values_clean($form_state);
$fv =& $form_state['values'];
$group = $fv['settings_group'];
unset($fv['settings_group']);
$type = isset($fv['product_type']) ? $fv['product_type'] : NULL;
unset($fv['product_type']);
foreach ($fv as $key => $value) {
commerce_bpc_setting_set($group, $key, $value, $type);
}
drupal_set_message(t('The configuration options have been saved.'));
}