function drupalchat_notifications_schema in DrupalChat 7.2
Same name and namespace in other branches
- 6.2 drupalchat_notifications/drupalchat_notifications.install \drupalchat_notifications_schema()
- 7 drupalchat_notifications/drupalchat_notifications.install \drupalchat_notifications_schema()
Implements hook_schema().
File
- drupalchat_notifications/
drupalchat_notifications.install, line 20 - Installation file for the DrupalChat Notifications module.
Code
function drupalchat_notifications_schema() {
$schema = array();
$schema['drupalchat_notifications'] = array(
'fields' => array(
'nfid' => array(
'description' => 'Uid of the sender.',
'type' => 'int',
'not null' => TRUE,
'unsigned' => TRUE,
),
'uid' => array(
'description' => 'Uid of the receiver.',
'type' => 'int',
'not null' => TRUE,
'unsigned' => TRUE,
),
'message' => array(
'type' => 'text',
'size' => 'big',
'not null' => TRUE,
'description' => 'Chat message.',
),
'timestamp' => array(
'description' => 'The Unix timestamp when the XMPP account was created.',
'type' => 'int',
'not null' => TRUE,
'unsigned' => TRUE,
),
),
'primary key' => array(
'nfid',
),
'indexes' => array(
'uid' => array(
'uid',
),
),
);
return $schema;
}