Built motion from commit 9e1ec266.|2.6.28
[motion2.git] / server / services / ami / dialer / models / agentComplete.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 _0x5af9=['recallme','ContactId','UserId','VoiceQueueId','CampaignId','originatecalleridnum','originatecalleridname','agiafterat','moment','../utils','statedesc','Answer','scheduledat','type','campaigntype','outbound','queue','countbusyretry','countcongestionretry','countnoanswerretry','countglobal','countnosuchnumberretry','countdropretry','countabandonedretry','countmachineretry','countagentrejectretry','uniqueid','calleridname','name','number','starttime','responsetime','answertime','endtime','format','YYYY-MM-DD\x20HH:mm:ss','getSeconds','holdtime','talktime','membername','reason','callback','callbackuniqueid','callbackat'];(function(_0x5ce766,_0x495d80){var _0x4a68f3=function(_0x39aa58){while(--_0x39aa58){_0x5ce766['push'](_0x5ce766['shift']());}};_0x4a68f3(++_0x495d80);}(_0x5af9,0x1ec));var _0x95af=function(_0x12b8ec,_0x1655be){_0x12b8ec=_0x12b8ec-0x0;var _0x21af77=_0x5af9[_0x12b8ec];return _0x21af77;};'use strict';var moment=require(_0x95af('0x0'));var utils=require(_0x95af('0x1'));function AgentComplete(_0x56ae3b,_0x532506){this['state']=0x4;this[_0x95af('0x2')]=_0x95af('0x3');this[_0x95af('0x4')]=_0x56ae3b[_0x95af('0x4')];this['type']=_0x56ae3b[_0x95af('0x5')];this[_0x95af('0x6')]=_0x56ae3b[_0x95af('0x5')]===_0x95af('0x7')?_0x95af('0x8'):_0x56ae3b['type'];this[_0x95af('0x9')]=_0x56ae3b[_0x95af('0x9')];this[_0x95af('0xa')]=_0x56ae3b['countcongestionretry'];this['countnoanswerretry']=_0x56ae3b[_0x95af('0xb')];this[_0x95af('0xc')]=_0x56ae3b[_0x95af('0x9')]+_0x56ae3b[_0x95af('0xa')]+_0x56ae3b['countnoanswerretry']+_0x56ae3b[_0x95af('0xd')]+_0x56ae3b[_0x95af('0xe')]+_0x56ae3b[_0x95af('0xf')]+_0x56ae3b[_0x95af('0x10')]+_0x56ae3b['countagentrejectretry'];this[_0x95af('0xd')]=_0x56ae3b[_0x95af('0xd')];this[_0x95af('0xe')]=_0x56ae3b[_0x95af('0xe')];this[_0x95af('0xf')]=_0x56ae3b[_0x95af('0xf')];this[_0x95af('0x10')]=_0x56ae3b[_0x95af('0x10')];this[_0x95af('0x11')]=_0x56ae3b[_0x95af('0x11')];this[_0x95af('0x12')]=_0x532506['uniqueid'];this[_0x95af('0x13')]=_0x56ae3b[_0x95af('0x14')];this['calleridnum']=_0x56ae3b[_0x95af('0x15')];this[_0x95af('0x16')]=_0x56ae3b[_0x95af('0x16')];this[_0x95af('0x17')]=_0x56ae3b[_0x95af('0x17')];this[_0x95af('0x18')]=_0x56ae3b['answertime'];this[_0x95af('0x19')]=moment()[_0x95af('0x1a')](_0x95af('0x1b'));this['ringtime']=utils[_0x95af('0x1c')](_0x56ae3b['responsetime'],_0x56ae3b[_0x95af('0x16')]);this[_0x95af('0x1d')]=utils[_0x95af('0x1c')](_0x56ae3b['answertime'],_0x56ae3b['responsetime']);this[_0x95af('0x1e')]=utils[_0x95af('0x1c')](this['endtime'],_0x56ae3b[_0x95af('0x18')]);this[_0x95af('0x8')]=_0x532506['queue'];this[_0x95af('0x1f')]=_0x532506[_0x95af('0x1f')];this['reason']=_0x532506[_0x95af('0x20')];this['callback']=_0x56ae3b[_0x95af('0x21')];this[_0x95af('0x22')]=_0x56ae3b['callbackuniqueid'];this[_0x95af('0x23')]=_0x56ae3b[_0x95af('0x23')];this[_0x95af('0x24')]=_0x56ae3b['recallme'];this[_0x95af('0x25')]=_0x56ae3b[_0x95af('0x25')];this['ListId']=_0x56ae3b['ListId'];this[_0x95af('0x26')]=_0x56ae3b[_0x95af('0x26')];this[_0x95af('0x27')]=_0x56ae3b[_0x95af('0x27')];this[_0x95af('0x28')]=_0x56ae3b[_0x95af('0x28')];this[_0x95af('0x29')]=_0x56ae3b[_0x95af('0x29')]||'';this['originatecalleridname']=_0x56ae3b[_0x95af('0x2a')]||'';this[_0x95af('0x2b')]=_0x56ae3b[_0x95af('0x2b')];}module['exports']=AgentComplete;