New Features

- added notifications
- added toggle switches
- added delete feature
- added email verification
This commit is contained in:
Luke Vella 2015-01-26 13:11:48 +01:00
parent e61ef151f6
commit 1b20a11bba
91 changed files with 6859 additions and 2756 deletions

View file

@ -6,8 +6,26 @@ var debug = require('debug')('api/event/index');
router.post('/', controller.create);
router.get('/:id', controller.show);
router.post('/:id/participant', controller.createParticipant);
router.put('/:id', controller.update);
router.delete('/:id', controller.delete);
router.delete('/:id/code/:code', controller.delete);
router.get('/:id/code/:code', controller.verifyEmail);
router.post('/:id/comment', controller.createComment);
router.delete('/:id/comment/:cid', controller.deleteComment);
router.post('/:id/participant', controller.createParticipant);
router.delete('/:id/participant/:pid', controller.deleteParticipant);
router.put('/:id/participant/:pid', controller.updateParticipant);
router.all('/*', function(req, res){
if (req.event){
var event = req.event.toObject();
delete event['__private'];
res.json(event);
} else {
res.status(204).end();
}
});
module.exports = router;