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 _0xe470=['remove','emit','hasOwnProperty','hook','exports','events','UserVoiceQueueRt','save','update'];(function(_0x102e37,_0x14a181){var _0x35a07c=function(_0x16577f){while(--_0x16577f){_0x102e37['push'](_0x102e37['shift']());}};_0x35a07c(++_0x14a181);}(_0xe470,0x8c));var _0x0e47=function(_0x3b801a,_0x4ec0f2){_0x3b801a=_0x3b801a-0x0;var _0x4dc928=_0xe470[_0x3b801a];return _0x4dc928;};'use strict';var EventEmitter=require(_0x0e47('0x0'));var UserVoiceQueueRt=require('../../mysqldb')['db'][_0x0e47('0x1')];var UserVoiceQueueRtEvents=new EventEmitter();UserVoiceQueueRtEvents['setMaxListeners'](0x0);var events={'afterCreate':_0x0e47('0x2'),'afterUpdate':_0x0e47('0x3'),'afterDestroy':_0x0e47('0x4')};function emitEvent(_0x1401ea){return function(_0xad9626,_0x5a9c48,_0x4c2c86){UserVoiceQueueRtEvents[_0x0e47('0x5')](_0x1401ea+':'+_0xad9626['id'],_0xad9626);UserVoiceQueueRtEvents[_0x0e47('0x5')](_0x1401ea,_0xad9626);_0x4c2c86(null);};}for(var e in events){if(events[_0x0e47('0x6')](e)){var event=events[e];UserVoiceQueueRt[_0x0e47('0x7')](e,emitEvent(event));}}module[_0x0e47('0x8')]=UserVoiceQueueRtEvents;