function block_revisions_schema in Block Revisions 6
Same name and namespace in other branches
- 7 block_revisions.install \block_revisions_schema()
Implementation of hook_schema().
File
- ./
block_revisions.install, line 15 - Installation routines for the Block Revisions module.
Code
function block_revisions_schema() {
$schema['boxes_revisions'] = array(
'description' => 'Stores the revision history of content for custom-made blocks.',
'fields' => array(
'brid' => array(
'type' => 'serial',
'unsigned' => TRUE,
'not null' => TRUE,
'description' => "A unique id for this revision.",
),
'bid' => array(
'type' => 'int',
'unsigned' => TRUE,
'not null' => TRUE,
'description' => "The block's {blocks}.bid.",
),
'vid' => array(
'type' => 'int',
'unsigned' => TRUE,
'not null' => TRUE,
'description' => "The revision id.",
),
'uid' => array(
'description' => 'The {users}.uid that created this version.',
'type' => 'int',
'not null' => TRUE,
'default' => 0,
),
'body' => array(
'type' => 'text',
'not null' => FALSE,
'size' => 'big',
'description' => 'Block contents.',
),
'format' => array(
'type' => 'int',
'size' => 'small',
'not null' => FALSE,
'default' => 0,
'description' => "Block body's {filter_formats}.format; for example, 1 = Filtered HTML.",
),
'log' => array(
'description' => 'The log entry explaining the changes in this version.',
'type' => 'text',
'not null' => TRUE,
'size' => 'big',
),
'timestamp' => array(
'description' => 'A Unix timestamp indicating when this version was created.',
'type' => 'int',
'not null' => TRUE,
'default' => 0,
),
),
'unique keys' => array(
'revision' => array(
'bid',
'vid',
),
),
'primary key' => array(
'brid',
),
);
return $schema;
}