function uc_coupon_purchase_notify_settings in Ubercart Discount Coupons 5
Form builder for coupon notification settings.
1 string reference to 'uc_coupon_purchase_notify_settings'
- uc_coupon_purchase_menu in uc_coupon_purchase/
uc_coupon_purchase.module - Implementation of hook_menu().
File
- uc_coupon_purchase/
uc_coupon_purchase.module, line 198
Code
function uc_coupon_purchase_notify_settings() {
$form['single'] = array(
'#type' => 'fieldset',
'#title' => t('Single coupon creation message'),
'#collapsible' => TRUE,
'#collapsed' => TRUE,
);
$form['single']['uc_coupon_purchase_single_subject'] = array(
'#type' => 'textfield',
'#title' => t('Message subject'),
'#default_value' => variable_get('uc_coupon_purchase_single_subject', uc_get_message('uc_coupon_purchase_single_subject')),
);
$form['single']['uc_coupon_purchase_single_message'] = array(
'#type' => 'textarea',
'#title' => t('Message text'),
'#default_value' => variable_get('uc_coupon_purchase_single_message', uc_get_message('uc_coupon_purchase_single_message')),
'#description' => t('The message the user receives when a new coupon is created (<a href="!url">uses order, uc_coupon, and global tokens</a>).', array(
'!url' => url('admin/store/help/tokens'),
)),
'#rows' => 10,
);
$form['single']['uc_coupon_purchase_single_format'] = filter_form(variable_get('uc_coupon_purchase_single_format', FILTER_FORMAT_DEFAULT), NULL, array(
'uc_coupon_purchase_single_format',
));
$form['bulk'] = array(
'#type' => 'fieldset',
'#title' => t('Bulk coupon creation message'),
'#collapsible' => TRUE,
'#collapsed' => TRUE,
);
$form['bulk']['uc_coupon_purchase_bulk_subject'] = array(
'#type' => 'textfield',
'#title' => t('Message subject'),
'#default_value' => variable_get('uc_coupon_purchase_bulk_subject', uc_get_message('uc_coupon_purchase_bulk_subject')),
);
$form['bulk']['uc_coupon_purchase_bulk_message'] = array(
'#type' => 'textarea',
'#title' => t('Message text'),
'#default_value' => variable_get('uc_coupon_purchase_bulk_message', uc_get_message('uc_coupon_purchase_bulk_message')),
'#description' => t('The message the user receives when a new coupon is created (<a href="!url">uses order, uc_coupon, and global tokens</a>).', array(
'!url' => url('admin/store/help/tokens'),
)),
'#rows' => 10,
);
$form['bulk']['uc_coupon_purchase_bulk_format'] = filter_form(variable_get('uc_coupon_purchase_bulk_format', FILTER_FORMAT_DEFAULT), NULL, array(
'uc_coupon_purchase_bulk_format',
));
return system_settings_form($form);
}