7b125b0ecd61d0925f4534c3ccfde5d472a67c54
[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 _0xf6fb=['download','post','/:id/tags','tracked','mail','mailinteraction:addtags','put','/:id','mailinteraction:update','update','delete','removeTags','exports','path','connect-timeout','Router','../../components/auth/service','../../config/environment','get','isAuthenticated','index','/describe','describe','show','/:id/messages','/:id/download'];(function(_0x102662,_0x355699){var _0x3b0762=function(_0x2040d0){while(--_0x2040d0){_0x102662['push'](_0x102662['shift']());}};_0x3b0762(++_0x355699);}(_0xf6fb,0x111));var _0xbf6f=function(_0x42a585,_0x3f0208){_0x42a585=_0x42a585-0x0;var _0x12d1aa=_0xf6fb[_0x42a585];return _0x12d1aa;};'use strict';var multer=require('multer');var util=require('util');var path=require(_0xbf6f('0x0'));var timeout=require(_0xbf6f('0x1'));var express=require('express');var router=express[_0xbf6f('0x2')]();var auth=require(_0xbf6f('0x3'));var interaction=require('../../components/interaction/service');var config=require(_0xbf6f('0x4'));var controller=require('./mailInteraction.controller');router[_0xbf6f('0x5')]('/',auth[_0xbf6f('0x6')](),controller[_0xbf6f('0x7')]);router[_0xbf6f('0x5')](_0xbf6f('0x8'),auth[_0xbf6f('0x6')](),controller[_0xbf6f('0x9')]);router[_0xbf6f('0x5')]('/:id',auth[_0xbf6f('0x6')](),controller[_0xbf6f('0xa')]);router[_0xbf6f('0x5')](_0xbf6f('0xb'),auth[_0xbf6f('0x6')](),controller['getMessages']);router['get'](_0xbf6f('0xc'),auth[_0xbf6f('0x6')](),controller[_0xbf6f('0xd')]);router['post']('/',auth[_0xbf6f('0x6')](),controller['create']);router[_0xbf6f('0xe')](_0xbf6f('0xb'),auth[_0xbf6f('0x6')](),controller['addMessage']);router[_0xbf6f('0xe')](_0xbf6f('0xf'),auth[_0xbf6f('0x6')](),interaction[_0xbf6f('0x10')](_0xbf6f('0x11'),_0xbf6f('0x12')),controller['addTags']);router[_0xbf6f('0x13')](_0xbf6f('0x14'),auth[_0xbf6f('0x6')](),interaction[_0xbf6f('0x10')](_0xbf6f('0x11'),_0xbf6f('0x15')),controller[_0xbf6f('0x16')]);router['delete']('/:id',auth[_0xbf6f('0x6')](),interaction[_0xbf6f('0x10')](_0xbf6f('0x11'),'mailinteraction:destroy'),controller['destroy']);router[_0xbf6f('0x17')](_0xbf6f('0xf'),auth[_0xbf6f('0x6')](),controller[_0xbf6f('0x18')]);module[_0xbf6f('0x19')]=router;