Authored by Aiden Xu

Merge remote-tracking branch 'origin/feature/installment' into feature/installment

... ... @@ -65,6 +65,8 @@ const index = (req, res, next) => {
// status:0 未申请 1审核中 2已开通 3 审核未通过
let openStatus = result[0];
openStatus = '2';
if (openStatus === '0') {
return installmentModel.getResources().then(data => {
return {
... ...
... ... @@ -9,7 +9,7 @@
{{#data}}
<ul class="repay-list">
{{#each repaymentList}}
<li data-currfee="{{currFee}}" data-currNoFeeAmt="{{currNoFeeAmt}}" data-curramt="{{currAmt}}" data-billno="{{billNo}}" data-termNo={{currTerm}}>
<li data-currfee="{{currFee}}" data-currnofeeamt="{{currNoFeeAmt}}" data-curramt="{{currAmt}}" data-bill="{{billNo}}" data-termno={{currTerm}}>
<input id="list-{{billNo}}" type="checkbox" class="installment-check-btn" {{#if isChecked}}checked{{/if}}/>
<label for="list-{{billNo}}">
<div class="cont">
... ...
... ... @@ -17,5 +17,5 @@
<p class="repay-price">待支付:<span>¥<span class="curr-amt">{{round currAmtCount}}</span></span></p>
<p class="serve-price" {{#if isCurrFee}}style="display:block;"{{/if}}>含服务费¥<span class="curr-fee">{{round currFeeCount}}</span></p>
</label>
<a href="" class="repayment-btn">立即还款</a>
<a href='' class="repayment-btn">立即还款</a>
</div>
\ No newline at end of file
... ...
... ... @@ -42,9 +42,9 @@ module.exports = {
// master: ['192.168.102.205:12111'],
// slave: ['192.168.102.205:12111'],
// session: ['192.168.102.205:12111'],
master: ['127.0.0.1:11211'],
slave: ['127.0.0.1:11211'],
session: ['127.0.0.1:11211'],
master: ['192.168.102.205:12111'],
slave: ['192.168.102.205:12111'],
session: ['192.168.102.205:12111'],
timeout: 1000,
retries: 0
},
... ...
... ... @@ -18,7 +18,7 @@
(function(d,c){var e=d.documentElement,a="orientationchange" in window?"orientationchange":"resize",b=function(){var f=e.clientWidth;if(!f){return}if(f>=640){e.style.fontSize="40px"}else{e.style.fontSize=40*(f/640)+"px"}};if(!d.addEventListener){return}b();c.addEventListener(a,b,false);d.addEventListener("DOMContentLoaded",b,false)})(document,window);
</script>
{{#if devEnv}}
<link rel="stylesheet" href="//172.16.11.32:5001/css/index.css">
<link rel="stylesheet" href="//172.16.6.180:5001/css/index.css">
{{^}}
<link rel="stylesheet" href="//cdn.yoho.cn/m-yohobuy-node/{{version}}/index.css">
{{/if}}
... ... @@ -41,8 +41,8 @@
<script type="text/javascript" src="//res.wx.qq.com/open/js/jweixin-1.1.0.js"></script>
{{/wechatShare}}
{{#if devEnv}}
<script src="//172.16.11.32:5001/libs.js"></script>
<script src="//172.16.11.32:5001/{{module}}.{{page}}.js"></script>
<script src="//172.16.6.180:5001/libs.js"></script>
<script src="//172.16.6.180:5001/{{module}}.{{page}}.js"></script>
{{^}}
<script src="//cdn.yoho.cn/m-yohobuy-node/{{version}}/libs.js"></script>
<script src="//cdn.yoho.cn/m-yohobuy-node/{{version}}/{{module}}.{{page}}.js"></script>
... ...
... ... @@ -15,13 +15,12 @@ var repayment = new Repayment({
$(`${CHECKBOX_SELECTOR}:checked`).each(function(key, item) {
var li = $(item).parents('li');
var data = {
index: li.index(),
orderCode: li.attr('data-billno'),
termNo: li.attr('data-termNo'),
amount: parseFloat(li.attr('data-currNoFeeAmt')),
fee: parseFloat(li.attr('data-currfee')) + 0
orderCode: li.data('bill'),
termNo: li.data('termno'),
amount: parseFloat(li.data('currnofeeamt')),
fee: parseFloat(li.data('currfee')) + 0
};
ret.push(data);
... ... @@ -29,6 +28,9 @@ var repayment = new Repayment({
return ret;
},
onGetSelectableCount: function() {
return $(CHECKBOX_SELECTOR).length;
},
onDeselectAll: function() {
$(`${CHECKBOX_SELECTOR}:checked`).prop('checked', false);
return [];
... ... @@ -65,7 +67,4 @@ $(CHECKBOX_SELECTOR + ':checkbox').click(function() {
repayment.update();
});
// 跳转到还款详情
window.jumpDetail = function(id) {
location.href = '/home/installment/repay/detail?id=' + id;
};
repayment.update();
... ...
... ... @@ -165,4 +165,9 @@ Repayment.prototype.update = function() {
}
};
// 跳转到还款详情
window.jumpDetail = function(id) {
location.href = '/home/installment/repay/detail?id=' + id;
};
module.exports = Repayment;
... ...