stableversion-3.0
Last change
on this file since c43ea01 was
303fae2,
checked in by José Gregorio Puentes <jpuentes@…>, 9 años ago
|
se agregaron los modulos
|
-
Propiedad mode establecida a
100755
|
File size:
1.4 KB
|
Línea | |
---|
1 | <?php |
---|
2 | |
---|
3 | /* |
---|
4 | * Implementation of hook_install() |
---|
5 | */ |
---|
6 | function ente_planificador_hierarchical_install() { |
---|
7 | db_query("UPDATE {system} SET weight = 10 WHERE name = 'ente_planificador_hierarchical'"); |
---|
8 | // Notify content module when this module is uninstalled. |
---|
9 | drupal_install_schema('ente_planificador_hierarchical'); |
---|
10 | } |
---|
11 | |
---|
12 | /* |
---|
13 | * Implementation of hook_uninstall() |
---|
14 | */ |
---|
15 | function ente_planificador_hierarchical_uninstall() { |
---|
16 | drupal_uninstall_schema('ente_planificador_hierarchical'); |
---|
17 | db_query("DELETE FROM {variable} WHERE name LIKE '%s'", 'ente_planificador_hierarchical%'); |
---|
18 | } |
---|
19 | |
---|
20 | |
---|
21 | /* |
---|
22 | * Implementation of hook_schema |
---|
23 | */ |
---|
24 | function ente_planificador_hierarchical_schema() { |
---|
25 | $schema['ente_planificador_hierarchical'] = array( |
---|
26 | 'description' => 'ente planificador hierarchical.', |
---|
27 | 'fields' => array( |
---|
28 | 'nid' => array( |
---|
29 | 'description' => 'nid del nodo.', |
---|
30 | 'type' => 'int', |
---|
31 | 'unsigned' => TRUE, |
---|
32 | 'not null' => TRUE, |
---|
33 | 'default' => 0, |
---|
34 | ), |
---|
35 | 'level' => array( |
---|
36 | 'description' => 'nivel de la relacion.', |
---|
37 | 'type' => 'int', |
---|
38 | 'unsigned' => TRUE, |
---|
39 | 'not null' => TRUE, |
---|
40 | 'default' => 0, |
---|
41 | ), |
---|
42 | 'father' => array( |
---|
43 | 'description' => 'ente padre.', |
---|
44 | 'type' => 'int', |
---|
45 | 'unsigned' => TRUE, |
---|
46 | 'not null' => TRUE, |
---|
47 | 'default' => 0, |
---|
48 | ), |
---|
49 | ), |
---|
50 | 'indexes' => array( |
---|
51 | 'nid' => array('nid'), |
---|
52 | 'father' => array('father'), |
---|
53 | ), |
---|
54 | ); |
---|
55 | return $schema; |
---|
56 | } |
---|
Nota: Vea
TracBrowser
para ayuda de uso del navegador del repositorio.