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 07aac64 commit 1a317daCopy full SHA for 1a317da
Server-Side Components/Background Scripts/Get incident count based on priority/IncidentCount.js
@@ -0,0 +1,15 @@
1
+(function() {
2
+ var priorities = {};
3
+ var agg = new GlideAggregate('incident');
4
+ agg.addAggregate('COUNT');
5
+ agg.groupBy('priority');
6
+ agg.query();
7
+ while (agg.next()) {
8
+ var priority = agg.getDisplayValue('priority') || 'No Priority Set';
9
+ var count = agg.getAggregate('COUNT');
10
+ priorities[priority] = parseInt(count, 10);
11
+ }
12
+ for (var priority in priorities) {
13
+ gs.info('Priority: ' + priority + ' | Count: ' + priorities[priority]);
14
15
+})();
Server-Side Components/Background Scripts/Get incident count based on priority/README.md
@@ -0,0 +1 @@
+//To get the incident count based on priority.
0 commit comments