Built motion from commit e02f907f.|2.6.14
[motion2.git] / server / services / ami / dialer / models / hangup.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 _0xe991=['statedesc','Answer','scheduledat','type','campaigntype','outbound','amd','countbusyretry','countnoanswerretry','countglobal','countcongestionretry','countnosuchnumberretry','countabandonedretry','countmachineretry','countdropretry','countagentrejectretry','uniqueid','calleridname','calleridnum','number','starttime','responsetime','format','YYYY-MM-DD\x20HH:mm:ss','ringtime','getSeconds','holdtime','talktime','endtime','queue','membername','IVR','reason','cause-txt','callback','callbackuniqueid','callbackat','recallme','ContactId','ListId','UserId','VoiceQueueId','CampaignId','exports','moment'];(function(_0x246fe0,_0x7f6262){var _0x41dd52=function(_0x512f8b){while(--_0x512f8b){_0x246fe0['push'](_0x246fe0['shift']());}};_0x41dd52(++_0x7f6262);}(_0xe991,0x13a));var _0x1e99=function(_0x77938b,_0x370568){_0x77938b=_0x77938b-0x0;var _0x3db9be=_0xe991[_0x77938b];return _0x3db9be;};'use strict';var moment=require(_0x1e99('0x0'));var utils=require('../utils');function Hangup(_0x5df5c8,_0x5bbe2f){this['state']=0x4;this[_0x1e99('0x1')]=_0x1e99('0x2');this[_0x1e99('0x3')]=_0x5df5c8[_0x1e99('0x3')];this[_0x1e99('0x4')]=_0x5df5c8[_0x1e99('0x4')];this[_0x1e99('0x5')]=_0x5df5c8[_0x1e99('0x4')]===_0x1e99('0x6')?'queue':_0x5df5c8[_0x1e99('0x4')];this[_0x1e99('0x7')]=_0x5df5c8['amd']||![];this['countbusyretry']=_0x5df5c8[_0x1e99('0x8')];this['countcongestionretry']=_0x5df5c8['countcongestionretry'];this[_0x1e99('0x9')]=_0x5df5c8[_0x1e99('0x9')];this[_0x1e99('0xa')]=_0x5df5c8[_0x1e99('0x8')]+_0x5df5c8[_0x1e99('0xb')]+_0x5df5c8[_0x1e99('0x9')]+_0x5df5c8[_0x1e99('0xc')]+_0x5df5c8['countdropretry']+_0x5df5c8[_0x1e99('0xd')]+_0x5df5c8[_0x1e99('0xe')]+_0x5df5c8['countagentrejectretry'];this[_0x1e99('0xc')]=_0x5df5c8['countnosuchnumberretry'];this['countdropretry']=_0x5df5c8[_0x1e99('0xf')];this[_0x1e99('0xd')]=_0x5df5c8[_0x1e99('0xd')];this[_0x1e99('0xe')]=_0x5df5c8[_0x1e99('0xe')];this[_0x1e99('0x10')]=_0x5df5c8[_0x1e99('0x10')];this[_0x1e99('0x11')]=_0x5bbe2f['uniqueid'];this[_0x1e99('0x12')]=_0x5df5c8['name'];this[_0x1e99('0x13')]=_0x5df5c8[_0x1e99('0x14')];this[_0x1e99('0x15')]=_0x5df5c8[_0x1e99('0x15')];this[_0x1e99('0x16')]=_0x5df5c8[_0x1e99('0x16')];this['endtime']=moment()[_0x1e99('0x17')](_0x1e99('0x18'));this[_0x1e99('0x19')]=utils[_0x1e99('0x1a')](_0x5df5c8['responsetime'],_0x5df5c8['starttime']);this[_0x1e99('0x1b')]=0x0;this[_0x1e99('0x1c')]=utils[_0x1e99('0x1a')](this[_0x1e99('0x1d')],_0x5df5c8[_0x1e99('0x16')]);this[_0x1e99('0x1e')]=_0x5df5c8[_0x1e99('0x1e')];this[_0x1e99('0x1f')]=_0x1e99('0x20');this[_0x1e99('0x21')]=_0x5bbe2f[_0x1e99('0x22')];this[_0x1e99('0x23')]=_0x5df5c8[_0x1e99('0x23')];this['callbackuniqueid']=_0x5df5c8[_0x1e99('0x24')];this[_0x1e99('0x25')]=_0x5df5c8[_0x1e99('0x25')];this[_0x1e99('0x26')]=_0x5df5c8[_0x1e99('0x26')];this[_0x1e99('0x27')]=_0x5df5c8['ContactId'];this[_0x1e99('0x28')]=_0x5df5c8['ListId'];this[_0x1e99('0x29')]=_0x5df5c8[_0x1e99('0x29')];this['VoiceQueueId']=_0x5df5c8[_0x1e99('0x2a')];this[_0x1e99('0x2b')]=_0x5df5c8[_0x1e99('0x2b')];}module[_0x1e99('0x2c')]=Hangup;