[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Phpgroupware-cvs] [19058] cleanup setup from bad commit a long time ago
From: |
Dave Hall |
Subject: |
[Phpgroupware-cvs] [19058] cleanup setup from bad commit a long time ago - tts should now be installable - yay\! |
Date: |
Wed, 11 Feb 2009 08:07:50 +0000 |
Revision: 19058
http://svn.sv.gnu.org/viewvc/?view=rev&root=phpgroupware&revision=19058
Author: skwashd
Date: 2009-02-11 08:07:49 +0000 (Wed, 11 Feb 2009)
Log Message:
-----------
cleanup setup from bad commit a long time ago - tts should now be installable -
yay\!
Modified Paths:
--------------
branches/Version-0_9_16-branch/tts/setup/default_records.inc.php
branches/Version-0_9_16-branch/tts/setup/setup.inc.php
branches/Version-0_9_16-branch/tts/setup/tables_baseline.inc.php
branches/Version-0_9_16-branch/tts/setup/tables_current.inc.php
branches/Version-0_9_16-branch/tts/setup/tables_update.inc.php
Modified: branches/Version-0_9_16-branch/tts/setup/default_records.inc.php
===================================================================
--- branches/Version-0_9_16-branch/tts/setup/default_records.inc.php
2009-02-04 18:14:26 UTC (rev 19057)
+++ branches/Version-0_9_16-branch/tts/setup/default_records.inc.php
2009-02-11 08:07:49 UTC (rev 19058)
@@ -1,12 +1,51 @@
<?php
- /**
- * Trouble Ticket System - Setup
- *
- * @copyright Copyright (C) 2001-2005 Free Software Foundation, Inc.
http://www.fsf.org/
- * @license http://www.gnu.org/licenses/gpl.html GNU General Public
License
- * @package tts
- * @subpackage setup
- * @version $Id$
- */
+
/**************************************************************************\
+ * phpGroupWare - Trouble Ticket System
*
+ * http://www.phpgroupware.org
*
+ * --------------------------------------------
*
+ * This program is free software; you can redistribute it and/or modify
it *
+ * under the terms of the GNU General Public License as published by
the *
+ * Free Software Foundation; either version 2 of the License, or (at
your *
+ * option) any later version.
*
+
\**************************************************************************/
+ /* $Id$ */
+ $GLOBALS['phpgw_setup']->oProc->query('INSERT into phpgw_categories
(cat_main,cat_parent,cat_level,cat_owner,cat_access,cat_appname,cat_name,cat_description,cat_data)'
+
. " values(0,0,0,-1,'public','tts','Platform','Global category for
tts','platform')",__LINE__,__FILE__);
+ $GLOBALS['phpgw_setup']->oProc->query("SELECT cat_id from
phpgw_categories where cat_name='Platform' and cat_owner=-1 and
cat_appname='tts'",__LINE__,__FILE__);
+ if($GLOBALS['phpgw_setup']->oProc->next_record())
+ {
+ $main = $GLOBALS['phpgw_setup']->oProc->f('cat_id');
+ }
+ $main = intval($main);
+
+ $GLOBALS['phpgw_setup']->oProc->query('UPDATE phpgw_categories set
cat_main=' . $main . ' where cat_id=' . $main,__LINE__,__FILE__);
+
+ $GLOBALS['phpgw_setup']->oProc->query('INSERT into phpgw_categories
(cat_main,cat_parent,cat_level,cat_owner,cat_access,cat_appname,cat_name,cat_description,cat_data)'
+
. ' values('. $main . ',' . $main . ",1,-1,'public','tts','Linux','Global
category for tts','platform')",__LINE__,__FILE__);
+
+ $GLOBALS['phpgw_setup']->oProc->query('INSERT into phpgw_categories
(cat_main,cat_parent,cat_level,cat_owner,cat_access,cat_appname,cat_name,cat_description,cat_data)'
+
. ' values('. $main . ',' . $main . ",1,-1,'public','tts','Windows','Global
category for tts','platform')",__LINE__,__FILE__);
+
+ $GLOBALS['phpgw_setup']->oProc->query('INSERT into phpgw_categories
(cat_main,cat_parent,cat_level,cat_owner,cat_access,cat_appname,cat_name,cat_description,cat_data)'
+
. ' values('. $main . ',' . $main . ",1,-1,'public','tts','MacOS','Global
category for tts','platform')",__LINE__,__FILE__);
+
+
+ $GLOBALS['phpgw_setup']->oProc->query('INSERT into phpgw_categories
(cat_main,cat_parent,cat_level,cat_owner,cat_access,cat_appname,cat_name,cat_description,cat_data)'
+
. " values(0,0,0,-1,'public','tts','Type','Global category for
tts','type')",__LINE__,__FILE__);
+
+ $GLOBALS['phpgw_setup']->oProc->query("SELECT cat_id from
phpgw_categories where cat_name='Type' and cat_owner=-1 and
cat_appname='tts'",__LINE__,__FILE__);
+ if($GLOBALS['phpgw_setup']->oProc->next_record())
+ {
+ $main = $GLOBALS['phpgw_setup']->oProc->f('cat_id');
+ }
+ $main = intval($main);
+
+ $GLOBALS['phpgw_setup']->oProc->query('UPDATE phpgw_categories set
cat_main=' . $main . ' where cat_id=' . $main,__LINE__,__FILE__);
+
+ $GLOBALS['phpgw_setup']->oProc->query('INSERT into phpgw_categories
(cat_main,cat_parent,cat_level,cat_owner,cat_access,cat_appname,cat_name,cat_description,cat_data)'
+
. ' values('. $main . ',' . $main . ",1,-1,'public','tts','Bug','Global
category for tts','type')",__LINE__,__FILE__);
+
+ $GLOBALS['phpgw_setup']->oProc->query('INSERT into phpgw_categories
(cat_main,cat_parent,cat_level,cat_owner,cat_access,cat_appname,cat_name,cat_description,cat_data)'
+
. ' values('. $main . ',' . $main . ",1,-1,'public','tts','Feature
Request','Global category for tts','type')",__LINE__,__FILE__);
Modified: branches/Version-0_9_16-branch/tts/setup/setup.inc.php
===================================================================
--- branches/Version-0_9_16-branch/tts/setup/setup.inc.php 2009-02-04
18:14:26 UTC (rev 19057)
+++ branches/Version-0_9_16-branch/tts/setup/setup.inc.php 2009-02-11
08:07:49 UTC (rev 19058)
@@ -1,6 +1,6 @@
<?php
/**************************************************************************\
- * phpGroupWare - Addressbook
*
+ * phpGroupWare - Trouble Ticket System
*
* http://www.phpgroupware.org
*
* --------------------------------------------
*
* This program is free software; you can redistribute it and/or modify
it *
@@ -37,4 +37,3 @@
'appname' => 'phpgwapi',
'versions' => Array('0.9.13','0.9.14', '0.9.16')
);
-?>
Modified: branches/Version-0_9_16-branch/tts/setup/tables_baseline.inc.php
===================================================================
--- branches/Version-0_9_16-branch/tts/setup/tables_baseline.inc.php
2009-02-04 18:14:26 UTC (rev 19057)
+++ branches/Version-0_9_16-branch/tts/setup/tables_baseline.inc.php
2009-02-11 08:07:49 UTC (rev 19058)
@@ -1,14 +1,16 @@
<?php
- /**
- * Trouble Ticket System - Setup
- *
- * @copyright Copyright (C) 2001,2005 Free Software Foundation, Inc.
http://www.fsf.org/
- * @license http://www.gnu.org/licenses/gpl.html GNU General Public
License
- * @package tts
- * @subpackage setup
- * @version $Id$
- */
+ /**************************************************************************\
+ * phpGroupWare - Trouble Ticket System *
+ * http://www.phpgroupware.org *
+ * -------------------------------------------- *
+ * This program is free software; you can redistribute it and/or modify it *
+ * under the terms of the GNU General Public License as published by the *
+ * Free Software Foundation; either version 2 of the License, or (at your *
+ * option) any later version. *
+ \**************************************************************************/
+ /* $Id$ */
+
$phpgw_baseline = array(
'ticket' => array(
'fd' => array(
Modified: branches/Version-0_9_16-branch/tts/setup/tables_current.inc.php
===================================================================
--- branches/Version-0_9_16-branch/tts/setup/tables_current.inc.php
2009-02-04 18:14:26 UTC (rev 19057)
+++ branches/Version-0_9_16-branch/tts/setup/tables_current.inc.php
2009-02-11 08:07:49 UTC (rev 19058)
@@ -1,45 +1,46 @@
<?php
- /**
- * Trouble Ticket System - Setup
- *
- * @copyright Copyright (C) 2001-2005 Free Software Foundation, Inc.
http://www.fsf.org/
- * @license http://www.gnu.org/licenses/gpl.html GNU General Public
License
- * @package tts
- * @subpackage setup
- * @version $Id$
- */
+ /**************************************************************************\
+ * phpGroupWare - Trouble Ticket System *
+ * http://www.phpgroupware.org *
+ * -------------------------------------------- *
+ * This program is free software; you can redistribute it and/or modify it *
+ * under the terms of the GNU General Public License as published by the *
+ * Free Software Foundation; either version 2 of the License, or (at your *
+ * option) any later version. *
+ \**************************************************************************/
+ /* $Id$ */
+
$phpgw_baseline = array(
'phpgw_tts_tickets' => array(
'fd' => array(
- 'ticket_id' => array('type' =>
'auto','nullable' => False),
- 'ticket_group' => array('type' =>
'int','precision' => '8','nullable' => True),
- 'ticket_priority' => array('type' =>
'int','precision' => '2','nullable' => False),
- 'ticket_owner' => array('type' =>
'int','precision' => '8','nullable' => True),
- 'ticket_assignedto' => array('type' =>
'int','precision' => '4','nullable' => True),
- 'ticket_subject' => array('type' =>
'varchar','precision' => '255','nullable' => True),
- 'ticket_category' => array('type' =>
'int','precision' => '8','nullable' => True),
- 'ticket_billable_hours' => array('type' =>
'decimal','precision' => '8','scale' => '2','nullable' => False),
- 'ticket_billable_rate' => array('type' =>
'decimal','precision' => '8','scale' => '2','nullable' => False),
- 'ticket_status' => array('type' =>
'char','precision' => '1','nullable' => False),
- 'ticket_details' => array('type' =>
'text','nullable' => False),
- 'ticket_type' => array('type' =>
'int','precision' => '2','nullable' => False),
- 'ticket_deadline' => array('type' =>
'int','precision' => '8','nullable' => False),
- 'ticket_effort' => array('type' =>
'varchar','precision' => '4','nullable' => False),
- 'ticket_lastmod' => array('type' =>
'int','precision' => '8','nullable' => False),
- 'ticket_lastmod_user' => array('type' =>
'int','precision' => '8','nullable' => False),
- 'ticket_request_note' => array('type' =>
'varchar','precision' => '255','nullable' => True)
+ 'ticket_id' => array('type' =>
'auto', 'nullable' => False),
+ 'ticket_group' => array('type' =>
'varchar', 'precision' => 40, 'nullable' => True),
+ 'ticket_priority' => array('type' =>
'int', 'precision' => 2, 'nullable' => False),
+ 'ticket_owner' => array('type' =>
'varchar', 'precision' => 10, 'nullable' => True),
+ 'ticket_assignedto' => array('type' =>
'varchar', 'precision' => 10, 'nullable' => True),
+ 'ticket_subject' => array('type' =>
'varchar', 'precision' => 255, 'nullable' => True),
+ 'ticket_category' => array('type' =>
'varchar', 'precision' => 25, 'nullable' => True),
+ 'ticket_billable_hours' => array('type' =>
'decimal', 'precision' => 8, 'scale' => 2, 'nullable' => False),
+ 'ticket_billable_rate' => array('type' =>
'decimal', 'precision' => 8, 'scale' => 2, 'nullable' => False),
+ 'ticket_status' => array('type' =>
'char','precision' => 1, 'nullable' => False),
+ 'ticket_details' => array('type' =>
'text','nullable' => False),
+ 'ticket_type' => array('type' =>
'int', 'precision' => 2, 'nullable' => False),
+ 'ticket_deadline' => array('type' =>
'varchar', 'precision' => 10, 'nullable' => False),
+ 'ticket_effort' => array('type' =>
'varchar', 'precision' => 4, 'nullable' => False),
+ 'ticket_platform' => array('type' =>
'int', 'precision' => 2, 'nullable' => False),
+ 'ticket_attachment' => array('type' =>
'int', 'precision' => 2, 'nullable' => False)
),
'pk' => array('ticket_id'),
+ 'ix' => array(),
'fk' => array(),
- 'ix' =>
array('ticket_group','ticket_owner','ticket_assignedto','ticket_subject','ticket_category','ticket_status','ticket_deadline'),
'uc' => array()
),
'phpgw_tts_views' => array(
'fd' => array(
- 'view_id' => array('type' => 'int','precision'
=> '4','nullable' => False),
- 'view_account_id' => array('type' =>
'varchar','precision' => '40','nullable' => True),
- 'view_time' => array('type' =>
'int','precision' => '4','nullable' => False)
+ 'view_id' => array('type' => 'int',
'precision' => 4, 'nullable' => False),
+ 'view_account_id' => array('type' =>
'varchar', 'precision' => 40, 'nullable' => True),
+ 'view_time' => array('type' => 'int',
'precision' => 4, 'nullable' => False)
),
'pk' => array(),
'ix' => array(),
Modified: branches/Version-0_9_16-branch/tts/setup/tables_update.inc.php
===================================================================
--- branches/Version-0_9_16-branch/tts/setup/tables_update.inc.php
2009-02-04 18:14:26 UTC (rev 19057)
+++ branches/Version-0_9_16-branch/tts/setup/tables_update.inc.php
2009-02-11 08:07:49 UTC (rev 19058)
@@ -1,163 +1,53 @@
<?php
- /**
- * Trouble Ticket System - Setup
- *
- * @copyright Copyright (C) 2001-2005 Free Software Foundation, Inc.
http://www.fsf.org/
- * @license http://www.gnu.org/licenses/gpl.html GNU General Public
License
- * @package tts
- * @subpackage setup
- * @version $Id$
- */
+
/**************************************************************************\
+ * phpGroupWare - Trouble Ticket System
*
+ * http://www.phpgroupware.org
*
+ * --------------------------------------------
*
+ * This program is free software; you can redistribute it and/or modify
it *
+ * under the terms of the GNU General Public License as published by
the *
+ * Free Software Foundation; either version 2 of the License, or (at
your *
+ * option) any later version.
*
+
\**************************************************************************/
+ // $Id$
+ // $Source$
+
/* This is since the last release */
$test[] = '0.9.16';
-
- /**
- * Upgrade from 0.9.16 to 0.9.16.001
- *
- * @return string New version
- */
- function tts_upgrade0_9_16()
+ function phpgwapi_upgrade0_9_16()
{
global $setup_info,$phpgw_setup;
-
$GLOBALS['phpgw_setup']->oProc->AddColumn('phpgw_tts_tickets','ticket_type',array(
+
$GLOBALS['phpgw_setup']->oProc->AddColumn('phpgw_tts_tickets','type',array(
'type' => 'int',
- 'precision' => 2,
- 'nullable' => true
+ 'precision' => '',
+ 'nullable' => True
));
-
$GLOBALS['phpgw_setup']->oProc->AddColumn('phpgw_tts_tickets','ticket_deadline',array(
+
$GLOBALS['phpgw_setup']->oProc->AddColumn('phpgw_tts_tickets','deadline',array(
'type' => 'varchar',
- 'precision' => 10,
- 'nullable' => true
+ 'precision' => '10',
+ 'nullable' => True
));
-
$GLOBALS['phpgw_setup']->oProc->AddColumn('phpgw_tts_tickets','ticket_effort',array(
+
$GLOBALS['phpgw_setup']->oProc->AddColumn('phpgw_tts_tickets','effort',array(
'type' => 'varchar',
- 'precision' => 4,
- 'nullable' => true
+ 'precision' => '4',
+ 'nullable' => True
));
-
$GLOBALS['phpgw_setup']->oProc->AddColumn('phpgw_tts_tickets','ticket_platform',array(
+
$GLOBALS['phpgw_setup']->oProc->AddColumn('phpgw_tts_tickets','platform',array(
'type' => 'int',
- 'precision' => 2,
- 'nullable' => true
+ 'precision' => '',
+ 'nullable' => True
));
-
-
$GLOBALS['phpgw_setup']->oProc->AddColumn('phpgw_tts_tickets','ticket_attachment',array(
+
+
$GLOBALS['phpgw_setup']->oProc->AddColumn('phpgw_tts_tickets','attachment',array(
'type' => 'int',
- 'precision' => 2,
- 'nullable' => false
+ 'precision' => '',
+ 'nullable' => True
));
- $setup_info['tts']['currentver'] = '0.9.16.001';
- return $setup_info['tts']['currentver'];
+ $setup_info['phpgwapi']['currentver'] = '0.9.16.001';
+ return $setup_info['phpgwapi']['currentver'];
}
-
- $test[] = '0.9.16.001';
- function tts_upgrade0_9_16_001() {
- global $setup_info,$phpgw_setup;
-
-
$GLOBALS['phpgw_setup']->oProc->AddColumn('phpgw_tts_tickets','ticket_lastmod',array(
- 'type' => 'int',
- 'precision' => 4,
- 'nullable' => false
- ));
-
- $setup_info['tts']['currentver'] = '0.9.16.002';
- return $setup_info['tts']['currentver'];
- }
-
-
-
- $test[] = '0.9.16.002';
- function tts_upgrade0_9_16_002()
- {
-
$GLOBALS['phpgw_setup']->oProc->DropColumn('phpgw_tts_tickets',array(
- 'fd' => array(
- 'ticket_id' => array('type' =>
'auto','nullable' => False),
- 'ticket_group' => array('type' =>
'varchar','precision' => '40','nullable' => True),
- 'ticket_priority' => array('type' =>
'int','precision' => '2','nullable' => False),
- 'ticket_owner' => array('type' =>
'varchar','precision' => '10','nullable' => True),
- 'ticket_assignedto' => array('type' =>
'varchar','precision' => '10','nullable' => True),
- 'ticket_subject' => array('type' =>
'varchar','precision' => '255','nullable' => True),
- 'ticket_category' => array('type' =>
'varchar','precision' => '25','nullable' => True),
- 'ticket_billable_hours' => array('type' =>
'decimal','precision' => '8','scale' => '2','nullable' => False),
- 'ticket_billable_rate' => array('type' =>
'decimal','precision' => '8','scale' => '2','nullable' => False),
- 'ticket_status' => array('type' =>
'char','precision' => '1','nullable' => False),
- 'ticket_details' => array('type' =>
'text','nullable' => False),
- 'ticket_type' => array('type' =>
'int','precision' => '2','nullable' => False),
- 'ticket_deadline' => array('type' =>
'varchar','precision' => '10','nullable' => False),
- 'ticket_effort' => array('type' =>
'varchar','precision' => '4','nullable' => False),
- 'ticket_attachment' => array('type' =>
'int','precision' => '2','nullable' => False),
- 'ticket_lastmod' => array('type' =>
'int','precision' => '4','nullable' => False)
- ),
- 'pk' => array('ticket_id'),
- 'ix' => array(),
- 'fk' => array(),
- 'uc' => array()
- ),'ticket_platform');
-
$GLOBALS['phpgw_setup']->oProc->DropColumn('phpgw_tts_tickets',array(
- 'fd' => array(
- 'ticket_id' => array('type' =>
'auto','nullable' => False),
- 'ticket_group' => array('type' =>
'varchar','precision' => '40','nullable' => True),
- 'ticket_priority' => array('type' =>
'int','precision' => '2','nullable' => False),
- 'ticket_owner' => array('type' =>
'varchar','precision' => '10','nullable' => True),
- 'ticket_assignedto' => array('type' =>
'varchar','precision' => '10','nullable' => True),
- 'ticket_subject' => array('type' =>
'varchar','precision' => '255','nullable' => True),
- 'ticket_category' => array('type' =>
'varchar','precision' => '25','nullable' => True),
- 'ticket_billable_hours' => array('type' =>
'decimal','precision' => '8','scale' => '2','nullable' => False),
- 'ticket_billable_rate' => array('type' =>
'decimal','precision' => '8','scale' => '2','nullable' => False),
- 'ticket_status' => array('type' =>
'char','precision' => '1','nullable' => False),
- 'ticket_details' => array('type' =>
'text','nullable' => False),
- 'ticket_type' => array('type' =>
'int','precision' => '2','nullable' => False),
- 'ticket_deadline' => array('type' =>
'varchar','precision' => '10','nullable' => False),
- 'ticket_effort' => array('type' =>
'varchar','precision' => '4','nullable' => False),
- 'ticket_lastmod' => array('type' =>
'int','precision' => '4','nullable' => False)
- ),
- 'pk' => array('ticket_id'),
- 'ix' => array(),
- 'fk' => array(),
- 'uc' => array()
- ),'ticket_attachment');
-
$GLOBALS['phpgw_setup']->oProc->AlterColumn('phpgw_tts_tickets','ticket_group',array(
- 'type' => 'int',
- 'precision' => '8',
- 'nullable' => True
- ));
-
$GLOBALS['phpgw_setup']->oProc->AlterColumn('phpgw_tts_tickets','ticket_owner',array(
- 'type' => 'int',
- 'precision' => '8',
- 'nullable' => True
- ));
-
$GLOBALS['phpgw_setup']->oProc->AlterColumn('phpgw_tts_tickets','ticket_assignedto',array(
- 'type' => 'int',
- 'precision' => '8',
- 'nullable' => True
- ));
-
$GLOBALS['phpgw_setup']->oProc->AlterColumn('phpgw_tts_tickets','ticket_category',array(
- 'type' => 'int',
- 'precision' => '8',
- 'nullable' => True
- ));
-
$GLOBALS['phpgw_setup']->oProc->AlterColumn('phpgw_tts_tickets','ticket_deadline',array(
- 'type' => 'int',
- 'precision' => '8',
- 'nullable' => False
- ));
-
$GLOBALS['phpgw_setup']->oProc->AddColumn('phpgw_tts_tickets','ticket_lastmod_user',array(
- 'type' => 'int',
- 'precision' => '4',
- 'nullable' => False
- ));
-
$GLOBALS['phpgw_setup']->oProc->AddColumn('phpgw_tts_tickets','ticket_request_note',array(
- 'type' => 'varchar',
- 'precision' => '255',
- 'nullable' => True
- ));
-
- $GLOBALS['setup_info']['tts']['currentver'] = '0.9.17.500';
- return $GLOBALS['setup_info']['tts']['currentver'];
- }
-?>
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Phpgroupware-cvs] [19058] cleanup setup from bad commit a long time ago - tts should now be installable - yay\!,
Dave Hall <=