-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathviews_send.install
101 lines (98 loc) · 2.77 KB
/
views_send.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
<?php
/**
* @file
* The install and update code for the Views Send module.
*
* @ingroup views_send.
*/
/**
* Implements hook_schema().
*/
function views_send_schema() {
$schema['views_send_spool'] = array(
'description' => 'Table holds e-mails that are being send on cron.',
'fields' => array(
'eid' => array(
'description' => 'The primary identifier for an e-mail.',
'type' => 'serial',
'unsigned' => TRUE,
'not null' => TRUE),
'uid' => array(
'description' => 'The user that has sent the message.',
'type' => 'int',
'not null' => TRUE,
'unsigned' => TRUE,
'default' => 0),
'timestamp' => array(
'description' => 'The Unix timestamp when the message was added to spool.',
'type' => 'int',
'not null' => TRUE,
'unsigned' => TRUE,
'default' => 0),
'status' => array(
'description' => 'Status: 0 = pending; 1 = sent.',
'type' => 'int',
'size' => 'tiny',
'not null' => TRUE,
'unsigned' => TRUE,
'default' => 0),
'tentatives' => array(
'description' => 'How many times we tried to send this message.',
'type' => 'int',
'not null' => TRUE,
'unsigned' => TRUE,
'default' => 0),
'from_name' => array(
'description' => 'The real name of the sender.',
'type' => 'varchar',
'length' => 255,
'not null' => FALSE,
'default' => ''),
'from_mail' => array(
'description' => 'The sender e-mail address.',
'type' => 'varchar',
'length' => 255,
'not null' => TRUE,
'default' => ''),
'to_name' => array(
'description' => 'The real name of the recipient.',
'type' => 'varchar',
'length' => 255,
'not null' => FALSE,
'default' => ''),
'to_mail' => array(
'description' => 'The recipient e-mail address.',
'type' => 'varchar',
'length' => 255,
'not null' => TRUE,
'default' => ''),
'subject' => array(
'description' => 'The e-mail subject.',
'type' => 'varchar',
'length' => 255,
'not null' => TRUE,
'default' => ''),
'body' => array(
'description' => 'The e-mail body.',
'type' => 'text',
'not null' => TRUE,
'size' => 'big',),
'headers' => array(
'description' => 'The e-mail additional headers.',
'type' => 'text',
'not null' => TRUE,
'size' => 'big',),
),
'indexes' => array(
'uid' => array('uid'),
'timestamp' => array('timestamp'),
),
'primary key' => array('eid'),
);
return $schema;
}
/**
* Implements hook_uninstall().
*/
function views_send_uninstall() {
}