Built motion from commit (unavailable).|2.0.83
[motion2.git] / server / services / ami / rpc / user.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 _0x7c55=['voicePause','interface','getAgent','getAgents','Request','GetUser','email','accountcode','fullname','online','lastLoginAt','pauseType','lastPauseAt','phone','mobile','getTelephones','name','PauseUser','savePause','UnpauseUser'];(function(_0x4565bf,_0x5ad9d6){var _0x5610ba=function(_0x170988){while(--_0x170988){_0x4565bf['push'](_0x4565bf['shift']());}};_0x5610ba(++_0x5ad9d6);}(_0x7c55,0xcb));var _0x57c5=function(_0x516c58,_0x361641){_0x516c58=_0x516c58-0x0;var _0x3af076=_0x7c55[_0x516c58];return _0x3af076;};'use strict';var client=require('../client');exports[_0x57c5('0x0')]=function(){return function(){return client[_0x57c5('0x1')](_0x57c5('0x2'),{'options':{'raw':![],'where':{'role':'agent'},'attributes':['id','name',_0x57c5('0x3'),_0x57c5('0x4'),_0x57c5('0x5'),_0x57c5('0x6'),_0x57c5('0x7'),_0x57c5('0x8'),_0x57c5('0x9'),'voicePause',_0x57c5('0xa'),_0x57c5('0xb'),'interface']},'log':_0x57c5('0x0')});};};exports[_0x57c5('0xc')]=function(){return function(){return client[_0x57c5('0x1')](_0x57c5('0x2'),{'options':{'raw':!![],'where':{'role':'telephone'},'attributes':['id',_0x57c5('0xd'),_0x57c5('0x4'),'internal']},'log':'getTelephones'});};};exports['savePause']=function(_0x313de3,_0x3230e2,_0x45369d){return client[_0x57c5('0x1')](_0x57c5('0xe'),{'body':{'type':_0x3230e2,'uniqueid':_0x45369d},'options':{'where':{'id':_0x313de3['id']}},'log':_0x57c5('0xf')});};exports['saveUnpause']=function(_0x527fc6){return client['Request'](_0x57c5('0x10'),{'body':{},'options':{'where':{'id':_0x527fc6['id']}},'log':_0x57c5('0xf')});};exports['getAgent']=function(_0x25b107){return client[_0x57c5('0x1')]('ShowUser',{'options':{'raw':![],'where':{'role':'agent','id':_0x25b107},'attributes':['id',_0x57c5('0xd'),'email',_0x57c5('0x4'),_0x57c5('0x5'),_0x57c5('0x6'),_0x57c5('0x7'),_0x57c5('0x8'),_0x57c5('0x9'),_0x57c5('0x11'),_0x57c5('0x12')]},'log':_0x57c5('0x13')});};