-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy patheventsign.install
149 lines (146 loc) · 4.14 KB
/
eventsign.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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
<?php
/**
* @file
* Install, update and uninstall functions for the eventsign module.
*/
/**
* Implements hook_schema().
*/
function eventsign_schema() {
$schema['eventsign'] = array(
'description' => 'Stores eventsign items.',
'fields' => array(
'id' => array(
'type' => 'serial',
'not null' => TRUE,
'description' => 'Primary Key: Unique eventsign item ID.',
),
'type' => array(
'description' => 'The {eventsign_type}.type of this eventsign.',
'type' => 'varchar',
'length' => 32,
'not null' => TRUE,
'default' => '',
),
'label' => array(
'description' => 'The label of the eventsign.',
'type' => 'varchar',
'length' => 255,
'not null' => TRUE,
'default' => '',
),
'begindate' => array(
'description' => 'begin Date.',
'type' => 'int',
'not null' => FALSE,
),
'enddate' => array(
'description' => 'End Date.',
'type' => 'int',
'not null' => FALSE,
),
'langcode' => array(
'description' => 'The {language}.langcode of the eventsign.',
'type' => 'varchar',
'length' => 12,
'not null' => TRUE,
'default' => '',
),
'uid' => array(
'description' => 'The {users}.uid that owns this node; initially, this is the user that created it.',
'type' => 'int',
'not null' => TRUE,
'default' => 0,
),
'created' => array(
'description' => 'The Unix timestamp when the eventsign was created.',
'type' => 'int',
'not null' => FALSE,
),
'changed' => array(
'description' => 'The Unix timestamp when the eventsign was changed.',
'type' => 'int',
'not null' => FALSE,
),
'status' => array(
'description' => 'Whether the eventsign is active (1) or not (0).',
'type' => 'int',
'default' => 0,
'size' => 'tiny',
'not null' => FALSE,
),
),
'indexes' => array(
'type' => array('type'),
'changed' => array('changed'),
'created' => array('created'),
'uid' => array('uid'),
),
'foreign keys' => array(
'type' => array(
'table' => 'eventsign_type',
'columns' => array('type' => 'type'),
),
'owner' => array(
'table' => 'users',
'columns' => array('uid' => 'uid'),
),
),
'primary key' => array('id'),
);
$schema['eventsign_type'] = array(
'description' => 'Stores information about all defined eventsign types.',
'fields' => array(
'id' => array(
'type' => 'serial',
'not null' => TRUE,
'description' => 'Primary Key: Unique eventsign type ID.',
),
'name' => array(
'description' => 'The machine-readable name of this eventsign type.',
'type' => 'varchar',
'length' => 32,
'not null' => TRUE,
),
'label' => array(
'description' => 'The human-readable name of this eventsign type.',
'type' => 'varchar',
'length' => 255,
'not null' => TRUE,
'default' => '',
),
'weight' => array(
'type' => 'int',
'not null' => TRUE,
'default' => 0,
'size' => 'tiny',
'description' => 'The weight of this eventsign type in relation to others.',
),
'data' => array(
'type' => 'text',
'not null' => FALSE,
'size' => 'big',
'serialize' => TRUE,
'description' => 'A serialized array of additional data related to this eventsign type.',
),
'status' => array(
'type' => 'int',
'not null' => TRUE,
'default' => 0x01,
'size' => 'tiny',
'description' => 'The exportable status of the entity.',
),
'module' => array(
'description' => 'The name of the providing module if the entity has been defined in code.',
'type' => 'varchar',
'length' => 255,
'not null' => FALSE,
),
),
'primary key' => array('id'),
'unique keys' => array(
'name' => array('name'),
),
);
return $schema;
}