2a043b9424390925220bf17f72ca47409dc3c3b9
[motion2.git] / server / services / email / rpc / mailAccount.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 _0x1a54=['name','provider','email','active','key','ListId','TemplateId','Imap','CloudProvider','service','type','data5','MailServerOut','Smtp','getMailAccount','Request','NotifyMailAccount','../client','GetMailAccount'];(function(_0x322246,_0x21d668){var _0x3b29f4=function(_0x3cdf8a){while(--_0x3cdf8a){_0x322246['push'](_0x322246['shift']());}};_0x3b29f4(++_0x21d668);}(_0x1a54,0x12e));var _0x41a5=function(_0x3ff910,_0x3a0702){_0x3ff910=_0x3ff910-0x0;var _0x58970f=_0x1a54[_0x3ff910];return _0x58970f;};'use strict';var client=require(_0x41a5('0x0'));exports['getMailAccounts']=function(){return function(){return client['Request'](_0x41a5('0x1'),{'options':{'attributes':['id',_0x41a5('0x2'),_0x41a5('0x3'),'service',_0x41a5('0x4'),_0x41a5('0x5'),_0x41a5('0x6'),_0x41a5('0x7'),_0x41a5('0x8')],'raw':![],'include':[{'model':'MailServerIn','as':_0x41a5('0x9'),'include':[{'model':_0x41a5('0xa'),'attributes':['id',_0x41a5('0x2'),_0x41a5('0xb'),_0x41a5('0xc'),_0x41a5('0xd')],'as':_0x41a5('0xa')}]},{'model':_0x41a5('0xe'),'as':_0x41a5('0xf'),'include':[{'model':_0x41a5('0xa'),'attributes':['id',_0x41a5('0x2'),_0x41a5('0xb'),_0x41a5('0xc'),_0x41a5('0xd')],'as':_0x41a5('0xa')}]}]},'log':_0x41a5('0x10')});};};exports['notify']=function(_0x4d3d6e,_0x2152d0){return client[_0x41a5('0x11')]('NotifyMailAccount',{'account':{'id':_0x4d3d6e},'body':_0x2152d0,'log':_0x41a5('0x12')});};