View Issue Details

IDProjectCategoryView StatusLast Update
0011953mantisbtcustomizationpublic2010-11-16 12:07
Reportergpardi Assigned To 
PrioritynormalSeverityminorReproducibilityhave not tried
Status newResolutionopen 
Product Version1.2.0 
Summary0011953: Automatically change custom status
Description

Considering to my custom status as below, I'd like to automatically change from "Acceptance" to "Functional Analysis" when user adds a note

$g_status_enum_string = '10:new,20:feedback,60:functional analysis,65:technical analysis,70:acceptance,80:closed with no response,90:closed';

When status is on Feedback, I set $g_reassign_on_feedback = ON and $g_bug_assigned_status = FUNCTIONAL. This settings is working fine when issue is on feddback and status changes automatically to functional analysis when reporter adds a note.

I would like to do the same step when issue in on acceptance and changes to functional analysis by adding a note.

Can you help me how can I create a function to do this?

thank you and best regards.

TagsNo tags attached.

Activities

gpardi

gpardi

2010-11-16 08:23

reporter   ~0027377

Any help?

cas

cas

2010-11-16 10:05

reporter   ~0027378

You can find the routine for feedback in core\bugnote_api.php around line 191 where it says:

if it was FEEDBACK its NEW_ now

if ( config_get( 'reassign_on_feedback' ) && bug_get_field( $p_bug_id, 'status' ) == config_get( 'bug_feedback_status' ) && bug_get_field( $p_bug_id, 'reporter_id' ) == $c_user_id ) {
if ( bug_get_field( $p_bug_id, 'handler_id') == 0 ) {
bug_set_field( $p_bug_id, 'status', config_get( 'bug_submit_status' ) );
} else {
bug_set_field( $p_bug_id, 'status', config_get( 'bug_assigned_status' ) );
}
}
So now you can copy that section and make it work for the automaed action you need.

gpardi

gpardi

2010-11-16 11:25

reporter   ~0027380

Sorry, I couldn't find this part in core\bugnote_api.php in version 1.2.0 RC2

I appreciate your help

cas

cas

2010-11-16 12:07

reporter   ~0027383

well in that case you scan all php scripts for part of this code, then you know where to adjust.
The feeedback routine seems to be working so it is there.
It is there in version 1.2.0 so you could upgrade (always a good idea from a RC)