case 'bug_status': $field_name = BUG_STATUS; break; case 'assign_to': $field_name = BUG_ASSIGNED_TO; break; case 'assign_to_dev': $field_name = BUG_ASSIGNED_TO_DEVELOPER; break; case 'test_type': } if ($update_db) { # This could become too expensive as we update each bug individually # I'm doing this because we wan't to update the history table for each bug # I can probably find a better way of doing this later bug for now this'll do # UPDATE bug_table WHERE bug_id IN ( 1, 2, 3, 4 ) # Or maybe use a temp table to join the bug_table and history table and run # one update foreach ($ids as $bug_id) { if ($bug_id != '') { bug_update_field($bug_id, $field_name, $value); } } } html_print_operation_successful("bug_page", $redirect_page); # ------------------------------------ # $Log: bug_group_action.php,v $ # Revision 1.1.1.1 2005/11/30 23:00:56 gth2 # importing initial version - gth # # ------------------------------------
} # Need to verify the user entered a valid id and # update the bug table if the user has changed this value if ($current_bug_id != $new_bug_id) { # return the user to the previous page if the new_bug_id doesn't exist in the bug table if (!bug_exists($new_bug_id) && $new_bug_id != 0) { html_redirect($redirect_on_error); } # see if the verify_id exists anywhere in the bug table $related_bug_id = bug_get_bug_id_from_verification_id($verify_id); # remove the old verify_id from the bug table if it exists if (!empty($related_bug_id)) { bug_update_field($related_bug_id, BUG_TEST_VERIFY_ID, $value = ""); } # set the new verify_id in the bug table bug_update_field($new_bug_id, BUG_TEST_VERIFY_ID, $verify_id); } # Update the verify results table results_update_verification($test_run_id, $verify_id, $status, $comments, $new_bug_id); html_print_operation_successful('update_verification', $redirect_page); # --------------------------------------------------------------------- # $Log: results_update_verification_action.php,v $ # Revision 1.3 2006/09/25 12:46:39 gth2 # Working on linking rth and other bugtrackers - gth # # Revision 1.2 2006/01/20 02:36:05 gth2 # enable export to excel functionaltiy - gth # # Revision 1.1.1.1 2005/11/30 23:00:58 gth2 # importing initial version - gth #
function bug_close($bug_id, $closed_reason_code, $bugnote) { # Need to update the status field, who closed the ticket, the date, and closed reason code bug_update_field($bug_id, BUG_CLOSED_REASON_CODE, $closed_reason_code); # add a bugnote only if the user entered a comment if (!empty($bugnote)) { bug_add_bugnote($bug_id, $bugnote); } # Only add record to monitor table and email user if status array is true if ($GLOBALS['default_notify_flags']['status']) { # enter user_id in bug_monitor table and gather recipients to send email $action = "update_status"; bug_monitor_attach_user($bug_id); $recipients = bug_email_collect_recipients($bug_id, $action); if ($recipients != '') { bug_email($project_id, $bug_id, $recipients, $action); } } }