dc1b64dc84aa1ddea534868c4e7498780dce8cf4
[motion2.git] / server / services / ami / rpc / integrations / salesforce.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 _0x61c9=['Request','GetSalesforceAccount','name','username','remoteUri','clientId','securityToken','serverUrl','type','Configurations','moduleSearch','ticketType','SalesforceField','Variable','Fields','getSalesforceAccounts'];(function(_0x425916,_0x2d10ed){var _0x49ffb7=function(_0x5d825e){while(--_0x5d825e){_0x425916['push'](_0x425916['shift']());}};_0x49ffb7(++_0x2d10ed);}(_0x61c9,0x19f));var _0x961c=function(_0x429dc6,_0x439f71){_0x429dc6=_0x429dc6-0x0;var _0x4e5b77=_0x61c9[_0x429dc6];return _0x4e5b77;};'use strict';var client=require('../../client');exports[_0x961c('0x0')]=function(){return function(_0x4422ab){return client[_0x961c('0x1')](_0x961c('0x2'),{'options':{'raw':![],'attributes':['id',_0x961c('0x3'),_0x961c('0x4'),'password',_0x961c('0x5'),_0x961c('0x6'),'clientSecret',_0x961c('0x7'),_0x961c('0x8'),_0x961c('0x9')],'include':[{'model':'SalesforceConfiguration','as':_0x961c('0xa'),'attributes':['id',_0x961c('0x3'),_0x961c('0xb'),'moduleCreate',_0x961c('0xc')],'include':[{'model':_0x961c('0xd'),'as':'Subjects','include':[{'model':'Variable','as':_0x961c('0xe'),'attributes':['id',_0x961c('0x3')]}]},{'model':_0x961c('0xd'),'as':'Descriptions','include':[{'model':_0x961c('0xe'),'as':_0x961c('0xe'),'attributes':['id',_0x961c('0x3')]}]},{'model':'SalesforceField','as':_0x961c('0xf'),'include':[{'model':_0x961c('0xe'),'as':'Variable','attributes':['id','name']}]}]}]},'log':_0x961c('0x2')});};};