fadd2885607ab372ddf153ae64e23c75930f79db
[motion2.git] / server / services / ami / rpc / integrations / vtiger.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 _0xc21e=['remoteUri','serverUrl','Configurations','VtigerField','Subjects','content','Variable','Descriptions','keyType','keyContent','variableName','Fields','type','idField','customField','../../client','Request','GetVtigerAccount','name','description','username','accessKey'];(function(_0x49c722,_0x7f2064){var _0x16a371=function(_0x9955eb){while(--_0x9955eb){_0x49c722['push'](_0x49c722['shift']());}};_0x16a371(++_0x7f2064);}(_0xc21e,0x67));var _0xec21=function(_0x122ef9,_0x451d2a){_0x122ef9=_0x122ef9-0x0;var _0x42fba0=_0xc21e[_0x122ef9];return _0x42fba0;};'use strict';var client=require(_0xec21('0x0'));exports['getVtigerAccounts']=function(){return function(_0x2af9ed){return client[_0xec21('0x1')](_0xec21('0x2'),{'options':{'raw':![],'attributes':['id',_0xec21('0x3'),_0xec21('0x4'),_0xec21('0x5'),_0xec21('0x6'),_0xec21('0x7'),_0xec21('0x8')],'include':[{'model':'VtigerConfiguration','as':_0xec21('0x9'),'attributes':['id','name'],'include':[{'model':_0xec21('0xa'),'as':_0xec21('0xb'),'attributes':['id','type',_0xec21('0xc'),'variableName'],'include':[{'model':_0xec21('0xd'),'as':_0xec21('0xd'),'attributes':['id',_0xec21('0x3')]}]},{'model':_0xec21('0xa'),'as':_0xec21('0xe'),'attributes':['id','type',_0xec21('0xc'),'key',_0xec21('0xf'),_0xec21('0x10'),_0xec21('0x11')],'include':[{'model':_0xec21('0xd'),'as':'Variable','attributes':['id','name']}]},{'model':_0xec21('0xa'),'as':_0xec21('0x12'),'attributes':['id',_0xec21('0x13'),_0xec21('0xc'),_0xec21('0x14'),'nameField',_0xec21('0x15'),'variableName'],'include':[{'model':_0xec21('0xd'),'as':_0xec21('0xd'),'attributes':['id','name']}]}]}]},'log':_0xec21('0x2')});};};