...
|
...
|
@@ -255,13 +255,14 @@ const orderIndex = (req, res) => { |
|
|
module: 'home',
|
|
|
page: 'installment.order',
|
|
|
title: '我的分期订单',
|
|
|
navBtn: false
|
|
|
navBtn: false,
|
|
|
isInstallmentPage: true
|
|
|
});
|
|
|
};
|
|
|
|
|
|
const orderList = (req, res) => {
|
|
|
const orderList = (req, res, next) => {
|
|
|
const params = {
|
|
|
uid: req.user.uid || 8041876, // TODO: fix me
|
|
|
uid: req.cookies.installmentUid || 8041876, // TODO: fix me
|
|
|
type: req.query.type || 1,
|
|
|
page: req.query.page || 1,
|
|
|
limit: req.query.limit || 10
|
...
|
...
|
@@ -270,15 +271,16 @@ const orderList = (req, res) => { |
|
|
installmentModel.getInstallmentOrders(params).then((result)=> {
|
|
|
res.render('installment/order-list', {
|
|
|
title: '我的分期订单',
|
|
|
orders: result.data.orderList,
|
|
|
layout: false
|
|
|
orders: result.data ? result.data.orderList : [],
|
|
|
layout: false,
|
|
|
isInstallmentPage: true
|
|
|
});
|
|
|
});
|
|
|
}).catch(next);
|
|
|
};
|
|
|
|
|
|
const orderDetail = (req, res) => {
|
|
|
const orderDetail = (req, res, next) => {
|
|
|
const params = {
|
|
|
uid: req.user.id || 8041876, // TODO: fix me
|
|
|
uid: req.cookies.installmentUid || 8041876, // TODO: fix me
|
|
|
orderCode: req.params.id
|
|
|
};
|
|
|
|
...
|
...
|
@@ -309,7 +311,7 @@ const orderDetail = (req, res) => { |
|
|
}
|
|
|
}
|
|
|
});
|
|
|
});
|
|
|
}).catch(next);
|
|
|
};
|
|
|
|
|
|
// 还款详情
|
...
|
...
|
|