public function UCXF_AddressField::edit_form in Extra Fields Checkout Pane 7
Same name and namespace in other branches
- 6.2 class/UCXF_AddressField.class.php \UCXF_AddressField::edit_form()
Override of UCXF_Field::edit_form().
Get the edit form for the item.
@access public
Return value
array
Overrides UCXF_Field::edit_form
File
- class/
UCXF_AddressField.class.php, line 41 - Contains the UCXF_AddressField class.
Class
- UCXF_AddressField
- Class for a Extra Fields Pane Address field
Code
public function edit_form() {
$form = parent::edit_form();
// Unset pane type field, the pane types asking is handled differently
unset($form['ucxf']['pane_type']);
// Unset also weight field, because the weight for an address field is implemented differently
unset($form['ucxf']['weight']);
// Add form element to ask in which panes they need to appear
$form['ucxf']['panes'] = array(
'#title' => t('Select the panes the field must get into'),
'#type' => 'checkboxes',
'#options' => array(
'extra_delivery' => t('Delivery pane'),
'extra_billing' => t('Billing pane'),
),
'#weight' => 5,
'#default_value' => $this->pane_types,
);
return $form;
}