2c66c4cfcc267219b011ec6f82aa96def1ea03af
[motion2.git] / server / api / cmCompany / 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 _0x523c=['post','addContacts','put','update','destroy','exports','multer','util','path','connect-timeout','Router','../../components/interaction/service','../../config/environment','./cmCompany.controller','get','isAuthenticated','/describe','describe','/:id','/:id/contacts','create'];(function(_0x3ab51d,_0x2fa01d){var _0x29a04e=function(_0x7807b0){while(--_0x7807b0){_0x3ab51d['push'](_0x3ab51d['shift']());}};_0x29a04e(++_0x2fa01d);}(_0x523c,0x156));var _0xc523=function(_0x5e3068,_0x1dde86){_0x5e3068=_0x5e3068-0x0;var _0x5c9abb=_0x523c[_0x5e3068];return _0x5c9abb;};'use strict';var multer=require(_0xc523('0x0'));var util=require(_0xc523('0x1'));var path=require(_0xc523('0x2'));var timeout=require(_0xc523('0x3'));var express=require('express');var router=express[_0xc523('0x4')]();var fs_extra=require('fs-extra');var auth=require('../../components/auth/service');var interaction=require(_0xc523('0x5'));var config=require(_0xc523('0x6'));var controller=require(_0xc523('0x7'));router[_0xc523('0x8')]('/',auth[_0xc523('0x9')](),controller['index']);router[_0xc523('0x8')](_0xc523('0xa'),auth[_0xc523('0x9')](),controller[_0xc523('0xb')]);router[_0xc523('0x8')](_0xc523('0xc'),auth[_0xc523('0x9')](),controller['show']);router[_0xc523('0x8')](_0xc523('0xd'),auth[_0xc523('0x9')](),controller['getContacts']);router['post']('/',auth[_0xc523('0x9')](),controller[_0xc523('0xe')]);router[_0xc523('0xf')]('/:id/contacts',auth[_0xc523('0x9')](),controller[_0xc523('0x10')]);router[_0xc523('0x11')]('/:id',auth[_0xc523('0x9')](),controller[_0xc523('0x12')]);router['delete']('/:id',auth[_0xc523('0x9')](),controller[_0xc523('0x13')]);module[_0xc523('0x14')]=router;