You are here

function commerce_registration_information_settings_form in Commerce Registration 7.2

Same name and namespace in other branches
  1. 7.3 includes/commerce_registration.checkout_pane.inc \commerce_registration_information_settings_form()

Commerce checkout pane settings form builder.

File

includes/commerce_registration.checkout_pane.inc, line 412
Checkout pane callback functions.

Code

function commerce_registration_information_settings_form($checkout_pane) {
  $form = array();
  $form['commerce_registration_product_title'] = array(
    '#type' => 'textfield',
    '#title' => t('Product Registration Title'),
    '#description' => t('The text to populate the fieldset label for a registrant\'s information. Tokens are supported if the module is enabled.'),
    '#default_value' => variable_get('commerce_registration_product_title', ''),
    '#maxlength' => 1024,
  );
  $form['commerce_registration_registrant_help'] = array(
    '#type' => 'textarea',
    '#title' => t('Product Registration Fieldset Help Text'),
    '#description' => t('The help text to display to the user entering registration information. Tokens are supported if the module is enabled.'),
    '#default_value' => variable_get('commerce_registration_registrant_help', ''),
  );
  if (module_exists('token')) {
    $form['commerce_registration_token_tree'] = array(
      '#theme' => 'token_tree',
      '#token_types' => array(
        'commerce-line-item',
        'commerce-order',
        'commerce-registration',
      ),
    );
  }
  $form['commerce_registration_hide_email_logged_in'] = array(
    '#type' => 'checkbox',
    '#title' => t('Hide the Email field for logged in users'),
    '#default_value' => variable_get('commerce_registration_hide_email_logged_in', ''),
  );
  return $form;
}