Built motion from commit (unavailable).|2.5.31
[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 _0xbd03=['content','variableName','Variable','key','keyType','idField','nameField','customField','../../client','Request','GetSugarcrmAccount','username','password','remoteUri','serverUrl','SugarcrmConfiguration','name','SugarcrmField','Subjects','type'];(function(_0x978037,_0x731e6b){var _0xed75c9=function(_0xac16dd){while(--_0xac16dd){_0x978037['push'](_0x978037['shift']());}};_0xed75c9(++_0x731e6b);}(_0xbd03,0x184));var _0x3bd0=function(_0xf50820,_0x56f041){_0xf50820=_0xf50820-0x0;var _0x2a9b10=_0xbd03[_0xf50820];return _0x2a9b10;};'use strict';var client=require(_0x3bd0('0x0'));exports['getSugarcrmAccounts']=function(){return function(_0x50e192){return client[_0x3bd0('0x1')](_0x3bd0('0x2'),{'options':{'raw':![],'attributes':['id','name',_0x3bd0('0x3'),_0x3bd0('0x4'),_0x3bd0('0x5'),_0x3bd0('0x6')],'include':[{'model':_0x3bd0('0x7'),'as':'Configurations','attributes':['id',_0x3bd0('0x8')],'include':[{'model':_0x3bd0('0x9'),'as':_0x3bd0('0xa'),'attributes':['id',_0x3bd0('0xb'),_0x3bd0('0xc'),_0x3bd0('0xd')],'include':[{'model':_0x3bd0('0xe'),'as':'Variable','attributes':['id',_0x3bd0('0x8')]}]},{'model':_0x3bd0('0x9'),'as':'Descriptions','attributes':['id',_0x3bd0('0xb'),_0x3bd0('0xc'),_0x3bd0('0xf'),_0x3bd0('0x10'),'keyContent','variableName'],'include':[{'model':_0x3bd0('0xe'),'as':_0x3bd0('0xe'),'attributes':['id','name']}]},{'model':_0x3bd0('0x9'),'as':'Fields','attributes':['id',_0x3bd0('0xb'),'content',_0x3bd0('0x11'),_0x3bd0('0x12'),_0x3bd0('0x13'),_0x3bd0('0xd')],'include':[{'model':_0x3bd0('0xe'),'as':_0x3bd0('0xe'),'attributes':['id',_0x3bd0('0x8')]}]}]}]},'log':_0x3bd0('0x2')});};};