You are here

function uc_extra_fields_pane_field_edit in Extra Fields Checkout Pane 6

1 string reference to 'uc_extra_fields_pane_field_edit'
uc_extra_fields_pane_menu in ./uc_extra_fields_pane.module

File

./uc_extra_fields_pane.module, line 375

Code

function uc_extra_fields_pane_field_edit(&$form_state, $field) {
  $form = array();
  $form['label'] = array(
    '#title' => t('Label'),
    '#type' => 'textfield',
    '#size' => 15,
    '#description' => t('Label shown to customers in checkout pages.'),
    '#required' => TRUE,
    '#default_value' => $field->field_name,
  );
  $form['description'] = array(
    '#title' => t('Description'),
    '#type' => 'textarea',
    '#rows' => 3,
    '#description' => t('Insert a description to tell customers how to fill this field.'),
    '#default_value' => $field->field_description,
  );
  $form['required'] = array(
    '#title' => t('Field required'),
    '#type' => 'checkbox',
    '#description' => t('Check this item is field is mandatory.'),
    '#default_value' => $field->field_required,
  );
  $form['submit'] = array(
    '#type' => 'submit',
    '#value' => t('Save'),
  );
  return $form;
}