| 1 |
<?php |
<?php |
| 2 |
// $Id: workflow.install,v 1.13.2.1 2009/01/05 17:10:00 jvandyk Exp $ |
// $Id: workflow.install,v 1.13.2.2 2009/01/07 02:48:33 jvandyk Exp $ |
| 3 |
|
|
| 4 |
/** |
/** |
| 5 |
* Implementation of hook_install(). |
* Implementation of hook_install(). |
| 75 |
); |
); |
| 76 |
$schema['workflow_node_history'] = array( |
$schema['workflow_node_history'] = array( |
| 77 |
'fields' => array( |
'fields' => array( |
| 78 |
'hid' => array('type' => 'serial'), |
'hid' => array('type' => 'serial', 'not null' => TRUE), |
| 79 |
'nid' => array('type' => 'int', 'unsigned' => TRUE, 'not null' => TRUE, 'default' => 0, 'disp-width' => '10'), |
'nid' => array('type' => 'int', 'unsigned' => TRUE, 'not null' => TRUE, 'default' => 0, 'disp-width' => '10'), |
| 80 |
'old_sid' => array('type' => 'int', 'unsigned' => TRUE, 'not null' => TRUE, 'default' => 0, 'disp-width' => '10'), |
'old_sid' => array('type' => 'int', 'unsigned' => TRUE, 'not null' => TRUE, 'default' => 0, 'disp-width' => '10'), |
| 81 |
'sid' => array('type' => 'int', 'unsigned' => TRUE, 'not null' => TRUE, 'default' => 0, 'disp-width' => '10'), |
'sid' => array('type' => 'int', 'unsigned' => TRUE, 'not null' => TRUE, 'default' => 0, 'disp-width' => '10'), |
| 399 |
// Test to see if the autoincrement attribute is present. |
// Test to see if the autoincrement attribute is present. |
| 400 |
switch ($GLOBALS['db_type']) { |
switch ($GLOBALS['db_type']) { |
| 401 |
case 'mysqli': |
case 'mysqli': |
| 402 |
case 'mysql': |
case 'mysql': |
| 403 |
$workflows = db_result(db_query("SHOW COLUMNS FROM {workflows} WHERE field = 'wid' and extra REGEXP 'auto_increment'")); |
$workflows = db_result(db_query("SHOW COLUMNS FROM {workflows} WHERE field = 'wid' and extra REGEXP 'auto_increment'")); |
| 404 |
$workflow_states = db_result(db_query("SHOW COLUMNS FROM {workflow_states} WHERE field = 'sid' and extra REGEXP 'auto_increment'")); |
$workflow_states = db_result(db_query("SHOW COLUMNS FROM {workflow_states} WHERE field = 'sid' and extra REGEXP 'auto_increment'")); |
| 405 |
$workflow_transitions = db_result(db_query("SHOW COLUMNS FROM {workflow_transitions} WHERE field = 'tid' and extra REGEXP 'auto_increment'")); |
$workflow_transitions = db_result(db_query("SHOW COLUMNS FROM {workflow_transitions} WHERE field = 'tid' and extra REGEXP 'auto_increment'")); |