3 module.exports = function(prefix) {
7 description: 'Detailed queues report',
8 parent: prefix + '_voice_queues',
10 conditions: '{"group":{"operator":"AND","rules":[]}}'
14 description: 'Simple queue calls overview',
15 parent: prefix + '_voice_queues',
16 table: 'report_queue',
17 conditions: '{"group":{"operator":"AND","rules":[]}}'
21 description: 'Detailed report about answered queue calls',
22 parent: prefix + '_voice_queues_answered',
23 table: 'report_agent',
24 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"agentcomplete","value":"1","required":true}]}}'
27 name: 'Calls by Agent',
28 description: 'Agent calls timer Handle time= talk time + ACW time',
29 parent: prefix + '_voice_queues_answered',
30 table: 'report_agent',
31 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"agentcomplete","value":"1","required":true}]}}'
34 name: 'Calls by Queue',
35 description: 'Queue timer Handle Time= Talk Time + AVG TIme',
36 parent: prefix + '_voice_queues_answered',
37 table: 'report_agent',
38 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"agentcomplete","value":"1","required":true}]}}'
41 name: 'Answer Time by Queue',
42 description: 'Queues answer time performance',
43 parent: prefix + '_voice_queues_answered',
44 table: 'report_agent',
45 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"agentcomplete","value":"1","required":true}]}}'
48 name: 'Disconnection Cause',
49 description: 'Summary of the calls disconnection causes',
50 parent: prefix + '_voice_queues_answered',
51 table: 'report_agent',
52 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"agentcomplete","value":"1","required":true}]}}'
55 name: 'Answer Time by Hour',
56 description: 'Answer time by hour',
57 parent: prefix + '_voice_queues_answered',
58 table: 'report_agent',
59 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"agentcomplete","value":"1","required":true}]}}'
63 description: 'Detailed report about the unanswered calls',
64 parent: prefix + '_voice_queues_unanswered',
65 table: 'report_queue',
66 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"queuecallercomplete","value":"0","required":true}]}}'
69 name: 'Unanswered by Queue',
70 description: 'Unanswered calls summary by queue',
71 parent: prefix + '_voice_queues_unanswered',
72 table: 'report_queue',
73 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"queuecallercomplete","value":"0","required":true}]}}'
76 name: 'Unmanaged calls',
77 description: 'Unmanaged calls summary',
78 parent: prefix + '_voice_queues_unanswered',
79 table: 'report_queue',
80 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"queuecallerexit","value":"1","required":true}]}}'
83 name: 'Abandon Time by Queue',
84 description: 'Abandon time performance by queue',
85 parent: prefix + '_voice_queues_unanswered',
86 table: 'report_queue',
87 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"queuecallerabandon","value":"1","required":true}]}}'
90 name: 'Calls by Date',
91 description: 'Queue calls summary by date',
92 parent: prefix + '_voice_queues_distribution',
93 table: 'report_queue',
94 conditions: '{"group":{"operator":"AND","rules":[]}}'
97 name: 'Calls by Hour',
98 description: 'Calls distribution by hour',
99 parent: prefix + '_voice_queues_distribution',
100 table: 'report_queue',
101 conditions: '{"group":{"operator":"AND","rules":[]}}'
104 name: 'Calls by Day',
105 description: 'Calls distribution by day of the month',
106 parent: prefix + '_voice_queues_distribution',
107 table: 'report_queue',
108 conditions: '{"group":{"operator":"AND","rules":[]}}'
111 name: 'Calls by Weekday',
112 description: 'Calls distribution by day of the week',
113 parent: prefix + '_voice_queues_distribution',
114 table: 'report_queue',
115 conditions: '{"group":{"operator":"AND","rules":[]}}'
119 description: 'Calls distribution by queue',
120 parent: prefix + '_voice_queues',
121 table: 'report_queue',
122 conditions: '{"group":{"operator":"AND","rules":[]}}'
126 description: 'Calls detail (cdr)',
127 parent: prefix + '_voice_calls',
128 table: 'report_call',
129 conditions: '{"group":{"operator":"AND","rules":[]}}'
133 description: 'Manual outbound calls detailed report',
134 parent: prefix + '_voice_calls',
135 table: 'report_call',
136 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"type","value":"\'outbound\'","required":true}]}}'
139 name: 'Calls by Type',
140 description: 'Summary report of the calls type',
141 parent: prefix + '_voice_calls',
142 table: 'report_call',
143 conditions: '{"group":{"operator":"AND","rules":[]}}'
146 name: 'Outbound Calls Disposition',
147 description: 'Outbound calls grouped by disposition',
148 parent: prefix + '_voice_calls',
149 table: 'report_call',
150 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"type","value":"\'outbound\'","required":true}]}}'
153 name: 'Outbound Calls by Agent',
154 description: 'Summary of outbound calls grouped by agent',
155 parent: prefix + '_voice_calls',
156 table: 'report_call',
157 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"type","value":"\'outbound\'","required":true}]}}'
160 name: 'Outbound Calls by Date',
161 description: 'Summary of outbound calls grouped by date',
162 parent: prefix + '_voice_calls',
163 table: 'report_call',
164 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"type","value":"\'outbound\'","required":true}]}}'
168 description: 'Agent\'s login time',
169 parent: prefix + '_agents',
170 table: 'report_member',
171 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"type","value":"\'LOGIN\'","required":true},{"condition":"=","field":"channel","value":"\'voice\'","required":true}]}}'
174 name: 'Activities Summary',
175 description: 'Agent\'s activities report',
176 parent: prefix + '_voice_agents',
177 table: 'report_member',
178 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"channel","value":"\'voice\'","required":true}]}}'
181 name: 'Pause Details',
182 description: 'Agents status details',
183 parent: prefix + '_voice_agents',
184 table: 'report_member',
185 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"channel","value":"\'voice\'","required":true},{"condition":"=","field":"type","value":"\'PAUSE\'","required":true}]}}'
189 description: 'Agent\'s status detail',
190 parent: prefix + '_voice_agents',
191 table: 'report_member',
192 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"channel","value":"\'voice\'","required":true}]}}'
196 description: 'Agent\'s pause time',
197 parent: prefix + '_voice_agents',
198 table: 'report_member',
199 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"type","value":"\'PAUSE\'","required":true},{"condition":"=","field":"channel","value":"\'voice\'","required":true}]}}'
203 description: 'CallySquare Summary',
204 parent: prefix + '_voice_callysquare',
205 table: 'report_square',
206 conditions: '{"group":{"operator":"AND","rules":[]}}'
210 description: 'CallySquare Blocks Detail',
211 parent: prefix + '_voice_callysquare',
212 table: 'report_square_details',
213 conditions: '{"group":{"operator":"AND","rules":[]}}'
216 name: 'Rating by Agent',
217 description: 'Records rating by agent',
218 parent: prefix + '_voice_recordings',
219 table: 'voice_recordings',
220 conditions: '{"group":{"operator":"AND","rules":[{"condition":">","field":"rating","value":"0","required":true}]}}'
223 name: 'Rating by Queue',
224 description: 'Records rating by queue',
225 parent: prefix + '_voice_recordings',
226 table: 'voice_recordings',
227 conditions: '{"group":{"operator":"AND","rules":[{"condition":"IS NOT NULL","field":"queue","value":"","required":false},{"condition":">","field":"rating","value":"0","required":true}]}}'
232 parent: prefix + '_bull_queue_campaigns',
233 table: 'cm_hopper_final',
234 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"campaigntype","value":"\'queue\'"}]}}'
237 name: 'Calls Summary',
239 parent: prefix + '_bull_queue_campaigns',
240 table: 'cm_hopper_history',
241 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"campaigntype","value":"\'queue\'"}]}}'
244 name: 'Campaign Calls',
246 parent: prefix + '_bull_queue_campaigns',
247 table: 'cm_hopper_final',
248 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"campaigntype","value":"\'queue\'"}]}}'
251 name: 'List Penetration Rate',
253 parent: prefix + '_bull_queue_campaigns',
254 table: 'cm_hopper_final',
255 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"campaigntype","value":"\'queue\'"}]}}'
260 parent: prefix + '_bull_queue_campaigns',
261 table: 'cm_hopper_final',
262 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"campaigntype","value":"\'queue\'"},{"condition":"=","field":"state","value":"4"}]}}'
265 name: 'Disposition Rate',
267 parent: prefix + '_bull_queue_campaigns',
268 table: 'cm_hopper_final',
269 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"campaigntype","value":"\'queue\'"},{"condition":"IS NOT NULL","field":"disposition","value":""},{"condition":"=","field":"state","value":"4"}]}}'
272 name: 'Agent Disposition Rate',
274 parent: prefix + '_bull_queue_campaigns',
275 table: 'cm_hopper_final',
276 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"campaigntype","value":"\'queue\'"},{"condition":"IS NOT NULL","field":"disposition","value":""},{"condition":"=","field":"state","value":"4"}]}}'
281 parent: prefix + '_bull_ivr_campaigns',
282 table: 'cm_hopper_final',
283 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"campaigntype","value":"\'ivr\'"}]}}'
286 name: 'Calls Summary',
288 parent: prefix + '_bull_ivr_campaigns',
289 table: 'cm_hopper_history',
290 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"campaigntype","value":"\'ivr\'"}]}}'
293 name: 'Campaign Calls',
295 parent: prefix + '_bull_ivr_campaigns',
296 table: 'cm_hopper_final',
297 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"campaigntype","value":"\'ivr\'"}]}}'
300 name: 'List Penetration Rate',
302 parent: prefix + '_bull_ivr_campaigns',
303 table: 'cm_hopper_final',
304 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"campaigntype","value":"\'ivr\'"}]}}'
307 name: 'Website Summary',
308 description: 'Chat interactions by website',
309 parent: prefix + '_chat',
310 table: 'chat_interactions',
311 joins: '[{"parentKey":"ChatWebsiteId","foreignTable":"chat_websites","foreignKey":"id","type":"join"}]'
314 name: 'Website Times',
315 description: 'Chat interaction times by website',
316 parent: prefix + '_chat',
317 table: 'chat_interactions',
318 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"chat_interactions.closed","value":"1"},{"group":{"operator":"OR","rules":[{"condition":"IS NULL","field":"chat_interactions.disposition","value":""},{"group":{"operator":"AND","rules":[{"condition":"!=","field":"chat_interactions.disposition","value":"\'abandoned\'"},{"condition":"!=","field":"chat_interactions.disposition","value":"\'unmanaged\'"}]}}]}}]}}',
319 joins: '[{"parentKey":"ChatWebsiteId","foreignTable":"chat_websites","foreignKey":"id","type":"join"}]'
322 name: 'Chat By Agent',
323 description: 'Chat interactions by agent',
324 parent: prefix + '_chat',
325 table: 'chat_interactions',
326 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"chat_interactions.closed","value":"1"}]}}',
327 joins: '[{"parentKey":"UserId","foreignTable":"users","foreignKey":"id","type":"join"}]'
330 name: 'Chat By Date',
331 description: 'Chat interactions by date',
332 parent: prefix + '_chat',
333 table: 'chat_interactions',
334 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"chat_interactions.closed","value":"1"}]}}'
337 name: 'Chat By Queue',
338 description: 'Chat interactions by queue',
339 parent: prefix + '_chat',
340 table: 'report_chat_queue',
341 joins: '[{"parentKey":"ChatQueueId","foreignTable":"chat_queues","foreignKey":"id","type":"join"}]'
344 name: 'Email Account Summary',
345 description: 'Email interactions by account',
346 parent: prefix + '_mail',
347 table: 'mail_interactions',
348 joins: '[{"parentKey":"MailAccountId","foreignTable":"mail_accounts","foreignKey":"id","type":"join"}]'
351 name: 'Email Account Times',
352 description: 'Email interaction times by account',
353 parent: prefix + '_mail',
354 table: 'mail_interactions',
355 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"mail_interactions.closed","value":"1"},{"group":{"operator":"OR","rules":[{"condition":"!=","field":"mail_interactions.disposition","value":"\'unmanaged\'"},{"condition":"IS NULL","field":"mail_interactions.disposition","value":""}]}}]}}',
356 joins: '[{"parentKey":"MailAccountId","foreignTable":"mail_accounts","foreignKey":"id","type":"join"}]'
359 name: 'Email By Agent',
360 description: 'Email interactions by agent',
361 parent: prefix + '_mail',
362 table: 'mail_interactions',
363 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"mail_interactions.closed","value":"1"}]}}',
364 joins: '[{"parentKey":"UserId","foreignTable":"users","foreignKey":"id","type":"join"}]'
367 name: 'Email By Date',
368 description: 'Email interactions by date',
369 parent: prefix + '_mail',
370 table: 'mail_interactions',
371 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"mail_interactions.closed","value":"1"}]}}'
374 name: 'Email By Queue',
375 description: 'Email interactions by queue',
376 parent: prefix + '_mail',
377 table: 'report_mail_queue',
378 joins: '[{"parentKey":"MailQueueId","foreignTable":"mail_queues","foreignKey":"id","type":"join"}]'
381 name: 'Openchannel Account Summary',
382 description: 'Openchannel interactions by account',
383 parent: prefix + '_openchannel',
384 table: 'openchannel_interactions',
385 joins: '[{"parentKey":"OpenchannelAccountId","foreignTable":"openchannel_accounts","foreignKey":"id","type":"join"}]'
388 name: 'Openchannel Account Times',
389 description: 'Openchannel interaction times by account',
390 parent: prefix + '_openchannel',
391 table: 'openchannel_interactions',
392 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"openchannel_interactions.closed","value":"1"},{"group":{"operator":"OR","rules":[{"condition":"!=","field":"openchannel_interactions.disposition","value":"\'unmanaged\'"},{"condition":"IS NULL","field":"openchannel_interactions.disposition","value":""}]}}]}}',
393 joins: '[{"parentKey":"OpenchannelAccountId","foreignTable":"openchannel_accounts","foreignKey":"id","type":"join"}]'
396 name: 'Openchannel By Agent',
397 description: 'Openchannel interactions by agent',
398 parent: prefix + '_openchannel',
399 table: 'openchannel_interactions',
400 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"openchannel_interactions.closed","value":"1"}]}}',
401 joins: '[{"parentKey":"UserId","foreignTable":"users","foreignKey":"id","type":"join"}]'
404 name: 'Openchannel By Date',
405 description: 'Openchannel interactions by date',
406 parent: prefix + '_openchannel',
407 table: 'openchannel_interactions',
408 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"openchannel_interactions.closed","value":"1"}]}}'
411 name: 'Openchannel By Queue',
412 description: 'Openchannel interactions by queue',
413 parent: prefix + '_openchannel',
414 table: 'report_openchannel_queue',
415 joins: '[{"parentKey":"OpenchannelQueueId","foreignTable":"openchannel_queues","foreignKey":"id","type":"join"}]'
418 name: 'Sms Account Summary',
419 description: 'Sms interactions by account',
420 parent: prefix + '_sms',
421 table: 'sms_interactions',
422 joins: '[{"parentKey":"SmsAccountId","foreignTable":"sms_accounts","foreignKey":"id","type":"join"}]'
425 name: 'Sms Account Times',
426 description: 'Sms interaction times by account',
427 parent: prefix + '_sms',
428 table: 'sms_interactions',
429 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"sms_interactions.closed","value":"1"},{"group":{"operator":"OR","rules":[{"condition":"!=","field":"sms_interactions.disposition","value":"\'unmanaged\'"},{"condition":"IS NULL","field":"sms_interactions.disposition","value":""}]}}]}}',
430 joins: '[{"parentKey":"SmsAccountId","foreignTable":"sms_accounts","foreignKey":"id","type":"join"}]'
433 name: 'Sms By Agent',
434 description: 'Sms interactions by agent',
435 parent: prefix + '_sms',
436 table: 'sms_interactions',
437 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"sms_interactions.closed","value":"1"}]}}',
438 joins: '[{"parentKey":"UserId","foreignTable":"users","foreignKey":"id","type":"join"}]'
442 description: 'Sms interactions by date',
443 parent: prefix + '_sms',
444 table: 'sms_interactions',
445 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"sms_interactions.closed","value":"1"}]}}'
448 name: 'Sms By Queue',
449 description: 'Sms interactions by queue',
450 parent: prefix + '_sms',
451 table: 'report_sms_queue',
452 joins: '[{"parentKey":"SmsQueueId","foreignTable":"sms_queues","foreignKey":"id","type":"join"}]'
455 name: 'Fax Account Summary',
456 description: 'Fax interactions by account',
457 parent: prefix + '_fax',
458 table: 'fax_interactions',
459 joins: '[{"parentKey":"FaxAccountId","foreignTable":"fax_accounts","foreignKey":"id","type":"join"}]'
462 name: 'Fax Account Times',
463 description: 'Fax interaction times by account',
464 parent: prefix + '_fax',
465 table: 'fax_interactions',
466 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"fax_interactions.closed","value":"1"},{"group":{"operator":"OR","rules":[{"condition":"!=","field":"fax_interactions.disposition","value":"\'unmanaged\'"},{"condition":"IS NULL","field":"fax_interactions.disposition","value":""}]}}]}}',
467 joins: '[{"parentKey":"FaxAccountId","foreignTable":"fax_accounts","foreignKey":"id","type":"join"}]'
470 name: 'Fax By Agent',
471 description: 'Fax interactions by agent',
472 parent: prefix + '_fax',
473 table: 'fax_interactions',
474 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"fax_interactions.closed","value":"1"}]}}',
475 joins: '[{"parentKey":"UserId","foreignTable":"users","foreignKey":"id","type":"join"}]'
479 description: 'Fax interactions by date',
480 parent: prefix + '_fax',
481 table: 'fax_interactions',
482 conditions: '{"group":{"operator":"AND","rules":[{"condition":"=","field":"fax_interactions.closed","value":"1"}]}}'
485 name: 'Fax By Queue',
486 description: 'Fax interactions by queue',
487 parent: prefix + '_fax',
488 table: 'report_fax_queue',
489 joins: '[{"parentKey":"FaxQueueId","foreignTable":"fax_queues","foreignKey":"id","type":"join"}]'