function formassembly_install in FormAssembly 7
Implementation of hook_install().
@todo the 'display' item in $field_instance is not hiding the field
File
- ./
formassembly.install, line 71 - The Drupal .install file for the formassembly module
Code
function formassembly_install() {
$field = array(
'field_name' => 'fa_query_params',
'cardinality' => 1,
'type' => 'text_long',
);
field_create_field($field);
$field_instance = array(
'field_name' => 'fa_query_params',
'label' => 'Form query parameters',
'entity_type' => 'fa_form',
'bundle' => 'fa_form',
'display' => array(
'default' => array(
'label' => 'hidden',
'settings' => array(),
'type' => 'hidden',
'weight' => 0,
),
'markup' => array(
'label' => 'hidden',
'settings' => array(),
'type' => 'hidden',
),
'full' => array(
'label' => 'hidden',
'settings' => array(),
'type' => 'hidden',
),
),
'description' => t('Enter parameters to be added to FormAssembly form request.<br />' . 'Parameter definitions should be of the form \'key|value\', with one parameter per line.'),
);
field_create_instance($field_instance);
}