0437d67a50fa88cc60e3c1d87cc9dc5ace1a42ae
[motion2.git] / server / api / mailInteraction / index.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 _0x4b84=['delete','mailinteraction:destroy','destroy','exports','multer','util','express','../../components/interaction/service','../../config/environment','./mailInteraction.controller','get','isAuthenticated','show','/:id/messages','getMessages','/:id/download','download','post','addMessage','/:id/tags','mail','put','/:id','tracked'];(function(_0xb0f7c3,_0x4eae95){var _0x28ea68=function(_0x4395a7){while(--_0x4395a7){_0xb0f7c3['push'](_0xb0f7c3['shift']());}};_0x28ea68(++_0x4eae95);}(_0x4b84,0x1cc));var _0x44b8=function(_0x870b62,_0x2143f9){_0x870b62=_0x870b62-0x0;var _0x2dcb39=_0x4b84[_0x870b62];return _0x2dcb39;};'use strict';var multer=require(_0x44b8('0x0'));var util=require(_0x44b8('0x1'));var path=require('path');var timeout=require('connect-timeout');var express=require(_0x44b8('0x2'));var router=express['Router']();var auth=require('../../components/auth/service');var interaction=require(_0x44b8('0x3'));var config=require(_0x44b8('0x4'));var controller=require(_0x44b8('0x5'));router['get']('/',auth['isAuthenticated'](),controller['index']);router[_0x44b8('0x6')]('/describe',auth[_0x44b8('0x7')](),controller['describe']);router[_0x44b8('0x6')]('/:id',auth['isAuthenticated'](),controller[_0x44b8('0x8')]);router[_0x44b8('0x6')](_0x44b8('0x9'),auth['isAuthenticated'](),controller[_0x44b8('0xa')]);router[_0x44b8('0x6')](_0x44b8('0xb'),auth[_0x44b8('0x7')](),controller[_0x44b8('0xc')]);router[_0x44b8('0xd')]('/',auth[_0x44b8('0x7')](),controller['create']);router[_0x44b8('0xd')](_0x44b8('0x9'),auth['isAuthenticated'](),controller[_0x44b8('0xe')]);router['post'](_0x44b8('0xf'),auth[_0x44b8('0x7')](),interaction['tracked'](_0x44b8('0x10'),'mailinteraction:addtags'),controller['addTags']);router[_0x44b8('0x11')](_0x44b8('0x12'),auth[_0x44b8('0x7')](),interaction[_0x44b8('0x13')]('mail','mailinteraction:update'),controller['update']);router[_0x44b8('0x14')]('/:id',auth[_0x44b8('0x7')](),interaction[_0x44b8('0x13')]('mail',_0x44b8('0x15')),controller[_0x44b8('0x16')]);router['delete'](_0x44b8('0xf'),auth[_0x44b8('0x7')](),controller['removeTags']);module[_0x44b8('0x17')]=router;