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 _0xf4bf=['ContactId','UserId','VoiceQueueId','CampaignId','originatecalleridnum','originatecalleridname','lodash','moment','milliseconds','diff','seconds','uniqueid','scheduledat','type','campaigntype','outbound','countbusyretry','countcongestionretry','countnoanswerretry','countdropretry','countabandonedretry','countmachineretry','countagentrejectretry','countnosuchnumberretry','queue','calleridname','name','number','starttime','responsetime','endtime','holdtime','talktime','callback','callbackuniqueid','callbackat','recallme'];(function(_0x22ffde,_0x49995d){var _0x1fe872=function(_0x1ecdf7){while(--_0x1ecdf7){_0x22ffde['push'](_0x22ffde['shift']());}};_0x1fe872(++_0x49995d);}(_0xf4bf,0xe4));var _0xff4b=function(_0x4e21ba,_0x18097f){_0x4e21ba=_0x4e21ba-0x0;var _0x55b94b=_0xf4bf[_0x4e21ba];return _0x55b94b;};'use strict';var util=require('util');var _=require(_0xff4b('0x0'));var moment=require(_0xff4b('0x1'));function getSeconds(_0x531c67,_0x555aee){var _0x1ab779=moment(_0x531c67)['milliseconds'](0x0);var _0x15c0e8=moment(_0x555aee)[_0xff4b('0x2')](0x0);return _0x1ab779[_0xff4b('0x3')](_0x15c0e8,_0xff4b('0x4'));}function AdditionalPhone(_0x590bf3){this[_0xff4b('0x5')]=_0x590bf3[_0xff4b('0x5')];this['scheduledat']=_0x590bf3[_0xff4b('0x6')]||undefined;this[_0xff4b('0x7')]=_0x590bf3[_0xff4b('0x7')];this[_0xff4b('0x8')]=_0x590bf3['type']===_0xff4b('0x9')?'queue':_0x590bf3['type'];this[_0xff4b('0xa')]=_0x590bf3['countbusyretry'];this[_0xff4b('0xb')]=_0x590bf3[_0xff4b('0xb')];this[_0xff4b('0xc')]=_0x590bf3['countnoanswerretry'];this['countglobal']=_0x590bf3[_0xff4b('0xa')]+_0x590bf3['countcongestionretry']+_0x590bf3[_0xff4b('0xc')]+_0x590bf3['countnosuchnumberretry']+_0x590bf3[_0xff4b('0xd')]+_0x590bf3[_0xff4b('0xe')]+_0x590bf3[_0xff4b('0xf')]+_0x590bf3[_0xff4b('0x10')];this['countnosuchnumberretry']=_0x590bf3[_0xff4b('0x11')];this[_0xff4b('0xd')]=_0x590bf3[_0xff4b('0xd')];this[_0xff4b('0xe')]=_0x590bf3[_0xff4b('0xe')];this[_0xff4b('0xf')]=_0x590bf3[_0xff4b('0xf')];this[_0xff4b('0x10')]=_0x590bf3[_0xff4b('0x10')];this[_0xff4b('0x12')]=_0x590bf3[_0xff4b('0x12')];this[_0xff4b('0x13')]=_0x590bf3[_0xff4b('0x14')];this['calleridnum']=_0x590bf3[_0xff4b('0x15')];this['starttime']=_0x590bf3[_0xff4b('0x16')];this[_0xff4b('0x17')]=_0x590bf3[_0xff4b('0x17')];this[_0xff4b('0x18')]=_0x590bf3[_0xff4b('0x17')];this['ringtime']=getSeconds(_0x590bf3[_0xff4b('0x17')],_0x590bf3[_0xff4b('0x16')]);this[_0xff4b('0x19')]=0x0;this[_0xff4b('0x1a')]=0x0;this[_0xff4b('0x1b')]=_0x590bf3[_0xff4b('0x1b')];this[_0xff4b('0x1c')]=_0x590bf3[_0xff4b('0x1c')];this['callbackat']=_0x590bf3[_0xff4b('0x1d')];this['recallme']=_0x590bf3[_0xff4b('0x1e')];this[_0xff4b('0x1f')]=_0x590bf3['ContactId'];this['ListId']=_0x590bf3['ListId'];this[_0xff4b('0x20')]=_0x590bf3['UserId'];this['VoiceQueueId']=_0x590bf3[_0xff4b('0x21')];this[_0xff4b('0x22')]=_0x590bf3[_0xff4b('0x22')];this[_0xff4b('0x23')]=_0x590bf3[_0xff4b('0x23')]||'';this[_0xff4b('0x24')]=_0x590bf3[_0xff4b('0x24')]||'';}module['exports']=History;