Built motion from commit eddce310.|2.6.12
[motion2.git] / server / api / openchannelInteraction / openchannelInteraction.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 _0x1230=['openchannelInteraction:','remove','update','removeListener','register','length'];(function(_0x4035a9,_0x52f3c1){var _0x239e39=function(_0x46870f){while(--_0x46870f){_0x4035a9['push'](_0x4035a9['shift']());}};_0x239e39(++_0x52f3c1);}(_0x1230,0x103));var _0x0123=function(_0x66cc96,_0xc22d8d){_0x66cc96=_0x66cc96-0x0;var _0x24cfe2=_0x1230[_0x66cc96];return _0x24cfe2;};'use strict';var OpenchannelInteractionEvents=require('./openchannelInteraction.events');var events=['save',_0x0123('0x0'),_0x0123('0x1')];function createListener(_0x1df1e8,_0x2a1107){return function(_0x28eaa9){_0x2a1107['emit'](_0x1df1e8,_0x28eaa9);};}function removeListener(_0x55f6ec,_0x1f3308){return function(){OpenchannelInteractionEvents[_0x0123('0x2')](_0x55f6ec,_0x1f3308);};}exports[_0x0123('0x3')]=function(_0x50fb3e){for(var _0x3fc58e=0x0,_0x4c0200=events[_0x0123('0x4')];_0x3fc58e<_0x4c0200;_0x3fc58e++){var _0x4f2da1=events[_0x3fc58e];var _0x599c3c=createListener(_0x0123('0x5')+_0x4f2da1,_0x50fb3e);OpenchannelInteractionEvents['on'](_0x4f2da1,_0x599c3c);}};