-
Notifications
You must be signed in to change notification settings - Fork 0
/
legal.install
59 lines (54 loc) · 2.16 KB
/
legal.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
<?php
/**
* @file
* Installation and update functions for the Legal module.
*/
/**
* Implements hook_schema().
*/
function legal_schema() {
$schema['legal_conditions'] = array(
'fields' => array(
'tc_id' => array('type' => 'serial', 'unsigned' => FALSE, 'not null' => TRUE, 'disp-width' => 10),
'version' => array('type' => 'int', 'unsigned' => FALSE, 'not null' => TRUE, 'default' => 0, 'disp-width' => 11),
'revision' => array('type' => 'int', 'unsigned' => FALSE, 'not null' => TRUE, 'default' => 0, 'disp-width' => 11),
'language' => array(
'description' => t("TODO."),
'type' => 'varchar',
'length' => '12',
'not null' => TRUE,
'default' => ''
),
'conditions' => array('type' => 'text', 'size' => 'big', 'not null' => TRUE),
'date' => array('type' => 'int', 'unsigned' => FALSE, 'not null' => TRUE, 'default' => 0, 'disp-width' => 11),
'extras' => array('type' => 'text'),
'changes' => array('type' => 'text'),
),
'primary key' => array('tc_id'),
);
$schema['legal_accepted'] = array(
'fields' => array(
'legal_id' => array('type' => 'serial', 'unsigned' => FALSE, 'not null' => TRUE, 'disp-width' => 10),
'version' => array('type' => 'int', 'unsigned' => FALSE, 'not null' => TRUE, 'default' => 0, 'disp-width' => 11),
'revision' => array('type' => 'int', 'unsigned' => FALSE, 'not null' => TRUE, 'default' => 0, 'disp-width' => 11),
'language' => array(
'description' => t("TODO."),
'type' => 'varchar',
'length' => '12',
'not null' => TRUE,
'default' => ''
),
'uid' => array('type' => 'int', 'unsigned' => FALSE, 'not null' => TRUE, 'default' => 0, 'disp-width' => 10),
'accepted' => array('type' => 'int', 'unsigned' => FALSE, 'not null' => TRUE, 'default' => 0, 'disp-width' => 11),
),
'indexes' => array('uid' => array('uid')),
'primary key' => array('legal_id'),
);
return $schema;
}
/**
* Implements hook_update_last_removed().
*/
function legal_update_last_removed() {
return 6003;
}