router.js
471 Bytes
/**
* 文章router
* @author: leo <qi.li@yoho.cn>
* @date: 23/06/2017
*/
const express = require('express');
const router = express.Router(); // eslint-disable-line
const auth = require('../../doraemon/middleware/auth');
const article = require('./controllers/article');
router.post('/like', article.like);
router.get('/list', article.list);
router.post('/publish', auth, article.publish);
router.get('/querySingle', article.querySingle);
module.exports = router;