Built motion from commit (unavailable).|2.6.0
[motion2.git] / server / services / ami / dialer / additionalPhone.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 _0x4ede=['callbackat','ContactId','ListId','UserId','VoiceQueueId','CampaignId','originatecalleridnum','originatecalleridname','exports','lodash','moment','milliseconds','diff','seconds','uniqueid','scheduledat','type','campaigntype','countbusyretry','countcongestionretry','countnoanswerretry','countglobal','countnosuchnumberretry','countdropretry','countabandonedretry','countmachineretry','countagentrejectretry','queue','calleridname','name','calleridnum','number','responsetime','endtime','holdtime','talktime','callback','callbackuniqueid'];(function(_0x434783,_0xff395d){var _0x13efcf=function(_0x235dac){while(--_0x235dac){_0x434783['push'](_0x434783['shift']());}};_0x13efcf(++_0xff395d);}(_0x4ede,0x1ab));var _0xe4ed=function(_0x2c91e9,_0x2fb965){_0x2c91e9=_0x2c91e9-0x0;var _0x13f0ff=_0x4ede[_0x2c91e9];return _0x13f0ff;};'use strict';var util=require('util');var _=require(_0xe4ed('0x0'));var moment=require(_0xe4ed('0x1'));function getSeconds(_0x5401ae,_0x518e78){var _0x4ce636=moment(_0x5401ae)[_0xe4ed('0x2')](0x0);var _0x5697bf=moment(_0x518e78)['milliseconds'](0x0);return _0x4ce636[_0xe4ed('0x3')](_0x5697bf,_0xe4ed('0x4'));}function AdditionalPhone(_0x1c0cda){this['uniqueid']=_0x1c0cda[_0xe4ed('0x5')];this['scheduledat']=_0x1c0cda[_0xe4ed('0x6')]||undefined;this[_0xe4ed('0x7')]=_0x1c0cda[_0xe4ed('0x7')];this[_0xe4ed('0x8')]=_0x1c0cda[_0xe4ed('0x7')]==='outbound'?'queue':_0x1c0cda[_0xe4ed('0x7')];this[_0xe4ed('0x9')]=_0x1c0cda[_0xe4ed('0x9')];this[_0xe4ed('0xa')]=_0x1c0cda['countcongestionretry'];this['countnoanswerretry']=_0x1c0cda[_0xe4ed('0xb')];this[_0xe4ed('0xc')]=_0x1c0cda['countbusyretry']+_0x1c0cda['countcongestionretry']+_0x1c0cda[_0xe4ed('0xb')]+_0x1c0cda[_0xe4ed('0xd')]+_0x1c0cda[_0xe4ed('0xe')]+_0x1c0cda[_0xe4ed('0xf')]+_0x1c0cda[_0xe4ed('0x10')]+_0x1c0cda['countagentrejectretry'];this[_0xe4ed('0xd')]=_0x1c0cda[_0xe4ed('0xd')];this[_0xe4ed('0xe')]=_0x1c0cda[_0xe4ed('0xe')];this[_0xe4ed('0xf')]=_0x1c0cda[_0xe4ed('0xf')];this['countmachineretry']=_0x1c0cda[_0xe4ed('0x10')];this[_0xe4ed('0x11')]=_0x1c0cda[_0xe4ed('0x11')];this[_0xe4ed('0x12')]=_0x1c0cda['queue'];this[_0xe4ed('0x13')]=_0x1c0cda[_0xe4ed('0x14')];this[_0xe4ed('0x15')]=_0x1c0cda[_0xe4ed('0x16')];this['starttime']=_0x1c0cda['starttime'];this[_0xe4ed('0x17')]=_0x1c0cda[_0xe4ed('0x17')];this[_0xe4ed('0x18')]=_0x1c0cda['responsetime'];this['ringtime']=getSeconds(_0x1c0cda['responsetime'],_0x1c0cda['starttime']);this[_0xe4ed('0x19')]=0x0;this[_0xe4ed('0x1a')]=0x0;this['callback']=_0x1c0cda[_0xe4ed('0x1b')];this[_0xe4ed('0x1c')]=_0x1c0cda[_0xe4ed('0x1c')];this[_0xe4ed('0x1d')]=_0x1c0cda[_0xe4ed('0x1d')];this['recallme']=_0x1c0cda['recallme'];this[_0xe4ed('0x1e')]=_0x1c0cda[_0xe4ed('0x1e')];this[_0xe4ed('0x1f')]=_0x1c0cda[_0xe4ed('0x1f')];this['UserId']=_0x1c0cda[_0xe4ed('0x20')];this[_0xe4ed('0x21')]=_0x1c0cda[_0xe4ed('0x21')];this[_0xe4ed('0x22')]=_0x1c0cda[_0xe4ed('0x22')];this['originatecalleridnum']=_0x1c0cda[_0xe4ed('0x23')]||'';this[_0xe4ed('0x24')]=_0x1c0cda[_0xe4ed('0x24')]||'';}module[_0xe4ed('0x25')]=History;