From 562c4ead15e5194d3cc9fd679f4879eef98c8659 Mon Sep 17 00:00:00 2001 From: Sean Chen Date: Tue, 29 Jan 2013 14:37:32 -0500 Subject: [PATCH] These changes will break the constrains introduced by the default workflow. We assume the workflow will be customized to remove set ownere operation for reassign and accept actions. --- wp-trac-client/actions.php | 14 ++++++++++++++ wp-trac-client/templates/page-ticket-details.php | 4 ++-- wp-trac-client/widgets.php | 11 +++++++++-- 3 files changed, 25 insertions(+), 4 deletions(-) diff --git a/wp-trac-client/actions.php b/wp-trac-client/actions.php index 1d03034..ad695b0 100644 --- a/wp-trac-client/actions.php +++ b/wp-trac-client/actions.php @@ -1,4 +1,5 @@ user_login; break; case 'resolve': // resove to a resolution. @@ -92,6 +105,7 @@ function wptc_analyze_workflow_action() { case 'reassign': // reassign to another person. $attributes['status'] = 'assigned'; + // set owner to selected user. $attributes['owner'] = $_POST['action_reassign_reassign_owner']; break; diff --git a/wp-trac-client/templates/page-ticket-details.php b/wp-trac-client/templates/page-ticket-details.php index 4e18fe5..0725a09 100644 --- a/wp-trac-client/templates/page-ticket-details.php +++ b/wp-trac-client/templates/page-ticket-details.php @@ -51,11 +51,11 @@ '; var_dump($ticket); echo ''; diff --git a/wp-trac-client/widgets.php b/wp-trac-client/widgets.php index 9de5853..552c7c8 100644 --- a/wp-trac-client/widgets.php +++ b/wp-trac-client/widgets.php @@ -472,10 +472,17 @@ function wptc_widget_action_reassign($action) { //$options = wptc_widget_options_html($fields[2], $fields[1]); // the resolve is a select element. // it will be disabled untile the radio button is selected. + + // The following is the right one for default workflow, + // which has the **set_owner** operation for reassign + // action. +// $select = << -{$options} + EOT; return apply_filters('wptc_widget_action_reassign', $select);