Merge remote-tracking branch 'origin/feature/installment' into feature/installment
Showing
7 changed files
with
24 additions
and
18 deletions
@@ -65,6 +65,8 @@ const index = (req, res, next) => { | @@ -65,6 +65,8 @@ const index = (req, res, next) => { | ||
65 | // status:0 未申请 1审核中 2已开通 3 审核未通过 | 65 | // status:0 未申请 1审核中 2已开通 3 审核未通过 |
66 | let openStatus = result[0]; | 66 | let openStatus = result[0]; |
67 | 67 | ||
68 | + openStatus = '2'; | ||
69 | + | ||
68 | if (openStatus === '0') { | 70 | if (openStatus === '0') { |
69 | return installmentModel.getResources().then(data => { | 71 | return installmentModel.getResources().then(data => { |
70 | return { | 72 | return { |
@@ -9,7 +9,7 @@ | @@ -9,7 +9,7 @@ | ||
9 | {{#data}} | 9 | {{#data}} |
10 | <ul class="repay-list"> | 10 | <ul class="repay-list"> |
11 | {{#each repaymentList}} | 11 | {{#each repaymentList}} |
12 | - <li data-currfee="{{currFee}}" data-currNoFeeAmt="{{currNoFeeAmt}}" data-curramt="{{currAmt}}" data-billno="{{billNo}}" data-termNo={{currTerm}}> | 12 | + <li data-currfee="{{currFee}}" data-currnofeeamt="{{currNoFeeAmt}}" data-curramt="{{currAmt}}" data-bill="{{billNo}}" data-termno={{currTerm}}> |
13 | <input id="list-{{billNo}}" type="checkbox" class="installment-check-btn" {{#if isChecked}}checked{{/if}}/> | 13 | <input id="list-{{billNo}}" type="checkbox" class="installment-check-btn" {{#if isChecked}}checked{{/if}}/> |
14 | <label for="list-{{billNo}}"> | 14 | <label for="list-{{billNo}}"> |
15 | <div class="cont"> | 15 | <div class="cont"> |
@@ -17,5 +17,5 @@ | @@ -17,5 +17,5 @@ | ||
17 | <p class="repay-price">待支付:<span>¥<span class="curr-amt">{{round currAmtCount}}</span></span></p> | 17 | <p class="repay-price">待支付:<span>¥<span class="curr-amt">{{round currAmtCount}}</span></span></p> |
18 | <p class="serve-price" {{#if isCurrFee}}style="display:block;"{{/if}}>含服务费¥<span class="curr-fee">{{round currFeeCount}}</span></p> | 18 | <p class="serve-price" {{#if isCurrFee}}style="display:block;"{{/if}}>含服务费¥<span class="curr-fee">{{round currFeeCount}}</span></p> |
19 | </label> | 19 | </label> |
20 | - <a href="" class="repayment-btn">立即还款</a> | ||
21 | -</div> | 20 | + <a href='' class="repayment-btn">立即还款</a> |
21 | +</div> |
@@ -42,9 +42,9 @@ module.exports = { | @@ -42,9 +42,9 @@ module.exports = { | ||
42 | // master: ['192.168.102.205:12111'], | 42 | // master: ['192.168.102.205:12111'], |
43 | // slave: ['192.168.102.205:12111'], | 43 | // slave: ['192.168.102.205:12111'], |
44 | // session: ['192.168.102.205:12111'], | 44 | // session: ['192.168.102.205:12111'], |
45 | - master: ['127.0.0.1:11211'], | ||
46 | - slave: ['127.0.0.1:11211'], | ||
47 | - session: ['127.0.0.1:11211'], | 45 | + master: ['192.168.102.205:12111'], |
46 | + slave: ['192.168.102.205:12111'], | ||
47 | + session: ['192.168.102.205:12111'], | ||
48 | timeout: 1000, | 48 | timeout: 1000, |
49 | retries: 0 | 49 | retries: 0 |
50 | }, | 50 | }, |
@@ -18,7 +18,7 @@ | @@ -18,7 +18,7 @@ | ||
18 | (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); | 18 | (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); |
19 | </script> | 19 | </script> |
20 | {{#if devEnv}} | 20 | {{#if devEnv}} |
21 | - <link rel="stylesheet" href="//172.16.11.32:5001/css/index.css"> | 21 | + <link rel="stylesheet" href="//172.16.6.180:5001/css/index.css"> |
22 | {{^}} | 22 | {{^}} |
23 | <link rel="stylesheet" href="//cdn.yoho.cn/m-yohobuy-node/{{version}}/index.css"> | 23 | <link rel="stylesheet" href="//cdn.yoho.cn/m-yohobuy-node/{{version}}/index.css"> |
24 | {{/if}} | 24 | {{/if}} |
@@ -41,8 +41,8 @@ | @@ -41,8 +41,8 @@ | ||
41 | <script type="text/javascript" src="//res.wx.qq.com/open/js/jweixin-1.1.0.js"></script> | 41 | <script type="text/javascript" src="//res.wx.qq.com/open/js/jweixin-1.1.0.js"></script> |
42 | {{/wechatShare}} | 42 | {{/wechatShare}} |
43 | {{#if devEnv}} | 43 | {{#if devEnv}} |
44 | - <script src="//172.16.11.32:5001/libs.js"></script> | ||
45 | - <script src="//172.16.11.32:5001/{{module}}.{{page}}.js"></script> | 44 | + <script src="//172.16.6.180:5001/libs.js"></script> |
45 | + <script src="//172.16.6.180:5001/{{module}}.{{page}}.js"></script> | ||
46 | {{^}} | 46 | {{^}} |
47 | <script src="//cdn.yoho.cn/m-yohobuy-node/{{version}}/libs.js"></script> | 47 | <script src="//cdn.yoho.cn/m-yohobuy-node/{{version}}/libs.js"></script> |
48 | <script src="//cdn.yoho.cn/m-yohobuy-node/{{version}}/{{module}}.{{page}}.js"></script> | 48 | <script src="//cdn.yoho.cn/m-yohobuy-node/{{version}}/{{module}}.{{page}}.js"></script> |
@@ -15,13 +15,12 @@ var repayment = new Repayment({ | @@ -15,13 +15,12 @@ var repayment = new Repayment({ | ||
15 | 15 | ||
16 | $(`${CHECKBOX_SELECTOR}:checked`).each(function(key, item) { | 16 | $(`${CHECKBOX_SELECTOR}:checked`).each(function(key, item) { |
17 | var li = $(item).parents('li'); | 17 | var li = $(item).parents('li'); |
18 | - | ||
19 | var data = { | 18 | var data = { |
20 | index: li.index(), | 19 | index: li.index(), |
21 | - orderCode: li.attr('data-billno'), | ||
22 | - termNo: li.attr('data-termNo'), | ||
23 | - amount: parseFloat(li.attr('data-currNoFeeAmt')), | ||
24 | - fee: parseFloat(li.attr('data-currfee')) + 0 | 20 | + orderCode: li.data('bill'), |
21 | + termNo: li.data('termno'), | ||
22 | + amount: parseFloat(li.data('currnofeeamt')), | ||
23 | + fee: parseFloat(li.data('currfee')) + 0 | ||
25 | }; | 24 | }; |
26 | 25 | ||
27 | ret.push(data); | 26 | ret.push(data); |
@@ -29,6 +28,9 @@ var repayment = new Repayment({ | @@ -29,6 +28,9 @@ var repayment = new Repayment({ | ||
29 | 28 | ||
30 | return ret; | 29 | return ret; |
31 | }, | 30 | }, |
31 | + onGetSelectableCount: function() { | ||
32 | + return $(CHECKBOX_SELECTOR).length; | ||
33 | + }, | ||
32 | onDeselectAll: function() { | 34 | onDeselectAll: function() { |
33 | $(`${CHECKBOX_SELECTOR}:checked`).prop('checked', false); | 35 | $(`${CHECKBOX_SELECTOR}:checked`).prop('checked', false); |
34 | return []; | 36 | return []; |
@@ -65,7 +67,4 @@ $(CHECKBOX_SELECTOR + ':checkbox').click(function() { | @@ -65,7 +67,4 @@ $(CHECKBOX_SELECTOR + ':checkbox').click(function() { | ||
65 | repayment.update(); | 67 | repayment.update(); |
66 | }); | 68 | }); |
67 | 69 | ||
68 | -// 跳转到还款详情 | ||
69 | -window.jumpDetail = function(id) { | ||
70 | - location.href = '/home/installment/repay/detail?id=' + id; | ||
71 | -}; | 70 | +repayment.update(); |
@@ -165,4 +165,9 @@ Repayment.prototype.update = function() { | @@ -165,4 +165,9 @@ Repayment.prototype.update = function() { | ||
165 | } | 165 | } |
166 | }; | 166 | }; |
167 | 167 | ||
168 | +// 跳转到还款详情 | ||
169 | +window.jumpDetail = function(id) { | ||
170 | + location.href = '/home/installment/repay/detail?id=' + id; | ||
171 | +}; | ||
172 | + | ||
168 | module.exports = Repayment; | 173 | module.exports = Repayment; |
-
Please register or login to post a comment