Skip to content

Commit

Permalink
- Fixed a warning that showed up twice because the customisation feat…
Browse files Browse the repository at this point in the history
…ure is ON and not used.

- Added the SQL tables to create the new table to the 0.17.x to 0.18.x upgrade script in the admin folder.
- Removed a couple of echo's that were used for debugging and were left there.


git-svn-id: http://mantisbt.svn.sourceforge.net/svnroot/mantisbt/trunk@1187 f5dc347c-c33d-0410-90a0-b07cc1902cb9
  • Loading branch information
vboctor committed Aug 10, 2002
1 parent 75015af commit 2e841fb
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 8 deletions.
22 changes: 21 additions & 1 deletion admin/admin_upgrade_0_18_0.php
Expand Up @@ -6,7 +6,27 @@

# START OF UPGRADE SQL STATEMENTS
# --- LATEST CHANGES SHOULD GO AT THE BOTTOM ---


$upgrade_obj->AddItem( "# Mantis Project Customization" );
$upgrade_obj->AddItem( "CREATE TABLE mantis_project_customization_table ".
"(project_id int(7) unsigned zerofill NOT NULL default '0000000', ".
"priorities varchar(200) NOT NULL default '', ".
"severities varchar(200) NOT NULL default '', ".
"reproducibilities varchar(200) NOT NULL default '', ".
"states varchar(200) NOT NULL default '', ".
"resolutions varchar(200) NOT NULL default '', ".
"projections varchar(200) NOT NULL default '', ".
"etas varchar(200) NOT NULL default '', ".
"colors varchar(160) NOT NULL default '', ".
"KEY project_id (project_id))" );
$upgrade_obj->AddItem();

$upgrade_obj->AddItem( "# Printing Preference Table" );
$upgrade_obj->AddItem( "CREATE TABLE mantis_user_print_pref_table (user_id int(7) unsigned zerofill NOT ".
"NULL default '0000000', print_pref varchar(27) NOT NULL default '', PRIMARY KEY ".
"(user_id))" );
$upgrade_obj->AddItem();

$upgrade_obj->AddItem( "# Bug history" );
$upgrade_obj->AddItem( "ALTER TABLE mantis_bug_history_table ADD type INT(2) NOT NULL" );
$upgrade_obj->AddItem();
Expand Down
15 changes: 8 additions & 7 deletions core_helper_API.php
Expand Up @@ -5,11 +5,11 @@
# See the files README and LICENSE for details

# --------------------------------------------------------
# $Revision: 1.53 $
# $Author: jctrosset $
# $Date: 2002-08-02 08:18:58 $
# $Revision: 1.54 $
# $Author: vboctor $
# $Date: 2002-08-10 11:17:30 $
#
# $Id: core_helper_API.php,v 1.53 2002-08-02 08:18:58 jctrosset Exp $
# $Id: core_helper_API.php,v 1.54 2002-08-10 11:17:30 vboctor Exp $
# --------------------------------------------------------

###########################################################################
Expand Down Expand Up @@ -458,14 +458,15 @@ function get_status_color( $p_status ) {
global $$t_color_variable_name;
if ( isset( $$t_color_variable_name ) ) {
return $$t_color_variable_name;
echo "tiiirii" ;
} elseif ( isset ( $g_status_colors[$t_color_str] ) ) {
return $g_status_colors[$t_color_str];
echo "tato" ;
} elseif ($g_customize_attributes) { // custom attributes
# if not found before, look into custom status colors
$t_colors_arr = attribute_get_all('colors', $t_project_id);
return $t_colors_arr[( $p_status-( $g_custom_status_slot[0]+1 ) )];
$t_offset = ( $p_status-( $g_custom_status_slot[0]+1 ) );
if ( isset( $t_colors_arr[$t_offset ]) ) {
return $t_colors_arr[$t_offset];
}
}
return '#ffffff';
}
Expand Down

0 comments on commit 2e841fb

Please sign in to comment.