function menu_position_schema in Menu Position 7
Same name and namespace in other branches
- 6 menu_position.install \menu_position_schema()
- 7.2 menu_position.install \menu_position_schema()
Implements hook_schema().
File
- ./
menu_position.install, line 10 - Provides install, update and un-install functions for menu_position.
Code
function menu_position_schema() {
$schema['menu_position_rules'] = array(
'description' => 'Stores breadcrumb rules for nodes.',
'fields' => array(
'rid' => array(
'description' => 'The primary identifier for a rule.',
'type' => 'serial',
'not null' => TRUE,
),
'admin_title' => array(
'description' => 'The administrative title of this rule.',
'type' => 'varchar',
'length' => 255,
'default' => NULL,
),
'enabled' => array(
'description' => 'Whether the rule is enabled or not.',
'type' => 'int',
'size' => 'tiny',
'unsigned' => TRUE,
'not null' => TRUE,
'default' => 1,
),
'conditions' => array(
'description' => 'The serialized conditions for this rule.',
'type' => 'text',
'serialize' => TRUE,
),
'menu_name' => array(
'description' => 'The menu of the menu link for this rule.',
'type' => 'varchar',
'length' => '32',
'not null' => TRUE,
'default' => '',
),
'plid' => array(
'description' => 'The parent menu link id for this rule.',
'type' => 'int',
'default' => NULL,
),
'mlid' => array(
'description' => 'The menu link id for this rule.',
'type' => 'int',
'default' => NULL,
),
'weight' => array(
'description' => 'The weight of this rule.',
'type' => 'int',
'size' => 'tiny',
'not null' => FALSE,
'default' => 0,
),
'machine_name' => array(
'description' => 'The machine name.',
'type' => 'varchar',
'length' => 255,
'default' => NULL,
),
),
'indexes' => array(
'rule_enabled' => array(
'enabled',
'weight',
'rid',
),
'rule_weight' => array(
'weight',
'rid',
),
),
'primary key' => array(
'rid',
),
'unique keys' => array(
'machine_name' => array(
'machine_name',
),
),
);
return $schema;
}