function block_inject_schema in Block Inject 7
1 call to block_inject_schema()
- block_inject_update_7104 in ./
block_inject.install - Add index on nid to block_inject_exceptions.
File
- ./
block_inject.install, line 11 - Schema function for the Block Inject table *
Code
function block_inject_schema() {
$schema = array();
$schema['block_inject'] = array(
'description' => 'The regions that are injected into nodes.',
'fields' => array(
'id' => array(
'description' => 'The id',
'type' => 'serial',
'length' => 5,
'not null' => TRUE,
'unsigned' => TRUE,
),
'region' => array(
'description' => 'The region that is injected',
'type' => 'varchar',
'length' => 32,
'not null' => TRUE,
'default' => '',
),
'node_type' => array(
'description' => 'The node type the region is injected in',
'type' => 'text',
'not null' => TRUE,
),
'node_name' => array(
'description' => 'The name of the node type the region is injected in',
'type' => 'text',
'not null' => TRUE,
),
'bi_condition' => array(
'description' => 'The condition if any',
'type' => 'text',
'default' => NULL,
'serialize' => TRUE,
),
),
'primary key' => array(
'id',
),
);
$schema['block_inject_exceptions'] = array(
'description' => 'The exceptions table.',
'fields' => array(
'id' => array(
'description' => 'The id',
'type' => 'serial',
'length' => 5,
'not null' => TRUE,
'unsigned' => TRUE,
),
'bi_id' => array(
'description' => 'The block_inject region ID',
'type' => 'int',
'length' => 2,
),
'nid' => array(
'description' => 'The block_inject region ID',
'type' => 'int',
'length' => 5,
),
'except_injection' => array(
'description' => 'The status of the exception',
'type' => 'int',
'length' => 1,
),
'offset' => array(
'description' => 'Offset for the injecton',
'type' => 'int',
'length' => 1,
),
),
'primary key' => array(
'id',
),
'indexes' => array(
'nid' => array(
'nid',
),
),
);
return $schema;
}