b5c01d10d4f3fc320867178297a4810acbfa9435
[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 _0x64e6=['SalesforceConfiguration','moduleSearch','moduleCreate','SalesforceField','Subjects','Variable','Fields','GetSalesforceAccount','getSalesforceAccounts','Request','name','username','password','remoteUri','securityToken','type'];(function(_0xaa1b3e,_0x47d976){var _0x454d7d=function(_0x575b32){while(--_0x575b32){_0xaa1b3e['push'](_0xaa1b3e['shift']());}};_0x454d7d(++_0x47d976);}(_0x64e6,0x198));var _0x664e=function(_0x31c201,_0x2f0396){_0x31c201=_0x31c201-0x0;var _0xe880b4=_0x64e6[_0x31c201];return _0xe880b4;};'use strict';var client=require('../../client');exports[_0x664e('0x0')]=function(){return function(_0x29b3a9){return client[_0x664e('0x1')]('GetSalesforceAccount',{'options':{'raw':![],'attributes':['id',_0x664e('0x2'),_0x664e('0x3'),_0x664e('0x4'),_0x664e('0x5'),'clientId','clientSecret',_0x664e('0x6'),'serverUrl',_0x664e('0x7')],'include':[{'model':_0x664e('0x8'),'as':'Configurations','attributes':['id',_0x664e('0x2'),_0x664e('0x9'),_0x664e('0xa'),'ticketType'],'include':[{'model':_0x664e('0xb'),'as':_0x664e('0xc'),'include':[{'model':'Variable','as':_0x664e('0xd'),'attributes':['id',_0x664e('0x2')]}]},{'model':'SalesforceField','as':'Descriptions','include':[{'model':_0x664e('0xd'),'as':_0x664e('0xd'),'attributes':['id',_0x664e('0x2')]}]},{'model':'SalesforceField','as':_0x664e('0xe'),'include':[{'model':_0x664e('0xd'),'as':_0x664e('0xd'),'attributes':['id','name']}]}]}]},'log':_0x664e('0xf')});};};