3 var express = require('express');
4 var controller = require('./voice_musiconhold.controller');
5 var auth = require('../../auth/auth.service');
7 var router = express.Router();
9 router.get('/', auth.isAuthenticated(), controller.index);
10 router.get('/stream', auth.isAuthenticated(), controller.stream);
11 router.get('/:id', auth.isAuthenticated(), controller.show);
12 router.get('/:id/files', auth.isAuthenticated(), controller.showAudioFiles);
13 router.post('/', auth.isAuthenticated(), controller.create);
14 router.post('/validate', auth.isAuthenticated(), controller.mohValidation);
15 router.post('/:id/files', auth.isAuthenticated(), controller.addFiles);
16 router.put('/:id', auth.isAuthenticated(), controller.update);
17 router.delete('/', auth.isAuthenticated(), controller.bulkDestroy);
18 router.delete('/:id', auth.isAuthenticated(), controller.destroy);
19 router.delete('/:id/files', auth.isAuthenticated(), controller.deleteAudioFiles);
21 module.exports = router;