1 // *************************************************************************
3 // * xCALLY Motion - The Omnichannel Contact Center *
4 // * Copyright (c) Xenialab s.r.l. All Rights Reserved *
6 // *************************************************************************
8 // * Email: info@xcally.com *
9 // * Website: https://www.xcally.com *
11 // *************************************************************************
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. *
17 // *************************************************************************
18 var _0xda3c=['FaxQueue','update','remove','emit','hook','exports','events','../../mysqldb'];(function(_0x118128,_0x386510){var _0x409438=function(_0x156e29){while(--_0x156e29){_0x118128['push'](_0x118128['shift']());}};_0x409438(++_0x386510);}(_0xda3c,0x106));var _0xcda3=function(_0x4a9fb1,_0x273043){_0x4a9fb1=_0x4a9fb1-0x0;var _0x348672=_0xda3c[_0x4a9fb1];return _0x348672;};'use strict';var EventEmitter=require(_0xcda3('0x0'));var FaxQueue=require(_0xcda3('0x1'))['db'][_0xcda3('0x2')];var FaxQueueEvents=new EventEmitter();FaxQueueEvents['setMaxListeners'](0x0);var events={'afterCreate':'save','afterUpdate':_0xcda3('0x3'),'afterDestroy':_0xcda3('0x4')};function emitEvent(_0xdc6e4d){return function(_0x26ba14,_0x61ca90,_0x3f283f){FaxQueueEvents['emit'](_0xdc6e4d+':'+_0x26ba14['id'],_0x26ba14);FaxQueueEvents[_0xcda3('0x5')](_0xdc6e4d,_0x26ba14);_0x3f283f(null);};}for(var e in events){if(events['hasOwnProperty'](e)){var event=events[e];FaxQueue[_0xcda3('0x6')](e,emitEvent(event));}}module[_0xcda3('0x7')]=FaxQueueEvents;