62d1dd4af428039e57aef93e61c8da0792e4d0d6
[motion2.git] / server / api / openchannelInteraction / 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 _0xf344=['openchannel','openchannelinteraction:addtags','addTags','openchannelinteraction:update','update','delete','/:id','destroy','/:id/tags','exports','multer','util','path','connect-timeout','express','Router','../../components/auth/service','../../components/interaction/service','../../config/environment','get','isAuthenticated','describe','/:id/messages','getMessages','post','create','addMessage','tracked'];(function(_0x5241d6,_0x4c8185){var _0x1885d5=function(_0x47d297){while(--_0x47d297){_0x5241d6['push'](_0x5241d6['shift']());}};_0x1885d5(++_0x4c8185);}(_0xf344,0x13e));var _0x4f34=function(_0x498cad,_0x5b5137){_0x498cad=_0x498cad-0x0;var _0x31f4c8=_0xf344[_0x498cad];return _0x31f4c8;};'use strict';var multer=require(_0x4f34('0x0'));var util=require(_0x4f34('0x1'));var path=require(_0x4f34('0x2'));var timeout=require(_0x4f34('0x3'));var express=require(_0x4f34('0x4'));var router=express[_0x4f34('0x5')]();var fs_extra=require('fs-extra');var auth=require(_0x4f34('0x6'));var interaction=require(_0x4f34('0x7'));var config=require(_0x4f34('0x8'));var controller=require('./openchannelInteraction.controller');router[_0x4f34('0x9')]('/',auth[_0x4f34('0xa')](),controller['index']);router[_0x4f34('0x9')]('/describe',auth['isAuthenticated'](),controller[_0x4f34('0xb')]);router['get']('/:id',auth[_0x4f34('0xa')](),controller['show']);router['get'](_0x4f34('0xc'),auth[_0x4f34('0xa')](),controller[_0x4f34('0xd')]);router[_0x4f34('0x9')]('/:id/download',auth[_0x4f34('0xa')](),controller['download']);router[_0x4f34('0xe')]('/',auth[_0x4f34('0xa')](),controller[_0x4f34('0xf')]);router[_0x4f34('0xe')](_0x4f34('0xc'),auth[_0x4f34('0xa')](),controller[_0x4f34('0x10')]);router[_0x4f34('0xe')]('/:id/tags',auth['isAuthenticated'](),interaction[_0x4f34('0x11')](_0x4f34('0x12'),_0x4f34('0x13')),controller[_0x4f34('0x14')]);router['put']('/:id',auth[_0x4f34('0xa')](),interaction[_0x4f34('0x11')]('openchannel',_0x4f34('0x15')),controller[_0x4f34('0x16')]);router[_0x4f34('0x17')](_0x4f34('0x18'),auth[_0x4f34('0xa')](),interaction[_0x4f34('0x11')]('openchannel','openchannelinteraction:destroy'),controller[_0x4f34('0x19')]);router[_0x4f34('0x17')](_0x4f34('0x1a'),auth['isAuthenticated'](),controller['removeTags']);module[_0x4f34('0x1b')]=router;