c3bc509f3cc374346c7bb5a252bfeadfa598476b
[motion2.git] / server / api / openchannelQueue / openchannelQueue.socket.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 _0x072f=['register','./openchannelQueue.events','save','emit','removeListener'];(function(_0x21858c,_0x7b23f9){var _0x2a5165=function(_0x2dffbf){while(--_0x2dffbf){_0x21858c['push'](_0x21858c['shift']());}};_0x2a5165(++_0x7b23f9);}(_0x072f,0x105));var _0xf072=function(_0x237351,_0x1dcf88){_0x237351=_0x237351-0x0;var _0x3de11f=_0x072f[_0x237351];return _0x3de11f;};'use strict';var OpenchannelQueueEvents=require(_0xf072('0x0'));var events=[_0xf072('0x1'),'remove','update'];function createListener(_0x375854,_0x239b67){return function(_0x48f6d8){_0x239b67[_0xf072('0x2')](_0x375854,_0x48f6d8);};}function removeListener(_0x52a7ef,_0x119e7a){return function(){OpenchannelQueueEvents[_0xf072('0x3')](_0x52a7ef,_0x119e7a);};}exports[_0xf072('0x4')]=function(_0x3e697d){for(var _0x208fcf=0x0,_0x292a1c=events['length'];_0x208fcf<_0x292a1c;_0x208fcf++){var _0x28ba4c=events[_0x208fcf];var _0x56c411=createListener('openchannelQueue:'+_0x28ba4c,_0x3e697d);OpenchannelQueueEvents['on'](_0x28ba4c,_0x56c411);}};