-
Notifications
You must be signed in to change notification settings - Fork 0
/
epm_project_management.install
77 lines (69 loc) · 2.41 KB
/
epm_project_management.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
<?php
// Consider tracking whether this is a module or theme.
/**
* Implementation of hook_schema().
*/
function epm_project_management_schema() {
$schema['epm_project_management_data'] = array(
'description' => 'Holds project metadata data for the epm project management system.',
'fields' => array(
'nid' => array(
'description' => 'The {node} this data belongs to.',
'type' => 'int',
'unsigned' => TRUE,
'not null' => TRUE,
'default' => 0),
'last_update' => array(
'description' => 'The Unix timestamp when this data was last updated.',
'type' => 'int',
'not null' => TRUE,
'default' => 0),
'open_bug_count' => array(
'description' => 'The number of open bugs on this project.',
'type' => 'int',
'unsigned' => TRUE,
'not null' => TRUE,
'default' => 0),
'closed_bug_count' => array(
'description' => 'The number of closed bugs on this project.',
'type' => 'int',
'unsigned' => TRUE,
'not null' => TRUE,
'default' => 0),
'last_stable_release' => array(
'description' => 'The date of the last stable release or 0 if none exists.',
'type' => 'int',
'unsigned' => TRUE,
'not null' => TRUE,
'default' => 0),
'open_bug_count' => array(
'description' => 'The number of open bugs on this project.',
'type' => 'int',
'unsigned' => TRUE,
'not null' => TRUE,
'default' => 0),
'active_maintainer_count' => array(
'description' => 'The number of active maintainers (code committers) on this project.',
'type' => 'int',
'unsigned' => TRUE,
'not null' => TRUE,
'default' => 0),
'major_version_usage' => array(
'description' => "The usage of the module's major version according to drupal.org",
'type' => 'int',
'unsigned' => TRUE,
'not null' => TRUE,
'default' => 0),
),
'indexes' => array('last_update' => array('last_update')),
'primary key' => array('nid'),
);
return $schema;
}
function epm_project_management_install() {
// A variable to determine which major version you care about.
// Used in gathering usage statistics, and maybe elsewhere.
variable_set('epm_project_management_major_version', '6');
// Create tables.
drupal_install_schema('epm_project_management');
}