function bat_event_field_schema in Booking and Availability Management Tools for Drupal 7
Implements hook_field_schema().
File
- modules/
bat_event/ bat_event.install, line 28 - Sets up the base table for our entity and a table to store information about the entity types.
Code
function bat_event_field_schema($field) {
$columns = array(
'state_id' => array(
'type' => 'int',
'unsigned' => TRUE,
'not null' => FALSE,
),
);
return array(
'columns' => $columns,
'indexes' => array(
'state_id' => array(
'state_id',
),
),
'foreign keys' => array(
'state_id' => array(
'table' => 'bat_event_state',
'columns' => array(
'state_id' => 'state_id',
),
),
),
);
}