xzh.js 504 Bytes
'use strict';

/**
 * [百度熊掌号]
 * @type {[type]}
 */

const XzhIndexModel = require('../../models/xzh/index');

const index = (req, res) => {

    req.ctx(XzhIndexModel).index().then(result => {
        return res.json(result);
    });

};

const history = (req, res) => {

    req.ctx(XzhIndexModel).sendDataHistory(1);

    return res.json({
        code: 200,
        data: '',
        message: '任务创建成功,开始运行...'
    });

};

module.exports = {
    index,
    history
};