/[drupal]/contributions/modules/decisions/decisions.install
ViewVC logotype

Diff of /contributions/modules/decisions/decisions.install

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

revision 1.28, Fri Dec 5 03:48:02 2008 UTC revision 1.29, Mon Oct 26 20:41:27 2009 UTC
# Line 6  Line 6 
6   * .install file for decisions module   * .install file for decisions module
7   */   */
8    
9  // $Id$  // $Id: decisions.install,v 1.28 2008/12/05 03:48:02 anarcat Exp $
10    
11  /**  /**
12   * Implementation of hook_install().   * Implementation of hook_install().
# Line 25  function decisions_schema() { Line 25  function decisions_schema() {
25           'algorithm' => array('type' => 'varchar', 'length' => '100', 'not null' => FALSE),           'algorithm' => array('type' => 'varchar', 'length' => '100', 'not null' => FALSE),
26           'showvotes' => array('type' => 'int', 'size' => 'tiny', 'not null' => FALSE, 'disp-width' => '4'),           'showvotes' => array('type' => 'int', 'size' => 'tiny', 'not null' => FALSE, 'disp-width' => '4'),
27           'startdate' => array('type' => 'int', 'unsigned' => TRUE, 'not null' => FALSE, 'disp-width' => '10')),           'startdate' => array('type' => 'int', 'unsigned' => TRUE, 'not null' => FALSE, 'disp-width' => '10')),
28             'randomize' => array('type' => 'int', 'size' => 'tiny', 'not null' => FALSE, 'default' => 1, 'disp-width' => '4'),
29      'primary key' => array('nid'),      'primary key' => array('nid'),
30    );    );
31    
# Line 113  function decisions_update_5() { Line 114  function decisions_update_5() {
114    return $items;    return $items;
115  }  }
116    
117    function decisions_update_6000() {
118      switch ($GLOBALS['db_type']) {
119      case 'mysql':
120      case 'mysqli':
121        $items[] = update_sql("ALTER TABLE {decisions} ADD COLUMN `randomize` tinyint default '0'");
122        break;
123      }
124      return $items;
125    }
126    
127  /**  /**
128   * Implementation of hook_uninstall().   * Implementation of hook_uninstall().
129   */   */

Legend:
Removed from v.1.28  
changed lines
  Added in v.1.29

  ViewVC Help
Powered by ViewVC 1.1.2