Different statuses between update and "Change status to"

Get help from other users here.

Moderators: Developer, Contributor

JulesA
Posts: 37
Joined: 11 Feb 2020, 10:01

Different statuses between update and "Change status to"

Post by JulesA »

Hi,

I'm trying to setup a mantis v.2.18.0.

Everything is almost done but I found a difference between the statuses I can pick when I click on "Modify" on a bug and the statutes I can pick when I use the "Change status to" on the same bug.

It's from the status "En Recette"

Here is when I modify :
Image

Here is when I try to "Change status to" :
Image

I have nothing in my mantis_config_table about the workflows, everything is setup using the config_mantis.php.

Here's my config_mantis.php file (about the workflows only, "35:enrecette" is the only we're looking for) :

/* Statuts - Workflow */

$g_status_enum_string = '10:new,11:incompletmetier,13:verifiemoa,14:verifiemoe,15:attenteissue,16:planifie,17:endeveloppement,22:corrige,35:enrecette,52:testreussi,53:ko,90:closed';

$g_status_enum_workflow[NEW_]='11:INCOMPLETMETIER,13:VERIFIEMOA,90:CLOSED';
$g_status_enum_workflow[INCOMPLETMETIER] ='10:NEW_,90:CLOSED';
$g_status_enum_workflow[VERIFIEMOA] ='10:NEW_,14:VERIFIEMOE,15:ATTENTEISSUE';
$g_status_enum_workflow[CORRIGE] ='17:ENDEVELOPPEMENT,35:ENRECETTE';
$g_status_enum_workflow[VERIFIEMOE] ='16:PLANIFIE';
$g_status_enum_workflow[ATTENTEISSUE] ='10:NEW_,14:VERIFIEMOE';
$g_status_enum_workflow[PLANIFIE] ='14:VERIFIEMOE,17:ENDEVELOPPEMENT';
$g_status_enum_workflow[ENDEVELOPPEMENT] ='15:ATTENTEISSUE,22:CORRIGE';
$g_status_enum_workflow[ENRECETTE] ='22:CORRIGE,52:TESTREUSSI,53:KO';
$g_status_enum_workflow[TESTREUSSI] ='10:NEW_,22:CORRIGE,90:CLOSED';
$g_status_enum_workflow[KO] ='10:NEW_';
$g_status_enum_workflow[CLOSED] ='';


Here's what it looks in the GUI :
Image

Thanks for the help.

Feel free to ask for more details.

Kind regards

Jules
Attachments
workflow.PNG
workflow.PNG (4.38 KiB) Viewed 6936 times
change_status_to.PNG
change_status_to.PNG (2.69 KiB) Viewed 6936 times
modify_bug.PNG
modify_bug.PNG (6.24 KiB) Viewed 6936 times
cas
Posts: 1586
Joined: 11 Mar 2006, 16:08
Contact:

Re: Different statuses between update and "Change status to"

Post by cas »

You do need to check the workflow settings, that is where the subsequent statusses are being defined.
Default values you can find in config_defaults_inc.php
You can copy your settings into core/config_inc.php
JulesA
Posts: 37
Joined: 11 Feb 2020, 10:01

Re: Different statuses between update and "Change status to"

Post by JulesA »

Hi,

I'm sorry but I forgot to mention that I copied and pasted the content of my config_mantis.php because my config_inc.php includes the config_mantis.php.

This config_mantis.php file is where I included the workflow definitions.

Kind regards

Jules
cas
Posts: 1586
Joined: 11 Mar 2006, 16:08
Contact:

Re: Different statuses between update and "Change status to"

Post by cas »

Are you sure config_mantis.php is actually included?
Did you also follow the instructions for adding/changing the status list?
JulesA
Posts: 37
Joined: 11 Feb 2020, 10:01

Re: Different statuses between update and "Change status to"

Post by JulesA »

Yes, sure.

Adding / changing the status list ??
What do you mean ?
cas
Posts: 1586
Joined: 11 Mar 2006, 16:08
Contact:

Re: Different statuses between update and "Change status to"

Post by cas »

