394c867aafce712f0678afd53623f597320ec509
[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 _0x1f31=['../../components/interaction/service','../../config/environment','./cmList.controller','isAuthenticated','index','get','/describe','describe','/global_fields','getGlobalCustomFields','/:id','show','/:id/dispositions','getDispositions','/:id/contacts','getContacts','/:id/contacts/csv','getContactsCsv','/:id/fields','getCustomFields','/:id/users','getAgents','post','addDisposition','addContacts','addCustomField','addAgents','put','update','delete','removeDispositions','removeAgents','connect-timeout','../../components/auth/service'];(function(_0x37233f,_0x6dada0){var _0x143036=function(_0x5afb50){while(--_0x5afb50){_0x37233f['push'](_0x37233f['shift']());}};_0x143036(++_0x6dada0);}(_0x1f31,0xca));var _0x11f3=function(_0x4e93a9,_0x413f30){_0x4e93a9=_0x4e93a9-0x0;var _0x43013c=_0x1f31[_0x4e93a9];return _0x43013c;};'use strict';var multer=require('multer');var util=require('util');var path=require('path');var timeout=require(_0x11f3('0x0'));var express=require('express');var router=express['Router']();var fs_extra=require('fs-extra');var auth=require(_0x11f3('0x1'));var interaction=require(_0x11f3('0x2'));var config=require(_0x11f3('0x3'));var controller=require(_0x11f3('0x4'));router['get']('/',auth[_0x11f3('0x5')](),controller[_0x11f3('0x6')]);router[_0x11f3('0x7')](_0x11f3('0x8'),auth[_0x11f3('0x5')](),controller[_0x11f3('0x9')]);router[_0x11f3('0x7')](_0x11f3('0xa'),auth[_0x11f3('0x5')](),controller[_0x11f3('0xb')]);router[_0x11f3('0x7')](_0x11f3('0xc'),auth[_0x11f3('0x5')](),controller[_0x11f3('0xd')]);router['get'](_0x11f3('0xe'),auth[_0x11f3('0x5')](),controller[_0x11f3('0xf')]);router['get'](_0x11f3('0x10'),auth[_0x11f3('0x5')](),controller[_0x11f3('0x11')]);router['get'](_0x11f3('0x12'),auth[_0x11f3('0x5')](),controller[_0x11f3('0x13')]);router[_0x11f3('0x7')](_0x11f3('0x14'),auth[_0x11f3('0x5')](),controller[_0x11f3('0x15')]);router[_0x11f3('0x7')](_0x11f3('0x16'),auth['isAuthenticated'](),controller[_0x11f3('0x17')]);router['post']('/',auth[_0x11f3('0x5')](),controller['create']);router[_0x11f3('0x18')]('/:id/dispositions',auth[_0x11f3('0x5')](),controller[_0x11f3('0x19')]);router['post'](_0x11f3('0x10'),auth[_0x11f3('0x5')](),controller[_0x11f3('0x1a')]);router['post']('/:id/fields',auth[_0x11f3('0x5')](),controller[_0x11f3('0x1b')]);router['post']('/:id/users',auth['isAuthenticated'](),controller[_0x11f3('0x1c')]);router[_0x11f3('0x1d')](_0x11f3('0xc'),auth[_0x11f3('0x5')](),controller[_0x11f3('0x1e')]);router[_0x11f3('0x1f')](_0x11f3('0xc'),auth[_0x11f3('0x5')](),controller['destroy']);router[_0x11f3('0x1f')](_0x11f3('0xe'),auth[_0x11f3('0x5')](),controller[_0x11f3('0x20')]);router[_0x11f3('0x1f')](_0x11f3('0x16'),auth[_0x11f3('0x5')](),controller[_0x11f3('0x21')]);module['exports']=router;