Built motion from commit (unavailable).|2.5.12
[motion2.git] / server / services / ami / rpc / integrations / sugarcrm.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 _0x142b=['keyContent','Fields','type','idField','nameField','customField','GetSugarcrmAccount','name','username','password','remoteUri','SugarcrmConfiguration','Configurations','SugarcrmField','content','variableName','Variable','key','keyType'];(function(_0x85f059,_0x27d70e){var _0x3520f7=function(_0x5b7c68){while(--_0x5b7c68){_0x85f059['push'](_0x85f059['shift']());}};_0x3520f7(++_0x27d70e);}(_0x142b,0x1bb));var _0xb142=function(_0x5a59cc,_0x3834fe){_0x5a59cc=_0x5a59cc-0x0;var _0x439407=_0x142b[_0x5a59cc];return _0x439407;};'use strict';var client=require('../../client');exports['getSugarcrmAccounts']=function(){return function(_0x596146){return client['Request'](_0xb142('0x0'),{'options':{'raw':![],'attributes':['id',_0xb142('0x1'),_0xb142('0x2'),_0xb142('0x3'),_0xb142('0x4'),'serverUrl'],'include':[{'model':_0xb142('0x5'),'as':_0xb142('0x6'),'attributes':['id',_0xb142('0x1')],'include':[{'model':_0xb142('0x7'),'as':'Subjects','attributes':['id','type',_0xb142('0x8'),_0xb142('0x9')],'include':[{'model':'Variable','as':_0xb142('0xa'),'attributes':['id',_0xb142('0x1')]}]},{'model':_0xb142('0x7'),'as':'Descriptions','attributes':['id','type','content',_0xb142('0xb'),_0xb142('0xc'),_0xb142('0xd'),'variableName'],'include':[{'model':_0xb142('0xa'),'as':'Variable','attributes':['id','name']}]},{'model':'SugarcrmField','as':_0xb142('0xe'),'attributes':['id',_0xb142('0xf'),'content',_0xb142('0x10'),_0xb142('0x11'),_0xb142('0x12'),'variableName'],'include':[{'model':_0xb142('0xa'),'as':_0xb142('0xa'),'attributes':['id',_0xb142('0x1')]}]}]}]},'log':'GetSugarcrmAccount'});};};