-
Notifications
You must be signed in to change notification settings - Fork 15
/
islandora_multi_importer.install
91 lines (86 loc) · 2.48 KB
/
islandora_multi_importer.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
<?php
/**
* @file
* Defines functions used for the installation of the islandora_multi_importer module.
* This works only for MYSQL!
*/
/**
* Implements hook_schema().
*/
function islandora_multi_importer_schema() {
$schema['islandora_multi_importer_twig_templates'] = array(
'description' => 'This table is used to store Twig templates used by the multi importer',
'fields' => array(
'id' => array(
'type' => 'serial',
'not null' => TRUE,
),
'name' => array(
'description' => 'The name of the stored Template.',
'type' => 'varchar',
'length' => 128,
'not null' => TRUE,
),
'twig' => array(
'description' => 'The stored template',
'type' => 'text',
'size' => 'big',
'not null' => TRUE,
),
'updated' => array(
'description' => 'Timestamp this Template was updated',
'type' => 'int',
'not null' => TRUE,
),
),
'unique keys' => array('name' => array('name')),
'primary key' => array('id'),
);
$schema['islandora_multi_importer_presets'] = array(
'description' => 'This table is used to whole islandora multi importer presets for an input/output mix',
'fields' => array(
'id' => array(
'type' => 'serial',
'not null' => TRUE,
),
'name' => array(
'description' => 'The name of the stored Preset',
'type' => 'varchar',
'length' => 128,
'not null' => TRUE,
),
'preset' => array(
'type' => 'blob',
'not null' => FALSE,
'size' => 'big',
'serialize' => TRUE,
'description' => 'A serialized array of the whole import form',
),
'updated' => array(
'description' => 'Timestamp this Template was updated',
'type' => 'int',
'not null' => TRUE,
),
),
'unique keys' => array('name' => array('name')),
'primary key' => array('id'),
);
return $schema;
}
function islandora_multi_importer_enable() {
}
/**
* Implements hook_uninstall().
*/
function islandora_multi_importer_uninstall() {
$variables = array(
'islandora_multi_importer_plupload',
'islandora_multi_importer_extrads',
'islandora_multi_importer_dontenforceds',
'islandora_multi_importer_googleClientID',
'islandora_multi_importer_googleClientSecret',
'islandora_multi_importer_googleClientToken',
'islandora_multi_importer_googleClientAuthCode',
);
array_walk($variables, 'variable_del');
}