From a2e4e618b6c3a1077c9abfa7e9b0ddd94e456618 Mon Sep 17 00:00:00 2001 From: Mark M Date: Fri, 14 Aug 2009 10:33:28 -0400 Subject: [PATCH] Add config option to hide shortcut buttons diff --git a/config_defaults_inc.php b/config_defaults_inc.php index 6535d57..e0ca605 100644 --- a/config_defaults_inc.php +++ b/config_defaults_inc.php @@ -909,6 +909,15 @@ $g_action_button_position = POSITION_BOTTOM; /** + * Show or hide the assign to and change status fields + * on the bug view page. + * Can be: ON or OFF + * @global int $g_hide_shortcut_buttons_ + */ + $g_hide_shortcut_buttons = OFF; + + + /** * show product versions in create, view and update screens * ON forces display even if none are defined * OFF suppresses display diff --git a/core/html_api.php b/core/html_api.php index 03119fd..a3166fc 100644 --- a/core/html_api.php +++ b/core/html_api.php @@ -1580,6 +1580,7 @@ function html_buttons_view_bug_page( $p_bug_id ) { $t_status = bug_get_field( $p_bug_id, 'status' ); $t_readonly = bug_is_readonly( $p_bug_id ); $t_sticky = config_get( 'set_bug_sticky_threshold' ); + $t_hide_shortcut_buttons = config_get( 'hide_shortcut_buttons' ); echo ''; if( !$t_readonly ) { @@ -1587,7 +1588,9 @@ function html_buttons_view_bug_page( $p_bug_id ) { echo ''; + } + if( ( !$t_readonly ) && ( !$t_hide_shortcut_buttons ) ) { # ASSIGN button echo '
'; html_button_bug_update( $p_bug_id ); echo ''; html_button_bug_assign_to( $p_bug_id ); -- 1.6.0.4