...
|
...
|
@@ -50,6 +50,7 @@ const _repaymentList = (req, res, opt, params) => { |
|
|
// 开通分期首页
|
|
|
const index = (req, res) => {
|
|
|
let uid = req.query.uid;
|
|
|
|
|
|
Promise.all([
|
|
|
installmentModel.getStauts(uid),
|
|
|
installmentModel.getSearchIntallment({
|
...
|
...
|
@@ -98,6 +99,12 @@ const index = (req, res) => { |
|
|
notice: data[3]
|
|
|
}, data[0], data[1]);
|
|
|
|
|
|
if (installmentOnly.goods.length > 0) {
|
|
|
params.installmentOnly = _.assign({
|
|
|
showMore: true
|
|
|
}, installmentOnly);
|
|
|
}
|
|
|
|
|
|
// status: 1 正常 2 逾期 3 不可用 4 未开通
|
|
|
if (data[0].status === '2') {
|
|
|
params.replayStatus = '逾期';
|
...
|
...
|
@@ -308,13 +315,15 @@ const getRepayRecord = (req, res) => { |
|
|
// 账号管理
|
|
|
const account = (req, res) => {
|
|
|
var url = req.yoho.isApp || req.cookies.appVersion ? '/home/installment/account' : '/home/installment/bank-card';
|
|
|
|
|
|
if (req.cookies.appVersion) {
|
|
|
var versions = req.cookies.appVersion.split('.');
|
|
|
|
|
|
if (versions.length >= 2) {
|
|
|
if (versions[0] < 5 || (parseInt(versions[0], 10)===5 && versions[1] <= 1)) {
|
|
|
if (versions[0] < 5 || (parseInt(versions[0], 10) === 5 && versions[1] <= 1)) {
|
|
|
url = '/home/installment/bank-card';
|
|
|
} else {
|
|
|
url = helpers.appUrlFormat(url, 'go.instalmentMyCard')
|
|
|
url = helpers.appUrlFormat(url, 'go.instalmentMyCard');
|
|
|
}
|
|
|
}
|
|
|
}
|
...
|
...
|
|