function newsletter_list_schema in Newsletter 7.2
Implements hook_schema().
File
- modules/
list/ newsletter_list.install, line 27 - Contains install,uninstall and update functions for Newsletter module.
Code
function newsletter_list_schema() {
$schema = array();
$schema['newsletter_list'] = array(
'description' => 'Contains the newsletter subscriber lists with their templates relations.',
'fields' => array(
'list_id' => array(
'description' => 'The primary identifier of newsletter lists.',
'type' => 'serial',
'unsigned' => TRUE,
'not null' => TRUE,
),
'title' => array(
'description' => 'The list\'s title.',
'type' => 'varchar',
'length' => 255,
'not null' => TRUE,
),
'last_sent' => array(
'description' => 'Timestamp this list was last sent.',
'type' => 'int',
'not null' => FALSE,
),
'send_again' => array(
'description' => 'Timestamp this list needs to be sent again.',
'type' => 'int',
'not null' => FALSE,
),
'created' => array(
'description' => 'The creation timestamp of this subscriber.',
'type' => 'int',
'not null' => TRUE,
'default' => 0,
),
),
'foreign keys' => array(
'tracked_template' => array(
'table' => 'newsletter_template',
'columns' => array(
'template_id' => 'template_id',
),
),
),
'indexes' => array(
'send_again' => array(
'send_again',
),
),
'primary key' => array(
'list_id',
),
);
return $schema;
}