Authored by 王水玲

Merge branch 'feature/installment3' into release/5.2

@@ -18,7 +18,7 @@ const _serverCrash = (res, params) => { @@ -18,7 +18,7 @@ const _serverCrash = (res, params) => {
18 // 还款列表公共处理块 18 // 还款列表公共处理块
19 const _repaymentList = (req, res, opt, params) => { 19 const _repaymentList = (req, res, opt, params) => {
20 params = _.assign({ 20 params = _.assign({
21 - uid: req.cookies.installmentUid || 1 21 + uid: req.cookies.installmentUid
22 }, params); 22 }, params);
23 23
24 installmentModel.getQueryAmtList(params).then((result) => { 24 installmentModel.getQueryAmtList(params).then((result) => {
@@ -262,7 +262,7 @@ const repayRecordPage = (req, res) => { @@ -262,7 +262,7 @@ const repayRecordPage = (req, res) => {
262 // ajax 请求还款记录 262 // ajax 请求还款记录
263 const getRepayRecord = (req, res) => { 263 const getRepayRecord = (req, res) => {
264 let params = _.assign({ 264 let params = _.assign({
265 - uid: req.cookies.installmentUid || 1, 265 + uid: req.cookies.installmentUid,
266 pageNo: req.query.page || 1 266 pageNo: req.query.page || 1
267 }); 267 });
268 268
@@ -358,7 +358,7 @@ function getRealIP(req) { @@ -358,7 +358,7 @@ function getRealIP(req) {
358 const activateService = (req, res) => { 358 const activateService = (req, res) => {
359 359
360 installmentModel.activateService({ 360 installmentModel.activateService({
361 - uid: req.cookies.installmentUid || 532892, 361 + uid: req.cookies.installmentUid,
362 userName: req.body.userName, 362 userName: req.body.userName,
363 identityCardNo: req.body.identityCardNo, 363 identityCardNo: req.body.identityCardNo,
364 cardNo: req.body.cardNo, 364 cardNo: req.body.cardNo,
@@ -382,7 +382,7 @@ const activateService = (req, res) => { @@ -382,7 +382,7 @@ const activateService = (req, res) => {
382 const getBankInfo = (req, res) => { 382 const getBankInfo = (req, res) => {
383 installmentModel.getBankInfo({ 383 installmentModel.getBankInfo({
384 cardNo: req.query.cardNo, 384 cardNo: req.query.cardNo,
385 - uid: req.cookies.installmentUid || 512579468 // TODO: fix uid 385 + uid: req.cookies.installmentUid
386 }).then((result)=> { 386 }).then((result)=> {
387 res.json(result); 387 res.json(result);
388 }).catch(() => { 388 }).catch(() => {
@@ -415,7 +415,7 @@ const orderIndex = (req, res) => { @@ -415,7 +415,7 @@ const orderIndex = (req, res) => {
415 415
416 const orderList = (req, res) => { 416 const orderList = (req, res) => {
417 const params = { 417 const params = {
418 - uid: req.cookies.installmentUid || 8041876, // TODO: fix me 418 + uid: req.cookies.installmentUid,
419 type: req.query.type || 1, 419 type: req.query.type || 1,
420 page: req.query.page || 1, 420 page: req.query.page || 1,
421 limit: req.query.limit || 10 421 limit: req.query.limit || 10
@@ -451,7 +451,7 @@ const orderList = (req, res) => { @@ -451,7 +451,7 @@ const orderList = (req, res) => {
451 451
452 const orderDetail = (req, res) => { 452 const orderDetail = (req, res) => {
453 const params = { 453 const params = {
454 - uid: req.cookies.installmentUid || 8041876, // TODO: fix me 454 + uid: req.cookies.installmentUid,
455 orderCode: req.params.id 455 orderCode: req.params.id
456 }; 456 };
457 457
@@ -545,7 +545,7 @@ const orderDetail = (req, res) => { @@ -545,7 +545,7 @@ const orderDetail = (req, res) => {
545 // 还款详情 545 // 还款详情
546 const repayDetail = (req, res) => { 546 const repayDetail = (req, res) => {
547 let params = { 547 let params = {
548 - uid: req.cookies.installmentUid || 512579468, 548 + uid: req.cookies.installmentUid,
549 rePayNo: req.query.id || '', 549 rePayNo: req.query.id || '',
550 pageNo: 1 550 pageNo: 1
551 }; 551 };
@@ -607,7 +607,7 @@ const serverCrash = (req, res) => { @@ -607,7 +607,7 @@ const serverCrash = (req, res) => {
607 607
608 // 银行卡列表 608 // 银行卡列表
609 const bankCard = (req, res) => { 609 const bankCard = (req, res) => {
610 - let uid = req.cookies.installmentUid || 512579468; 610 + let uid = req.cookies.installmentUid;
611 611
612 installmentModel.getBankCards(uid).then((result) => { 612 installmentModel.getBankCards(uid).then((result) => {
613 res.render('installment/bank-card', { 613 res.render('installment/bank-card', {
@@ -628,7 +628,6 @@ const bankCard = (req, res) => { @@ -628,7 +628,6 @@ const bankCard = (req, res) => {
628 628
629 // 银行卡详情 629 // 银行卡详情
630 const cardDetail = (req, res) => { 630 const cardDetail = (req, res) => {
631 -  
632 installmentModel.getCardDetail(req.cookies.installmentUid, req.query.cardIdNo).then(result => { 631 installmentModel.getCardDetail(req.cookies.installmentUid, req.query.cardIdNo).then(result => {
633 res.render('installment/card-detail', { 632 res.render('installment/card-detail', {
634 module: 'home', 633 module: 'home',
@@ -166,8 +166,8 @@ const _processBankCards = (list) => { @@ -166,8 +166,8 @@ const _processBankCards = (list) => {
166 const _processCardDetail = (list) => { 166 const _processCardDetail = (list) => {
167 list = list || {}; 167 list = list || {};
168 168
169 - list.isMaster = +list.masterType;  
170 - list.cardNo = list.cardNo.replace(/\*/g, ''); 169 + list.isMaster = list.masterType === '1' ? true : false;
  170 + list.cardNo = list.cardNo ? list.cardNo.replace(/\*/g, '') : list.cardNo;
171 171
172 return list; 172 return list;
173 }; 173 };
@@ -526,7 +526,8 @@ const setMasterCard = (params) => { @@ -526,7 +526,8 @@ const setMasterCard = (params) => {
526 const getNotices = () => { 526 const getNotices = () => {
527 return api.get('', { 527 return api.get('', {
528 method: 'app.resources.getNotices', 528 method: 'app.resources.getNotices',
529 - position: 8 529 + position: 8,
  530 + client_type: 'iphone'
530 }, { 531 }, {
531 cache: true 532 cache: true
532 }).then((res) => { 533 }).then((res) => {
@@ -419,14 +419,14 @@ @@ -419,14 +419,14 @@
419 419
420 .group-list { 420 .group-list {
421 background: #fff; 421 background: #fff;
422 - margin-top: 30px; 422 + margin-top: 25px;
423 border-top: 1px solid #e1e1e1; 423 border-top: 1px solid #e1e1e1;
424 border-bottom: 1px solid #e1e1e1; 424 border-bottom: 1px solid #e1e1e1;
425 padding-left: 26px; 425 padding-left: 26px;
426 426
427 li { 427 li {
428 - height: 88px;  
429 - line-height: 88px; 428 + height: 80px;
  429 + line-height: 80px;
430 border-bottom: 1px solid #e1e1e1; 430 border-bottom: 1px solid #e1e1e1;
431 font-size: 28px; 431 font-size: 28px;
432 overflow: hidden; 432 overflow: hidden;
@@ -456,7 +456,7 @@ @@ -456,7 +456,7 @@
456 display: none; 456 display: none;
457 457
458 .banner-center { 458 .banner-center {
459 - margin: 30px auto; 459 + margin-top: 25px;
460 height: 210px; 460 height: 210px;
461 461
462 .banner-list { 462 .banner-list {