Skip to content

Commit

Permalink
Retire bug_change_status_page_fields config option
Browse files Browse the repository at this point in the history
Fixes #26778

Signed-off-by: Victor Boctor <[email protected]>
  • Loading branch information
vboctor committed Mar 15, 2020
1 parent d92b78f commit 690ae29
Show file tree
Hide file tree
Showing 8 changed files with 6 additions and 143 deletions.
1 change: 0 additions & 1 deletion bug_change_status_page.php
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,6 @@
$t_mantis_dir = dirname( __FILE__ ) . DIRECTORY_SEPARATOR;
$t_show_page_header = false;
$t_force_readonly = true;
$t_fields_config_option = 'bug_change_status_page_fields';

if( $t_bug->project_id != helper_get_current_project() ) {
# in case the current project is not the same project of the bug we are viewing...
Expand Down
1 change: 0 additions & 1 deletion bug_relationship_graph.php
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,6 @@

<?php
$_GET['id'] = $f_bug_id;
$t_fields_config_option = 'bug_view_page_fields';
$t_show_page_header = false;
$t_force_readonly = true;
$t_mantis_dir = dirname( __FILE__ ) . DIRECTORY_SEPARATOR;
Expand Down
1 change: 0 additions & 1 deletion bug_reminder_page.php
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,6 @@ class="form-control <?php echo $t_bugnote_class; ?>"></textarea>

<?php
$_GET['id'] = $f_bug_id;
$t_fields_config_option = 'bug_view_page_fields';
$t_show_page_header = false;
$t_force_readonly = true;
$t_mantis_dir = dirname( __FILE__ ) . DIRECTORY_SEPARATOR;
Expand Down
6 changes: 2 additions & 4 deletions bugnote_view_inc.php
Original file line number Diff line number Diff line change
Expand Up @@ -72,10 +72,8 @@
&& access_has_bug_level( config_get( 'time_tracking_view_threshold' ), $f_bug_id );

# get attachments data
if( !isset( $t_fields ) ) {
$t_fields = config_get( $t_fields_config_option );
$t_fields = columns_filter_disabled( $t_fields );
}
$t_fields = config_get( 'bug_view_page_fields' );
$t_fields = columns_filter_disabled( $t_fields );

$t_show_attachments = in_array( 'attachments', $t_fields );

Expand Down
79 changes: 0 additions & 79 deletions config_defaults_inc.php
Original file line number Diff line number Diff line change
Expand Up @@ -2590,84 +2590,6 @@
'view_state',
);

/**
* An array of optional fields to show on the bug change status page. This
* only changes the visibility of fields shown below the form used for
* updating the status of an issue.
*
* The following optional fields are allowed:
* - additional_info
* - attachments
* - category_id
* - date_submitted
* - description
* - due_date
* - eta
* - fixed_in_version
* - handler
* - id
* - last_updated
* - os
* - os_version
* - platform
* - priority
* - product_build
* - product_version
* - project
* - projection
* - reporter
* - reproducibility
* - resolution
* - severity
* - status
* - steps_to_reproduce
* - summary
* - tags
* - target_version
* - view_state
*
* Fields not listed above cannot be shown on the bug change status page.
* Visibility of custom fields is handled via the Manage =>
* Manage Custom Fields administrator page (use the same settings as the
* bug view page).
*
* This setting can be set on a per-project basis by using the
* Manage => Manage Configuration administrator page.
*
* @global array $g_bug_change_status_page_fields
*/
$g_bug_change_status_page_fields = array(
'additional_info',
'attachments',
'category_id',
'date_submitted',
'description',
'due_date',
'eta',
'fixed_in_version',
'handler',
'id',
'last_updated',
'os',
'os_version',
'platform',
'priority',
'product_build',
'product_version',
'project',
'projection',
'reporter',
'reproducibility',
'resolution',
'severity',
'status',
'steps_to_reproduce',
'summary',
'tags',
'target_version',
'view_state',
);

##########################
# MantisBT Misc Settings #
##########################
Expand Down Expand Up @@ -4441,7 +4363,6 @@
'backward_year_count',
'bottom_include_page',
'bug_assigned_status',
'bug_change_status_page_fields',
'bug_closed_status_threshold',
'bug_count_hyperlink_prefix',
'bug_duplicate_resolution',
Expand Down
3 changes: 3 additions & 0 deletions core/obsolete.php
Original file line number Diff line number Diff line change
Expand Up @@ -226,3 +226,6 @@

# changes in 2.21.0
config_obsolete( 'my_view_boxes_fixed_position' );

# changes in 2.24.0
config_obsolete( 'bug_change_status_page_fields', 'bug_view_page_fields' );
57 changes: 1 addition & 56 deletions docbook/Admin_Guide/en-US/config/fields.xml
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@
<term>$g_bug_view_page_fields</term>
<listitem>
<para>
An array of optional fields to show on the bug view page.
An array of optional fields to show on the issue view page and other pages that include issue details.
</para>
<para>
The following optional fields are allowed:
Expand Down Expand Up @@ -183,60 +183,5 @@
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>$g_bug_change_status_page_fields</term>
<listitem>
<para>
An array of optional fields to show on the bug change
status page. This only changes the visibility of
fields shown below the form used for updating the
status of an issue.
</para>
<para>
The following optional fields are allowed:
additional_info,
attachments,
category_id,
date_submitted,
description,
due_date,
eta,
fixed_in_version,
handler,
id,
last_updated,
os,
os_version,
platform,
priority,
product_build,
product_version,
project,
projection,
reporter,
reproducibility,
resolution,
severity,
status,
steps_to_reproduce,
summary,
tags,
target_version,
view_state.
</para>
<para>
Fields not listed above cannot be shown on the bug
change status page. Visibility of custom fields is
handled via the Manage =&gt; Manage Custom Fields
administrator page (use the same settings as the bug
view page).
</para>
<para>
This setting can be set on a per-project basis by
using the Manage =&gt; Manage Configuration
administrator page.
</para>
</listitem>
</varlistentry>
</variablelist>
</section>
1 change: 0 additions & 1 deletion view.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@
$t_mantis_dir = dirname( __FILE__ ) . DIRECTORY_SEPARATOR;
$t_show_page_header = true;
$t_force_readonly = false;
$t_fields_config_option = 'bug_view_page_fields';

define( 'BUG_VIEW_INC_ALLOW', true );
include( dirname( __FILE__ ) . '/bug_view_inc.php' );

0 comments on commit 690ae29

Please sign in to comment.