We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6750b61 commit ab49a77Copy full SHA for ab49a77
Client-Side Components/Client Scripts/Count Inactive Users with Active incidents/script.js
@@ -0,0 +1,11 @@
1
+var ga = new GlideAggregate('incident');
2
+ ga.addQuery('active', true);
3
+ ga.addQuery('assigned_to.active', false);
4
+ ga.addAggregate('COUNT', 'assigned_to');
5
+ ga.query();
6
+
7
+ while (ga.next()) {
8
+ var inactiveUser = ga.assigned_to.getDisplayValue();
9
+ var taskCount = ga.getAggregate('COUNT', 'assigned_to');
10
+ gs.info("Inactive user " + inactiveUser + " has " + IncidentCount + " active tasks.");
11
+ }
0 commit comments