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