This repository has been archived by the owner on Nov 7, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 12
/
noteresource.install
68 lines (65 loc) · 1.66 KB
/
noteresource.install
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
<?php
// $Id$
/**
* Implementation of hook_install().
*/
function noteresource_install() {
drupal_install_schema('noteresource');
}
/**
* Implementation of hook_uninstall().
*/
function noteresource_uninstall() {
drupal_install_schema('noteresource');
}
/**
* Implementation of hook_schema().
*/
function noteresource_schema() {
return array(
'note' => array(
'description' => 'Stores information about notes',
'fields' => array(
'id' => array(
'description' => 'The primary identifier for a note.',
'type' => 'serial',
'unsigned' => TRUE,
'not null' => TRUE,
),
'uid' => array(
'description' => t('The user that created the note.'),
'type' => 'int',
'unsigned' => TRUE,
'not null' => TRUE,
'default' => 0,
),
'created' => array(
'description' => t('The timestamp for when the note was created.'),
'type' => 'int',
'unsigned' => TRUE,
'not null' => TRUE,
'default' => 0,
),
'modified' => array(
'description' => t('The timestamp for when the note was modified.'),
'type' => 'int',
'unsigned' => TRUE,
'not null' => TRUE,
'default' => 0,
),
'subject' => array(
'description' => t('The subject of the note'),
'type' => 'varchar',
'length' => 255,
'not null' => TRUE,
),
'note' => array(
'description' => t('The note'),
'type' => 'text',
'size' => 'medium',
),
),
'primary key' => array('id'),
),
);
}