From: Glenn H. <thr...@us...> - 2004-08-23 14:48:20
|
Update of /cvsroot/mantisbt/mantisbt/core In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv14562/core Modified Files: bug_api.php email_api.php Log Message: fix for 0003766: [email] status notifications are confused and confusing This also requires documentation changes. Index: bug_api.php =================================================================== RCS file: /cvsroot/mantisbt/mantisbt/core/bug_api.php,v retrieving revision 1.80 retrieving revision 1.81 diff -u -d -r1.80 -r1.81 --- bug_api.php 18 Aug 2004 13:54:41 -0000 1.80 +++ bug_api.php 23 Aug 2004 14:48:08 -0000 1.81 @@ -804,15 +804,15 @@ # bug assigned if ( $t_old_data->handler_id != $p_bug_data->handler_id ) { - email_generic( $p_bug_id, 'assigned', $t_action_prefix . 'assigned' ); + email_generic( $p_bug_id, 'owner', $t_action_prefix . 'assigned' ); return true; } # status changed if ( $t_old_data->status != $p_bug_data->status ) { $t_status = get_enum_to_string( config_get( 'status_enum_string' ), $p_bug_data->status ); - $t_status = str_replace( ' ', '', $t_status ); - email_generic( $p_bug_id, 'status_' . $t_status, $t_status_prefix . $t_status ); + $t_status = str_replace( ' ', '_', $t_status ); + email_generic( $p_bug_id, $t_status, $t_status_prefix . $t_status ); return true; } Index: email_api.php =================================================================== RCS file: /cvsroot/mantisbt/mantisbt/core/email_api.php,v retrieving revision 1.97 retrieving revision 1.98 diff -u -d -r1.97 -r1.98 --- email_api.php 21 Aug 2004 13:07:14 -0000 1.97 +++ email_api.php 23 Aug 2004 14:48:08 -0000 1.98 @@ -214,6 +214,7 @@ $count = db_num_rows( $result ); for( $i=0 ; $i < $count ; $i++ ) { $t_user_id = db_result( $result, $i ); + # @@@ (thraxisp) check that user can see bugnotes here $t_recipients[$t_user_id] = true; } } @@ -416,14 +417,14 @@ # send notices when a relationship is ADDED # MASC RELATIONSHIP function email_relationship_added( $p_bug_id ) { - email_generic( $p_bug_id, 'updated', 'email_notification_title_for_action_relationship_added' ); + email_generic( $p_bug_id, 'relation', 'email_notification_title_for_action_relationship_added' ); } # -------------------- # send notices when a relationship is DELETED # MASC RELATIONSHIP function email_relationship_deleted( $p_bug_id ) { - email_generic( $p_bug_id, 'updated', 'email_notification_title_for_action_relationship_deleted' ); + email_generic( $p_bug_id, 'relation', 'email_notification_title_for_action_relationship_deleted' ); } # -------------------- @@ -468,19 +469,19 @@ # -------------------- # send notices when a bug is sponsored function email_sponsorship_added( $p_bug_id ) { - email_generic( $p_bug_id, 'sponsorship_added', 'email_notification_title_for_action_sponsorship_added' ); + email_generic( $p_bug_id, 'sponsor', 'email_notification_title_for_action_sponsorship_added' ); } # -------------------- # send notices when a sponsorship is modified function email_sponsorship_updated( $p_bug_id ) { - email_generic( $p_bug_id, 'sponsorship_updated', 'email_notification_title_for_action_sponsorship_updated' ); + email_generic( $p_bug_id, 'sponsor', 'email_notification_title_for_action_sponsorship_updated' ); } # -------------------- # send notices when a sponsorship is deleted function email_sponsorship_deleted( $p_bug_id ) { - email_generic( $p_bug_id, 'sponsorship_deleted', 'email_notification_title_for_action_sponsorship_deleted' ); + email_generic( $p_bug_id, 'sponsor', 'email_notification_title_for_action_sponsorship_deleted' ); } # -------------------- @@ -511,7 +512,7 @@ # -------------------- # send notices when a bug is ASSIGNED function email_assign( $p_bug_id ) { - email_generic( $p_bug_id, 'assigned', 'email_notification_title_for_action_bug_assigned' ); + email_generic( $p_bug_id, 'owner', 'email_notification_title_for_action_bug_assigned' ); } # -------------------- # send notices when a bug is DELETED |