Built motion from commit e0fa946e.|2.6.5
[motion2.git] / server / api / voiceQueueReport / voiceQueueReport.events.js
1 // *************************************************************************
2 // *                                                                       *
3 // * xCALLY Motion -  The Omnichannel Contact Center                       *
4 // * Copyright (c) Xenialab s.r.l. All Rights Reserved                     *
5 // *                                                                       *
6 // *************************************************************************
7 // *                                                                       *
8 // * Email: info@xcally.com                                                *
9 // * Website: https://www.xcally.com                                       *
10 // *                                                                       *
11 // *************************************************************************
12 // *                                                                       *
13 // * The SOFTWARE PRODUCT is protected by copyright laws and international *
14 // * copyright treaties, as well as other intellectual property laws and   *
15 // * treaties. The SOFTWARE PRODUCT is licensed, not sold.                         *
16 // *                                                                       *
17 // *************************************************************************
18 var _0x436a=['save','update','remove','emit','hook','exports','../../mysqldb','VoiceQueueReport','setMaxListeners'];(function(_0x3cae69,_0x233c38){var _0x3128eb=function(_0x21d64e){while(--_0x21d64e){_0x3cae69['push'](_0x3cae69['shift']());}};_0x3128eb(++_0x233c38);}(_0x436a,0x15c));var _0xa436=function(_0x321ddc,_0x58f72a){_0x321ddc=_0x321ddc-0x0;var _0x277f53=_0x436a[_0x321ddc];return _0x277f53;};'use strict';var EventEmitter=require('events');var VoiceQueueReport=require(_0xa436('0x0'))['db'][_0xa436('0x1')];var VoiceQueueReportEvents=new EventEmitter();VoiceQueueReportEvents[_0xa436('0x2')](0x0);var events={'afterCreate':_0xa436('0x3'),'afterUpdate':_0xa436('0x4'),'afterDestroy':_0xa436('0x5')};function emitEvent(_0x27d254){return function(_0x1e197a,_0x4fd4ee,_0x3e39be){VoiceQueueReportEvents[_0xa436('0x6')](_0x27d254+':'+_0x1e197a['id'],_0x1e197a);VoiceQueueReportEvents['emit'](_0x27d254,_0x1e197a);_0x3e39be(null);};}for(var e in events){if(events['hasOwnProperty'](e)){var event=events[e];VoiceQueueReport[_0xa436('0x7')](e,emitEvent(event));}}module[_0xa436('0x8')]=VoiceQueueReportEvents;