d3b814f6700f96ee0cf7249dfdb274baa845306c
[motion2.git] / server / api / dashboard / dashboard.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 _0xb269=['emit','removeListener','register','./dashboard.events','save','remove'];(function(_0x174ef5,_0x256e8e){var _0x1cc379=function(_0x3eafcf){while(--_0x3eafcf){_0x174ef5['push'](_0x174ef5['shift']());}};_0x1cc379(++_0x256e8e);}(_0xb269,0x1b3));var _0x9b26=function(_0x5b644e,_0x2e5e07){_0x5b644e=_0x5b644e-0x0;var _0x49c6bf=_0xb269[_0x5b644e];return _0x49c6bf;};'use strict';var DashboardEvents=require(_0x9b26('0x0'));var events=[_0x9b26('0x1'),_0x9b26('0x2'),'update'];function createListener(_0x2da0ae,_0x11e640){return function(_0x5e343b){_0x11e640[_0x9b26('0x3')](_0x2da0ae,_0x5e343b);};}function removeListener(_0x2d11c0,_0x235a0e){return function(){DashboardEvents[_0x9b26('0x4')](_0x2d11c0,_0x235a0e);};}exports[_0x9b26('0x5')]=function(_0x301562){for(var _0x42b192=0x0,_0x1b0926=events['length'];_0x42b192<_0x1b0926;_0x42b192++){var _0x14b838=events[_0x42b192];var _0x9408b=createListener('dashboard:'+_0x14b838,_0x301562);DashboardEvents['on'](_0x14b838,_0x9408b);}};