vip.js
478 Bytes
'use strict';
const vipModel = require('../models/vip-service');
const index = (req, res, next) => {
let uid = req.user.uid;
vipModel.vipIndex(uid).then(result => {
res.render('vip', result);
}).catch(next);
};
const details = (req, res, next) => {
let uid = req.user.uid;
vipModel.getVipRecord(uid, req.query || {}).then(result => {
res.render('vip-details', result);
}).catch(next);
};
module.exports = {
index,
details
};