Check out the chapter Enumerations in the mantis admin guide, page 81 :mrgreen:
JulesA
Posts: 37
Joined: 11 Feb 2020, 10:01

Re: Different statuses between update and "Change status to"

Post by JulesA »

I'm not exactly sure how it solves my problem.

My enumeration is correctly setup right ?

Code: Select all

$g_status_enum_string = '10:new,11:incompletmetier,13:verifiemoa,14:verifiemoe,15:attenteissue,16:planifie,17:endeveloppement,22:corrige,35:enrecette,52:testreussi,53:ko,90:closed';
cas
Posts: 1586
Joined: 11 Mar 2006, 16:08
Contact:

Re: Different statuses between update and "Change status to"

Post by cas »

Well, did you created/updated custom_strings_inc.php and custom_constants_inc.php as described on page 82 of the manual?
JulesA
Posts: 37
Joined: 11 Feb 2020, 10:01

Re: Different statuses between update and "Change status to"

Post by JulesA »

(I did the same trick, I included the custom_strings_mantis.php in the custom_strings_inc.php and same with custom_constants_mantis.php & custom_constants_inc.php)

Yes :
(custom_strings_mantis.php)

Code: Select all

$s_status_enum_string = '10:Ouvert,11:Incomplet Métier,13:Vérifié MOA,14:Vérifié MOE,15:Attente Issue,16:Planifié,17:En Développement,22:Corrigé,35:En Recette,52:Test Réussi,53:K.O.,90:Fermé';
And Yes :
(custom_constants_mantis.php)

Code: Select all

define( 'INCOMPLETMETIER', 11 );
define( 'VERIFIEMOA', 13 );
define( 'VERIFIEMOE', 14 );
define( 'ATTENTEISSUE', 15 );
define( 'PLANIFIE', 16 );
define( 'ENDEVELOPPEMENT', 17 );
define( 'CORRIGE', 22 );
define( 'ENRECETTE', 35 );
define( 'TESTREUSSI', 52 );
define( 'KO', 53 );
cas
Posts: 1586
Joined: 11 Mar 2006, 16:08
Contact:

Re: Different statuses between update and "Change status to"

Post by cas »

Apparently it does not work now, so I would suggest to follow the instructions given instead of using your own logic. :mrgreen:
JulesA
Posts: 37
Joined: 11 Feb 2020, 10:01

Re: Different statuses between update and "Change status to"

Post by JulesA »

I have two mantis environments so sorry, I can't.

Also including a php into another one isn't something special (especially to manage different configurations).
cas
Posts: 1586
Joined: 11 Mar 2006, 16:08
Contact:

Re: Different statuses between update and "Change status to"

Post by cas »

Indeed inclusions are quite normal but since whatever you have is not working, something is failing there.
In addition I am not aware of any bugs in this area so you review your solution or try it the way it has been described.
The latter is definately a good way of debugging your solution :D
JulesA
Posts: 37
Joined: 11 Feb 2020, 10:01

Re: Different statuses between update and "Change status to"

Post by JulesA »

I copied the contents of each file xxxxx_mantis.php into the original ones : xxxxx_inc.php but I still have the same problem :

I can use a workflow when I use "Modify" on a bug instead of using "Change status to" and it gives me an error when I use it (the different statuses in the "Change status to" is the correct one) :
<img>error_1303.PNG</img>
Attachments
error_1303.PNG
error_1303.PNG (18.14 KiB) Viewed 6834 times
cas
Posts: 1586
Joined: 11 Mar 2006, 16:08
Contact:

Re: Different statuses between update and "Change status to"

Post by cas »

Just to be sure, the old issue is gone but now you get error 1303 when using "change status"?
JulesA
Posts: 37
Joined: 11 Feb 2020, 10:01

Re: Different statuses between update and "Change status to"

Post by JulesA »

No, still the same problem. It did not change anything.

As I said, I get this error when I use "Modify" on a bug, then I select the status then I use "Update the info".

This is the original problem !

I got no clue what's going on, it seems like it's part of the remaining config (of my old mantis version, before upgrading)
Post Reply