45767b0736ec5abc767a3d6911418ba784089459
[motion2.git] / server / api / dashboard / 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 _0xb874=['clone','addItem','put','multer','util','path','connect-timeout','express','Router','fs-extra','../../components/interaction/service','../../config/environment','get','isAuthenticated','/:id','show','/:id/items','getItems','post','/:id/clone'];(function(_0x22cb0e,_0x190ba9){var _0x10b1ed=function(_0x3844dc){while(--_0x3844dc){_0x22cb0e['push'](_0x22cb0e['shift']());}};_0x10b1ed(++_0x190ba9);}(_0xb874,0x12f));var _0x4b87=function(_0x502c7d,_0x2f1285){_0x502c7d=_0x502c7d-0x0;var _0x30b7ed=_0xb874[_0x502c7d];return _0x30b7ed;};'use strict';var multer=require(_0x4b87('0x0'));var util=require(_0x4b87('0x1'));var path=require(_0x4b87('0x2'));var timeout=require(_0x4b87('0x3'));var express=require(_0x4b87('0x4'));var router=express[_0x4b87('0x5')]();var fs_extra=require(_0x4b87('0x6'));var auth=require('../../components/auth/service');var interaction=require(_0x4b87('0x7'));var config=require(_0x4b87('0x8'));var controller=require('./dashboard.controller');router[_0x4b87('0x9')]('/',auth[_0x4b87('0xa')](),controller['index']);router['get'](_0x4b87('0xb'),auth[_0x4b87('0xa')](),controller[_0x4b87('0xc')]);router['get'](_0x4b87('0xd'),auth['isAuthenticated'](),controller[_0x4b87('0xe')]);router[_0x4b87('0xf')]('/',auth['isAuthenticated'](),controller['create']);router[_0x4b87('0xf')](_0x4b87('0x10'),auth['isAuthenticated'](),controller[_0x4b87('0x11')]);router[_0x4b87('0xf')]('/:id/items',auth[_0x4b87('0xa')](),controller[_0x4b87('0x12')]);router[_0x4b87('0x13')]('/:id',auth[_0x4b87('0xa')](),controller['update']);router['delete'](_0x4b87('0xb'),auth['isAuthenticated'](),controller['destroy']);module['exports']=router;