Redenvelopes.js
500 Bytes
'use strict';
const Promise = require('bluebird');
const co = Promise.coroutine;
const RedenvelopesModel = require('../models/RedenvelopesModel');
const index = (req, res, next)=>{
let $uid = '8041246';// req.user.uid;
let $udid = 'abcdrf';// req.sessionID;
co(function*() {
let result = yield RedenvelopesModel.redenvelopesList($uid);
res.render('Redenvelopes', {
meRedEnvelopes: result
});
})().catch(next);
};
module.exports = {
index
};