Resolution drop down is not displayed while status change

General discussion of Mantis.

Moderators: Developer, Contributor

Post Reply
shanthini.g
Posts: 44
Joined: 31 May 2017, 12:45

Resolution drop down is not displayed while status change

Post by shanthini.g »

Hi

I am using Mantis version 2.3.1

While changing the status of the issues, in some scenarios like from resolved to feedback in bug_change_status_page.php the resolution drop down is not getting displayed.

Could you please suggest in which scenario the resolution dropdown will get displayed and which scenarios it will not.

Thanks
atrol
Site Admin
Posts: 8366
Joined: 26 Mar 2008, 21:37
Location: Germany

Re: Resolution drop down is not displayed while status chang

Post by atrol »

The drop down is displayed if
status >= configuration of ('bug_resolved_status_threshold') AND
(status < configuration of ('bug_closed_status_threshold') OR current_resolution >= configuration of ('bug_resolution_fixed_threshold'))
Please use Search before posting and read the Manual
shanthini.g
Posts: 44
Joined: 31 May 2017, 12:45

Re: Resolution drop down is not displayed while status chang

Post by shanthini.g »

Thanks for your reply.

We changed the below workflow thresholds from 'Resolved' to 'Closed'. We have attached the screen shot for the same.

1. Status where an issue is considered resolved
2. Status where an issue becomes read only

But still this is not working. Please suggest whether we need to change anything additionally.

Thanks
Attachments
MantisWorkFlowThresholds.png
MantisWorkFlowThresholds.png (201.15 KiB) Viewed 9166 times
atrol
Site Admin
Posts: 8366
Joined: 26 Mar 2008, 21:37
Location: Germany

Re: Resolution drop down is not displayed while status chang

Post by atrol »

shanthini.g wrote: We changed the below workflow thresholds from 'Resolved' to 'Closed'.
It seems you did not understand what I wrote.
atrol wrote:The drop down is displayed if
status >= configuration of ('bug_resolved_status_threshold') AND ...
You set bug_resolved_status_threshold to CLOSED, so according to the rule you will see resolution just when setting the status to CLOSED.
Please use Search before posting and read the Manual
Uno-Di-Noi
Posts: 8
Joined: 16 May 2020, 17:58

Re: Resolution drop down is not displayed while status chang

Post by Uno-Di-Noi »

atrol wrote: 31 May 2017, 19:40 The drop down is displayed if
status >= configuration of ('bug_resolved_status_threshold') AND
(status < configuration of ('bug_closed_status_threshold') OR current_resolution >= configuration of ('bug_resolution_fixed_threshold'))
Hello. I'm curious about what is the rationale for that "if"?

We are using MantisBT (v1.2.19) as an Issue Tracking System, and I've noticed that sometimes when closing an Issue the "resolution" drop-down menu does not appear (which I think is what this thread is about).

According to my tests, that happens when the Issue has its status set as "status:new" (10) or "status:assigned" (50), and its resolution is set as "resolution:suspended" (80) or "resolution:not fixable" (50). [Disclaimer: I have trouble mapping that situation to the "if" quoted above, because that "if" looks very abstract to me whereas my tests are very concrete.]

I've just discovered in our Mantis installation that we have some Issues as both "status:closed" (90) and "resolution:suspended" (80). This is a problem, because for our needs, a "status:closed" (90) issue should never be in a "resolution:suspended" (80) resolution, but only in either a "resolution:fixed" (20) or "resolution:no fixable" (50) resolution. I guess we arrived to having those Issues as both "status:closed" (90) and "resolution:suspended" (80) because when the issue was both "assigned" and "suspended" and then the user proceeded to close the Issue the user was not presented with the drop-down menu to change the resolution so the Issue was closed by the user keeping the "suspended" resolution it already had.

This is why I am asking what is the rationale for the "if" quoted above.
Uno-Di-Noi
Posts: 8
Joined: 16 May 2020, 17:58

Re: Resolution drop down is not displayed while status change

Post by Uno-Di-Noi »

Just for the record, I've done this change to our MantisBT 1.2.19: in file "bug_change_status_page.php", I changed this code block:

Code: Select all

<?php
$t_current_resolution = $t_bug->resolution;
$t_bug_is_open = in_array( $t_current_resolution, array( config_get( 'default_bug_resolution' ), config_get( 'bug_reopen_resolution' ) ) );
if ( ( $t_resolved <= $f_new_status ) && ( ( $t_closed > $f_new_status ) || ( $t_bug_is_open ) ) ) { ?>
<!-- Resolution -->
<tr <?php echo helper_alternate_class() ?>>
        <td class="category">
                <?php echo lang_get( 'resolution' ) ?>
        </td>
        <td>
                <select name="resolution">
                        <?php
                                $t_resolution = $t_bug_is_open ? config_get( 'bug_resolution_fixed_threshold' ) : $t_current_resolution;
                                print_enum_string_option_list( "resolution", $t_resolution );
                        ?>
                </select>
        </td>
</tr>
<?php } ?>
so that it now is like this:

Code: Select all

<?php
$t_current_resolution = $t_bug->resolution;
$t_bug_is_open = in_array( $t_current_resolution, array( config_get( 'default_bug_resolution' ), config_get( 'bug_reopen_resolution' ) ) );
/* if ( ( $t_resolved <= $f_new_status ) && ( ( $t_closed > $f_new_status ) || ( $t_bug_is_open ) ) ) { ?> */
// This is so that on closing an Issue always is shown the drop-down menu to choose Resolution.
if ( $t_bug->status !== CLOSED ) { ?>
<!-- Resolution -->
<tr <?php echo helper_alternate_class() ?>>
        <td class="category">
                <?php echo lang_get( 'resolution' ) ?>
        </td>
        <td>
                <select name="resolution">
                        <?php
                                // $t_resolution = $t_bug_is_open ? config_get( 'bug_resolution_fixed_threshold' ) : $t_current_resolution;
                                // This is so that "fixed" resolution is always the first option in the drop-down menu for Resolution.
                                $t_resolution = config_get( 'bug_resolution_fixed_threshold' );
                                print_enum_string_option_list( "resolution", $t_resolution );
                        ?>
                </select>
        </td>
</tr>
<?php } ?>
It works for me, in order to minimize the ocurrence of Issues in both Closed and Suspended state (which is supposed not to happen in our scenario).
airmadina-
Posts: 1
Joined: 02 Jul 2020, 12:44

Re: Resolution drop down is not displayed while status change

Post by airmadina- »

We changed the below workflow thresholds from 'Resolved' to 'Closed'. We have attached the screen shot for the same.

1. Status where an issue is considered resolved
2. Status where an issue becomes read only
John
Post Reply