[Bps-public-commit] rt-extension-automaticassignment branch, master, updated. b55e378efa497dae2496c5ecbbbe33972c071439
Shawn Moore
shawn at bestpractical.com
Wed Aug 17 15:39:50 EDT 2016
The branch, master has been updated
via b55e378efa497dae2496c5ecbbbe33972c071439 (commit)
from e058a9046bf4e7d726d39d85df860374c58ab7a2 (commit)
Summary of changes:
html/Admin/Queues/AutomaticAssignment.html | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)
- Log -----------------------------------------------------------------
commit b55e378efa497dae2496c5ecbbbe33972c071439
Author: Shawn M Moore <shawn at bestpractical.com>
Date: Wed Aug 17 19:40:34 2016 +0000
Warn about no scrips for automatic assignment
diff --git a/html/Admin/Queues/AutomaticAssignment.html b/html/Admin/Queues/AutomaticAssignment.html
index f186828..7f68c72 100644
--- a/html/Admin/Queues/AutomaticAssignment.html
+++ b/html/Admin/Queues/AutomaticAssignment.html
@@ -154,6 +154,26 @@ my $config = $attr ? $attr->Content : {
filters => [],
chooser => { _name => 'Random' },
};
+
+my $scrips = RT::Scrips->new($session{'CurrentUser'});
+$scrips->LimitToQueue($id);
+$scrips->LimitToGlobal;
+my $scripactions = $scrips->Join(
+ ALIAS1 => 'main',
+ FIELD1 => 'ScripAction',
+ TABLE2 => 'ScripActions',
+ FIELD2 => 'id',
+);
+$scrips->Limit(
+ ALIAS => $scripactions,
+ FIELD => 'ExecModule',
+ OPERATOR => 'IN',
+ VALUE => ['AutomaticAssignment', 'AutomaticReassignment'],,
+);
+
+if ($scrips->Count == 0) {
+ push @results, "No scrips for automatic assignment are applied to this queue. Please see the AutomaticAssignment documentation for setup instructions.";
+}
</%INIT>
<%ARGS>
$id => undef
-----------------------------------------------------------------------
More information about the Bps-public-commit
mailing list