42b8598ce041f9e1d4c7b4cbe7eeb94fc9c67fe0
[motion2.git] / server / api / cmList / 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 _0xb790=['/:id','update','delete','destroy','removeAgents','util','Router','../../components/interaction/service','../../config/environment','get','isAuthenticated','index','/describe','describe','/global_fields','getGlobalCustomFields','show','/:id/dispositions','getDispositions','/:id/contacts','/:id/contacts/csv','getContactsCsv','/:id/fields','getCustomFields','getAgents','create','post','addDisposition','addCustomField','/:id/users','addAgents','put'];(function(_0x1fd973,_0x47e406){var _0x19fed6=function(_0x19e8b0){while(--_0x19e8b0){_0x1fd973['push'](_0x1fd973['shift']());}};_0x19fed6(++_0x47e406);}(_0xb790,0xe5));var _0x0b79=function(_0x5ea797,_0x2d39dd){_0x5ea797=_0x5ea797-0x0;var _0x500783=_0xb790[_0x5ea797];return _0x500783;};'use strict';var multer=require('multer');var util=require(_0x0b79('0x0'));var path=require('path');var timeout=require('connect-timeout');var express=require('express');var router=express[_0x0b79('0x1')]();var fs_extra=require('fs-extra');var auth=require('../../components/auth/service');var interaction=require(_0x0b79('0x2'));var config=require(_0x0b79('0x3'));var controller=require('./cmList.controller');router[_0x0b79('0x4')]('/',auth[_0x0b79('0x5')](),controller[_0x0b79('0x6')]);router[_0x0b79('0x4')](_0x0b79('0x7'),auth[_0x0b79('0x5')](),controller[_0x0b79('0x8')]);router[_0x0b79('0x4')](_0x0b79('0x9'),auth[_0x0b79('0x5')](),controller[_0x0b79('0xa')]);router[_0x0b79('0x4')]('/:id',auth['isAuthenticated'](),controller[_0x0b79('0xb')]);router[_0x0b79('0x4')](_0x0b79('0xc'),auth[_0x0b79('0x5')](),controller[_0x0b79('0xd')]);router['get'](_0x0b79('0xe'),auth[_0x0b79('0x5')](),controller['getContacts']);router[_0x0b79('0x4')](_0x0b79('0xf'),auth[_0x0b79('0x5')](),controller[_0x0b79('0x10')]);router['get'](_0x0b79('0x11'),auth[_0x0b79('0x5')](),controller[_0x0b79('0x12')]);router[_0x0b79('0x4')]('/:id/users',auth[_0x0b79('0x5')](),controller[_0x0b79('0x13')]);router['post']('/',auth[_0x0b79('0x5')](),controller[_0x0b79('0x14')]);router[_0x0b79('0x15')](_0x0b79('0xc'),auth[_0x0b79('0x5')](),controller[_0x0b79('0x16')]);router[_0x0b79('0x15')](_0x0b79('0xe'),auth['isAuthenticated'](),controller['addContacts']);router['post'](_0x0b79('0x11'),auth[_0x0b79('0x5')](),controller[_0x0b79('0x17')]);router['post'](_0x0b79('0x18'),auth['isAuthenticated'](),controller[_0x0b79('0x19')]);router[_0x0b79('0x1a')](_0x0b79('0x1b'),auth['isAuthenticated'](),controller[_0x0b79('0x1c')]);router[_0x0b79('0x1d')](_0x0b79('0x1b'),auth['isAuthenticated'](),controller[_0x0b79('0x1e')]);router['delete']('/:id/dispositions',auth[_0x0b79('0x5')](),controller['removeDispositions']);router[_0x0b79('0x1d')](_0x0b79('0x18'),auth[_0x0b79('0x5')](),controller[_0x0b79('0x1f')]);module['exports']=router;