Authored by zzzzzzz

Merge branch 'master' of git.yoho.cn:fe/yohobuywap-node into feature/newfloor

Showing 56 changed files with 1027 additions and 394 deletions
... ... @@ -322,23 +322,23 @@ const getWxUserInfo = (params) => {
gzip: true,
timeout: 3000
})
.then((result) => {
if (_.isEmpty(result.openid)) {
return false;
}
url2 = url2 + '&access_token=' + result.access_token +
.then((result) => {
if (_.isEmpty(result.openid)) {
return false;
}
url2 = url2 + '&access_token=' + result.access_token +
'&openid=' + result.openid;
return api._requestFromAPI({
url: url2,
qs: {},
json: true,
gzip: true,
timeout: 3000
})
.then((result2) => {
return result2;
return api._requestFromAPI({
url: url2,
qs: {},
json: true,
gzip: true,
timeout: 3000
})
.then((result2) => {
return result2;
});
});
});
};
module.exports = {
... ...
... ... @@ -57,7 +57,7 @@ const _processIndexData = (dataList) => {
if (list.ads) {
_.forEach(list.ads.data, (data) => {
formatData.ads.push({
src: data.src.replace('imageView', 'imageView2'),
src: data.src.replace('imageView/', 'imageView2/'),
url: data.url
});
});
... ... @@ -81,7 +81,7 @@ const _processIndexData = (dataList) => {
avatar.tags.push({
avatarUrl: `/guang/star/detail?tag=${tags.tagName}&openby:yohobuy{"action":"go.h5","params":{"id":"","share":"","shareparam":{},"islogin":"N","type":0,"updateflag":"N","url":"http://m.yohobuy.com/guang/star/detail","param":{"tag":"${tags.tagName}"}}}`, // eslint-disable-line
cover: tags.cover ? (tags.cover + '?imageView2/2/w/104/h/104/q/80') : tags.cover,
cover: tags.cover ? (tags.cover + '?imageView2/2/w/104/h/104') : tags.cover,
tagName: tags.tagName
});
});
... ... @@ -96,7 +96,7 @@ const _processIndexData = (dataList) => {
url: data.url,
title: data.title,
articeTxt: data.intro,
src: data.src + '/q/80',
src: data.src,
publishTime: helpers.dateFormat('MM月DD日 hh:mm', data.publishTime),
viewsNum: data.viewsNum
}, avatar));
... ... @@ -106,13 +106,13 @@ const _processIndexData = (dataList) => {
// 首页明星头像数据处理
if (list.tags) {
_.forEach(list.tags, (data) => {
_.forEach(list.tags, (data, index) => {
let url = `/guang/star/detail?tag=${data.tagName}&openby:yohobuy{"action":"go.h5","params":{"id":"","share":"","shareparam":{},"islogin":"N","type":0,"updateflag":"N","url":"http://m.yohobuy.com/guang/star/detail","param":{"tag":"${data.tagName}"}}}`; // eslint-disable-line
formatData.starAvatar.push({
// noLazy: index < 5,
//noLazy: index < 6,
url: url,
cover: data.cover ? (data.cover + '?imageView2/2/w/180/h/180/q/80') : data.cover
cover: data.cover ? (data.cover + '?imageView2/2/w/180/h/180') : data.cover
});
});
}
... ... @@ -213,7 +213,7 @@ const getSpecialData = () => {
return;
}
item.src += '/q/80';
// item.src += '/q/80';
if (key < 4) {
item.islazy = true;
... ...
... ... @@ -11,19 +11,22 @@
<ul class="clearfix swiper-wrapper">
{{# starAvatar}}
<li class="swiper-slide">
{{#if noLazy}}
<a href='{{url}}' class="star" style="background: url('{{image cover 180 180}}')">
</a>
{{else}}
<a href='{{url}}' class="star swiper-lazy" data-background="{{image cover 180 180}}">
<a href='{{url}}'>
{{#if noLazy}}
<img class="star" src="{{cover}}">
{{else}}
<img class="star swiper-lazy" data-src="{{cover}}">
{{/if}}
</a>
{{/if}}
</li>
{{/ starAvatar}}
</ul>
</div>
</div>
<ul class="star-info clearfix">
{{#each articles}}
<li data-id="{{id}}">
... ...
... ... @@ -9,8 +9,14 @@ const installmentModel = require('../models/installment');
const _ = require('lodash');
const helpers = global.yoho.helpers;
// 服务器报错页面
const _serverCrash = (res, params) => {
params.title = params.title || '有货分期';
res.render('installment/server-crash', params);
};
// 判断是否已经获取到了开通的状态值
const _reviewStatus = (uid, status, next) => {
const _reviewStatus = (res, req, uid, status) => {
let jumpUrl = helpers.appUrlFormat('/product/new', 'go.new');
if (status === '1') {
... ... @@ -27,17 +33,33 @@ const _reviewStatus = (uid, status, next) => {
success: {
price: result[1].currCreditLimit,
installmentOnly: {
title: '分期专享',
title: {
title: '分期专享',
moreUrl: helpers.appUrlFormat(req.originalUrl, 'go.instalmentlist', {
title: '分期专享'
})
},
goods: result[0]
},
url: jumpUrl
url: helpers.appUrlFormat(req.originalUrl, 'go.instalmentlist', {
title: '分期专享'
})
}
};
}).catch(next);
}).catch(() => {
_serverCrash(res, {
url: req.originalUrl,
title: '分期专享'
});
});
} else if (status === '3') {
return {
error: {
error: true
};
} else if (status === '4') {
return {
cancel: {
url: jumpUrl
}
};
... ... @@ -45,7 +67,7 @@ const _reviewStatus = (uid, status, next) => {
};
// 还款列表公共处理块
const _repaymentList = (req, res, next, title, params) => {
const _repaymentList = (req, res, title, params) => {
params = _.assign({
uid: req.cookies.installmentUid || 1
}, params);
... ... @@ -58,11 +80,16 @@ const _repaymentList = (req, res, next, title, params) => {
title: title,
data: result
});
}).catch(next);
}).catch(() => {
_serverCrash(res, {
url: req.originalUrl,
title: title
});
});
};
// 开通分期首页
const index = (req, res, next) => {
const index = (req, res) => {
let uid = req.query.uid;
Promise.all([installmentModel.getStauts(uid), installmentModel.getSearchIntallment({
... ... @@ -72,7 +99,12 @@ const index = (req, res, next) => {
// status:0 未申请 1审核中 2已开通 3 审核未通过
let openStatus = result[0];
let installmentOnly = {
title: '分期专享',
title: {
title: '分期专享',
moreUrl: helpers.appUrlFormat(req.originalUrl, 'go.instalmentlist', {
title: '分期专享'
})
},
goods: result[1]
};
... ... @@ -105,7 +137,7 @@ const index = (req, res, next) => {
return params;
});
} else if (openStatus === '1' || openStatus === '3') {
} else if (openStatus === '1' || openStatus === '3' || openStatus === '4') {
res.redirect('/home/installment/review?status=' + openStatus);
}
}).then((result) => {
... ... @@ -115,11 +147,15 @@ const index = (req, res, next) => {
isInstallmentPage: true,
title: '有货分期'
}, result));
}).catch(next);
}).catch(() => {
_serverCrash(res, {
url: req.originalUrl
});
});
};
// ajax 请求分期专享商品
const getInstallmentGoods = (req, res, next) => {
const getInstallmentGoods = (req, res) => {
let params = req.query || {};
installmentModel.getSearchIntallment(params).then((result) => {
... ... @@ -131,11 +167,15 @@ const getInstallmentGoods = (req, res, next) => {
} else {
res.json();
}
}).catch(next);
}).catch(() => {
_serverCrash(res, {
url: req.originalUrl
});
});
};
// 开通结果显示
const review = (req, res, next) => {
const review = (req, res) => {
let openStatus = req.query.status || false;
let uid = req.query.uid;
let data = {
... ... @@ -145,38 +185,38 @@ const review = (req, res, next) => {
};
if (openStatus !== '2') {
res.render('installment/open-result', _.assign(data, _reviewStatus(uid, openStatus)));
res.render('installment/open-result', _.assign(data, _reviewStatus(res, req, uid, openStatus)));
} else {
_reviewStatus(uid, openStatus, next).then((params) => {
_reviewStatus(res, req, uid, openStatus).then((params) => {
res.render('installment/open-result', _.assign(data, params));
});
}
};
// 逾期未还款列表
const overdueList = (req, res, next) => {
_repaymentList(req, res, next, '逾期未还金额', {
const overdueList = (req, res) => {
_repaymentList(req, res, '逾期未还金额', {
queryDays: -1
});
};
// 7日待还款列表
const sevenDayList = (req, res, next) => {
_repaymentList(req, res, next, '近7日待还款', {
const sevenDayList = (req, res) => {
_repaymentList(req, res, '近7日待还款', {
queryDays: 7
});
};
// 本月待还款列表
const monthRepayList = (req, res, next) => {
_repaymentList(req, res, next, '本月待还金额', {
const monthRepayList = (req, res) => {
_repaymentList(req, res, '本月待还金额', {
queryDays: 30
});
};
// 待还总金额列表
const totalRepayList = (req, res, next) => {
_repaymentList(req, res, next, '待还总金额', {
const totalRepayList = (req, res) => {
_repaymentList(req, res, '待还总金额', {
queryDays: 0
});
};
... ... @@ -192,7 +232,7 @@ const repayRecordPage = (req, res) => {
};
// ajax 请求还款记录
const getRepayRecord = (req, res, next) => {
const getRepayRecord = (req, res) => {
let params = _.assign({
uid: req.cookies.installmentUid || 1,
pageNo: req.query.page || 1
... ... @@ -207,21 +247,49 @@ const getRepayRecord = (req, res, next) => {
} else {
res.json();
}
}).catch(next);
}).catch(() => {
_serverCrash(res, {
url: req.originalUrl,
title: '还款记录'
});
});
};
// 账号管理
const account = (req, res, next) => {
let uid = req.cookies.installmentUid || 512579468;
const account = (req, res) => {
res.render('installment/account', {
title: '账号管理',
isInstallmentPage: true
});
};
installmentModel.getBankCards(uid).then((result) => {
res.render('installment/account', {
accountList: result,
title: '账号管理',
isInstallmentPage: true,
repaymentList: result
// 添加新银行卡
const bindCard = (req, res) => {
res.render('installment/bind-card', {
module: 'home',
page: 'bind-card',
title: '使用新卡还款',
bindCard: {
userName: req.query.name
},
isInstallmentPage: true
});
};
// 添加新银行卡请求
const postAccount = (req, res) => {
var params = _.assign({
uid: req.cookies.installmentUid
}, req.query);
installmentModel.postAccount(params).then((result) => {
res.json(result);
}).catch(() => {
_serverCrash(res, {
url: req.originalUrl,
title: '使用新卡还款'
});
}).catch(next);
});
};
const startingService = (req, res) => {
... ... @@ -247,7 +315,7 @@ function getRealIP(req) {
return realIP || forwardedFor.split(',')[0] || req.connection.remoteAddress;
}
const activateService = (req, res, next) => {
const activateService = (req, res) => {
installmentModel.activateService({
uid: req.cookies.installmentUid || 532892,
... ... @@ -263,22 +331,35 @@ const activateService = (req, res, next) => {
ip: getRealIP(req)
}).then((result)=> {
res.json(result);
}).catch(next);
}).catch(() => {
_serverCrash(res, {
url: req.originalUrl,
title: '开通有货分期'
});
});
};
const getBankInfo = (req, res, next) => {
const getBankInfo = (req, res) => {
installmentModel.getBankInfo({
cardNo: req.query.cardNo,
uid: req.cookies.installmentUid || 512579468 // TODO: fix uid
}).then((result)=> {
res.json(result);
}).catch(next);
}).catch(() => {
_serverCrash(res, {
url: req.originalUrl
});
});
};
const verifyCode = (req, res, next) => {
const verifyCode = (req, res) => {
installmentModel.sendVerifyCode(req.cookies.installmentUid || 1, req.query.mobile).then((result)=> {
res.json(result);
}).catch(next);
}).catch(() => {
_serverCrash(res, {
url: req.originalUrl
});
});
};
const orderIndex = (req, res) => {
... ... @@ -291,7 +372,7 @@ const orderIndex = (req, res) => {
});
};
const orderList = (req, res, next) => {
const orderList = (req, res) => {
const params = {
uid: req.cookies.installmentUid || 8041876, // TODO: fix me
type: req.query.type || 1,
... ... @@ -319,10 +400,15 @@ const orderList = (req, res, next) => {
layout: false,
isInstallmentPage: true
});
}).catch(next);
}).catch(() => {
_serverCrash(res, {
url: req.originalUrl,
title: '我的分期订单'
});
});
};
const orderDetail = (req, res, next) => {
const orderDetail = (req, res) => {
const params = {
uid: req.cookies.installmentUid || 8041876, // TODO: fix me
orderCode: req.params.id
... ... @@ -405,11 +491,16 @@ const orderDetail = (req, res, next) => {
}
}
});
}).catch(next);
}).catch(() => {
_serverCrash(res, {
url: req.originalUrl,
title: '分期详情'
});
});
};
// 还款详情
const repayDetail = (req, res, next) => {
const repayDetail = (req, res) => {
let params = {
uid: req.cookies.installmentUid || 512579468,
rePayNo: req.query.id || '',
... ... @@ -422,7 +513,12 @@ const repayDetail = (req, res, next) => {
isInstallmentPage: true,
isOne: true
}, result[0]));
}).catch(next);
}).catch(() => {
_serverCrash(res, {
url: req.originalUrl,
title: '还款详情'
});
});
};
// 帮助静态页面
... ... @@ -440,17 +536,48 @@ const agreement = (req, res) => {
};
// 计算金额
const totalAmount = (req, res, next) => {
const totalAmount = (req, res) => {
installmentModel.totalAmount(req.query.prices).then((result) => {
res.json(result);
}).catch(next);
}).catch(() => {
_serverCrash(res, {
url: req.originalUrl
});
});
};
// 检查验证码
const checkVerifyCode = (req, res, next) => {
const checkVerifyCode = (req, res) => {
installmentModel.checkVerifyCode(req.cookies.installmentUid, req.query.mobile, req.query.code).then((result) => {
res.json(result);
}).catch(next);
}).catch(() => {
_serverCrash(res, {
url: req.originalUrl
});
});
};
// 服务器崩溃
const serverCrash = (req, res) => {
res.render('installment/server-crash');
};
// 银行卡列表
const bankCard = (req, res) => {
let uid = req.cookies.installmentUid || 512579468;
installmentModel.getBankCards(uid).then((result) => {
res.render('installment/bank-card', {
title: '我的银行卡',
isInstallmentPage: true,
accountList: result
});
}).catch(() => {
_serverCrash(res, {
url: req.originalUrl,
title: '我的银行卡'
});
});
};
module.exports = {
... ... @@ -475,5 +602,9 @@ module.exports = {
agreement,
totalAmount,
checkVerifyCode,
getInstallmentGoods
getInstallmentGoods,
bindCard,
serverCrash,
bankCard,
postAccount
};
... ...
... ... @@ -107,7 +107,6 @@ const _processAmtList = (listData, queryDays) => {
// 处理还款记录数据
const _processRepayList = (list) => {
if (list !== 'NULL') {
_.forEach(list.rePayList, (data) => {
if (data.status === 1) {
... ... @@ -464,6 +463,7 @@ const checkVerifyCode = (uid, mobile, code) => {
method: method,
mobile: mobile,
snsCheckCode: code,
codeType: 1, // 授信
debug: 'XYZ'
}, {
timeout: API_TIMEOUT
... ... @@ -472,6 +472,16 @@ const checkVerifyCode = (uid, mobile, code) => {
});
};
// 添加银行卡请求
const postAccount = (params) => {
return api.get('', _.assign({
method: 'user.instalment.bindingCards',
debug: 'XYZ'
}, params), {
timeout: 6000
});
};
module.exports = {
getStauts,
getQueryCreditInfo,
... ... @@ -487,5 +497,6 @@ module.exports = {
getInstallmentOrders,
getInstallmentOrderDetail,
totalAmount,
checkVerifyCode
checkVerifyCode,
postAccount
};
... ...
... ... @@ -18,7 +18,7 @@ const personalController = require(`${cRoot}/qrcode`);
router.get('/QRcode/:id', personalController.QRcode);
// 分期付款
router.get('/installment/index', installment.index);// 开通分期首页
router.get('/installment/index', installment.index); // 开通分期首页
router.get('/installment/review', installment.review); // 开通分期首页
router.get('/installment/starting-service', installment.startingService); // 分期付款开通
router.get('/installment/starting-service/verify-code', installment.verifyCode);
... ... @@ -34,6 +34,8 @@ router.get('/installment/repay/get-record', installment.getRepayRecord); // ajax
router.get('/installment/repay/detail', installment.repayDetail); // 还款详情
router.get('/installment/account', installment.account); // 账户管理
router.get('/installment/bind-card', installment.bindCard); // 添加新银行卡
router.get('/installment/post-account', installment.postAccount); // 添加新卡请求
router.get('/installment/bank-info', installment.getBankInfo);
router.post('/installment/activate-service', installment.activateService);
router.get('/installment/order', installment.orderIndex);
... ... @@ -42,6 +44,8 @@ router.get('/installment/order/:id', installment.orderDetail);
router.get('/installment/total-amount.json', installment.totalAmount);
router.get('/installment/help', installment.help);// 帮助静态页面
router.get('/installment/agreement', installment.agreement);// 服务协议\服务条款静态页面
router.get('/installment/agreement', installment.agreement);// 服务协议静态页面
router.get('/installment/server-crash', installment.serverCrash); // 服务器崩溃
router.get('/installment/bank-card', installment.bankCard); // 银行卡列表
module.exports = router;
... ...
<div class="account-page">
<ul class="account-list">
{{#accountList}}
<li>我的银行卡:<div class="list-right">{{cardNo}}</div></li>
{{/accountList}}
<li><a href="/home/installment/bank-card">我的银行卡:<div class="list-right"><span class="iconfont">&#xe604;</span></div></a></li>
</ul>
</div>
\ No newline at end of file
</div>
... ...
This diff could not be displayed because it is too large.
<div class="bank-card-page">
<ul class="bank-card-list">
{{#accountList}}
<li class="card-bg-{{lowerCase bankCode}}"><span>{{cardNo}}</span></li>
{{/accountList}}
</ul>
</div>
... ...
<div class="installment-page add-account-page yoho-page">
{{#bindCard}}
<ul class="add-form">
<li>
<label>持卡人</label>
<div class="username">{{userName}}</div>
</li>
<li>
<label>银行卡</label>
<input id="cardNo" name="cardNo" type="tel" placeholder="请输入本人银行卡号" size="26" maxlength="23">
</li>
<li id="bank-desc" style="display: none;">
<div class="bank-info">
<img id="bank-icon" src="" alt="">
<span id="bank-name"></span>
</div>
</li>
<li>
<label>手机号</label>
<input type="number" placeholder="请输入银行预留手机号" id="mobile" name="mobile" pattern="\d*" maxlength="11">
</li>
</ul>
<a href="" class="open-btn disabled">下一步</a>
<a href="" class="jumpResult">&nbsp;</a>
{{/bindCard}}
<div class="success">
<i class="success-icon"></i>
<p class="success-txt">恭喜您,新增还款银行卡成功!</p>
<a href="" class="open-btn">确认</a>
</div>
<div class="error">
<i class="error-icon"></i>
<p class="error-txt1">对不起,绑定银行卡失败</p>
<p class="error-txt2">失败的原因可能是:银行卡户名、<br/>银行卡、预留手机号不一致</p>
<a href="{{url}}" class="open-btn">重新绑定银行卡</a>
<p class="contact-cs">如有疑问,请联系客服</p>
</div>
</div>
... ...
... ... @@ -143,5 +143,4 @@
如您在使用有货分期过程中遇到还款及资金安全方面问题您可联系信而富客服为,您进行相关处理和解答,联系电话:400-688-8692(工作日9:00-18:00),如您无法联系信而富客服您可联系有货客服,我们将在3个工作日内给您回复,感谢您的理解与支持!
</p>
</div>
</div>
... ...
... ... @@ -35,7 +35,7 @@
<p class="detail-txt1">近7日待还款</p>
<p class="detail-txt1">¥<span class="detail-txt2">{{dayAmt}}</span></p>
{{#if isOverdue}}
<p class="detail-txt3">您有¥{{overAmt}}已逾期,点击<a href="/home/installment/repay/overdue">查看详情</a></p>
<p class="detail-txt3">您有¥{{overAmt}}已逾期,点击<a href="/home/installment/repay/overdue">查看详情</a></p>
{{/if}}
<a href="/home/installment/repay/7daylist" class="see-btn">明细</a>
</div>
... ...
... ... @@ -20,10 +20,19 @@
{{/ success}}
{{# error}}
<div class="error">
<i class="success-icon"></i>
<p class="error-txt1">审核未通过,暂时无法授信</p>
<p class="error-txt2">在有货更多的消费,增加信用度,<br>会大大提升审核通过率噢</p>
<a href="{{url}}" class="open-btn">去逛逛</a>
<i class="error-icon"></i>
<p class="error-txt1">审核未通过暂时无法授信</p>
<p class="error-txt2">可能原因:姓名、身份证、银行卡不匹配</p>
<a href="/home/installment/starting-service" class="open-btn">重新申请</a>
</div>
{{/ error}}
{{#cancel}}
<div class="cancel">
<i class="cancel-icon"></i>
<p class="cancel-txt1">账户已注销</p>
<p class="cancel-txt2">您的有货分期账户经本人确认已注销,<br>如有疑问,请联系客服。<br>提示:已注销用户不可再开通</p>
<p></p>
<a href="{{url}}" class="open-btn">先去逛逛</a>
</div>
{{/cancel}}
</div>
... ...
... ... @@ -90,5 +90,4 @@
{{#isRepaymentAllCompleted order.status}}
<div class="all-completed">已还清</div>
{{/isRepaymentAllCompleted}}
</div>
</div>
\ No newline at end of file
... ...
... ... @@ -21,4 +21,3 @@
</li>
{{/each}}
{{/if}}
... ...
... ... @@ -13,7 +13,7 @@
<input id="list-{{key}}" type="checkbox" class="installment-check-btn" {{#if isChecked}}checked{{/if}}/>
<label for="list-{{key}}">
<div class="cont">
<p>¥{{currNoFeeAmt}}</p>
<p>¥{{currAmt}}</p>
<p>【全{{stage}}期】{{billInfo}}</p>
</div>
</label>
... ... @@ -32,5 +32,5 @@
</ul>
{{> installment/repayment-bottom}}
{{/if}}
{{/data}}
{{/data}}
</div>
... ...
<div class="installment-page">
<div class="server-crash">
<i class="refresh-icon"></i>
<p>接口调用失败,服务器可能累了,<br>重新加载给个鼓励吧!</p>
<a href="{{url}}" class="open-btn">重新加载</a>
</div>
</div>
... ...
... ... @@ -53,7 +53,7 @@
</div>
<div class="agreements">
<input id="accept-agreements" name="agreements" type="checkbox" class="installment-check-btn"/>
<input id="accept-agreements" name="agreements" type="checkbox" class="installment-check-btn" checked/>
<label for="accept-agreements">
<div class="text-label">免费开通,详情请见
<a id="agreements" href="" data-href="/home/installment/agreement">《有货分期-信而富用户服务协议&借款服务协议》</a>
... ...
<div class="installment-only">
<h2>{{title}}</h2>
{{!--<h2>{{title}}</h2>--}}
{{> common/floor-header-more}}
<div id="goods-list" class="goods-list clearfix">
{{# goods}}
{{> common/goods}}
... ...
... ... @@ -40,6 +40,7 @@ passport.use(new LocalStrategy({
return done('登录参数错误', null);
}
let verifyEmail = helpers.verifyEmail(username);
// 国际号码验证取消
... ... @@ -58,7 +59,7 @@ passport.use(new LocalStrategy({
let shoppingKey = cookie.getShoppingKey(req);
AuthHelper.signinAes(area, username, password, shoppingKey).then((result) => {
AuthHelper.signin(area, username, password, shoppingKey).then((result) => {
if (result.code && result.code === 200 && result.data.uid) {
done(null, result.data);
} else {
... ...
/**
* 登录注册密码加密
* 登录注册密码加密,uid加密
* @author: wsl<shuiling.wang@yoho.cn>
* @date: 2016/07/07
*/
'use strict';
const crypto = require('crypto');
const crypto = global.yoho.crypto;
/**
* 密码加密
**/
const aesPwd = (pwd) => {
let algorithm = 'aes-128-ecb';
let key = 'yoho9646yoho9646';
let clearEncoding = 'utf8';
let cipherEncoding = 'base64';
let iv = '';
let cipher = crypto.createCipheriv(algorithm, key, iv);
let cipherChunks = [];
cipherChunks.push(cipher.update(pwd, clearEncoding, cipherEncoding));
cipherChunks.push(cipher.final(cipherEncoding));
return crypto.encryption('yoho9646yoho9646', pwd);
};
return cipherChunks.join('');
/**
* uid加密
**/
const encryptionUid = (uid) => {
return crypto.encryption('yoho9646abcdefgh', uid + '');
};
module.exports = {
aesPwd
aesPwd,
encryptionUid
};
... ...
... ... @@ -64,9 +64,10 @@ class Auth {
return Auth.profile(uid).then((userInfo) => {
let token = sign.makeToken(uid);
let data = userInfo.data;
let encryptionUid = aes.encryptionUid(data.uid);
if (data) {
let uidCookie = `${data.profile_name}::${data.uid}::${data.vip_info.title}::${token}`;
let uidCookie = `${data.profile_name}::${encryptionUid}::${data.vip_info.title}::${token}`;
res.cookie('_UID', uidCookie, {
domain: 'yohobuy.com',
... ...
... ... @@ -308,15 +308,15 @@ const getSizeInfo = (sizeInfo) => {
dest.productDetail.enTitle = 'DETAILS';
dest.productDetail.desc = productIntro.replace(/\r\n\t/g, '').
replace(/<\/p>/g, '').
replace(/<img src=/g, '<img class="lazy" src="data:image/gif;' +
replace(/<\/p>/g, '').
replace(/<img src=/g, '<img class="lazy" src="data:image/gif;' +
'base64,R0lGODlhAQABAJEAAAAAAP///93d3f///yH5BAEAAAMALAAAAAABAAEAAAICVAEAOw=="' +
' data-original=').
replace(/<img border="0" src=/g, '<img border="0" class="lazy" ' +
replace(/<img border="0" src=/g, '<img border="0" class="lazy" ' +
'src="data:image/gif;base64,' +
'R0lGODlhAQABAJEAAAAAAP///93d3f///yH5BAEAAAMALAAAAAABAAEAAAICVAEAOw=="' +
' data-original=').
replace(/.jpg/g, '.jpg?imageMogr2/thumbnail/750x/quality/90');
replace(/.jpg/g, '.jpg?imageMogr2/thumbnail/750x/quality/90');
}
// 清空变量,释放内存
... ...
... ... @@ -40,15 +40,7 @@ module.exports = {
retries: 0
},
interfaceShunt: {
useInterfaceShunt: false,
tencentServers: {
api: ['123.206.1.98', '123.206.2.80'],
service: ['123.206.1.98', '123.206.2.80']
},
awsServers: {
api: 'app-java-168863769.cn-north-1.elb.amazonaws.com.cn',
service: 'service-yoho-579825100.cn-north-1.elb.amazonaws.com.cn'
}
open: false
},
loggers: {
infoFile: {
... ... @@ -101,15 +93,8 @@ if (isProduction) {
useOneapm: true,
useCache: true,
interfaceShunt: {
useInterfaceShunt: false,
tencentServers: {
api: ['123.206.1.98', '123.206.2.80'],
service: ['123.206.1.98', '123.206.2.80']
},
awsServers: {
api: 'app-java-168863769.cn-north-1.elb.amazonaws.com.cn',
service: 'service-yoho-579825100.cn-north-1.elb.amazonaws.com.cn'
}
open: true,
url: 'http://123.206.2.55/strategy'
}
});
} else if (isTest) {
... ...
... ... @@ -8,28 +8,6 @@ function async_load(){
j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=
'//www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);
})(window,document,'script','dataLayer','GTM-W958MG');
(function() {
var hm = document.createElement("script");
hm.src = "//static.yohobuy.com/js/analytics/analysis.js";
hm.async = 1;
var s = document.getElementsByTagName("script")[0];
s.parentNode.insertBefore(hm, s);
})();
}
window.addEventListener('load', async_load, false);
</script>
<script>
window._py = window._py||[];
window._py.push(['a', 'MC..o8vMMWxEXDCiqYckD81lUX']);
window._py.push(['domain','stats.ipinyou.com']);
window._py.push(['e','']);
if(typeof _goodsData!='undefined'){
window._py.push(['pi',_goodsData]);
}
-function(d){
var f = 'https:' == d.location.protocol;var c = d.createElement('script');c.type='text/javascript';c.async=1;
c.src=(f ? 'https' : 'http') + '://'+(f?'fm.ipinyou.com':'fm.p0y.cn')+'/j/t/adv.js';
var h = d.getElementsByTagName("script")[0];h.parentNode.insertBefore(c, h);
}(document);
</script>
\ No newline at end of file
... ...
{
"name": "m-yohobuy-node",
"version": "4.9.12",
"version": "4.9.20",
"private": true,
"description": "A New Yohobuy Project With Express",
"repository": {
... ... @@ -56,7 +56,7 @@
"uuid": "^2.0.2",
"winston": "^2.2.0",
"winston-daily-rotate-file": "^1.2.0",
"yoho-node-lib": "0.0.43"
"yoho-node-lib": "0.0.47"
},
"devDependencies": {
"autoprefixer": "^6.3.7",
... ...

5.13 KB | W: | H:

1.65 MB | W: | H:

  • 2-up
  • Swipe
  • Onion skin
... ... @@ -28,10 +28,11 @@ var $window = $(window),
var mySwiper;
*/
var avatarKey, bannerLen, res, avatarSwiper, avatarSwiperClone, getIndexHtml, bannerSwiper,
$avatarClone, $avatarWrap, starIScroll;
var avatarKey, bannerLen, res, avatarSwiper, getIndexHtml, bannerSwiper,
$avatarWrap, starIScroll;
var swiperNum = $('.avatar-wrap .swiper-slide').width() / 2;
var swiperNum = $('.avatar-wrap .swiper-slide').width() / 2,
topBanner = $('.banner-top');
// var $gif = $('img[data-original*="gif"]');
... ... @@ -53,6 +54,7 @@ $('#yoho-header, .head-tab').on('touchmove', function() {
return false;
});
// inView(document.querySelectorAll('img[data-original*="gif"]'))
// .on('enter', function() {
// console.log(1);
... ... @@ -99,25 +101,26 @@ function bindAvatar(dom) {
avatarKey = dom.index();
if (!dom.hasClass('swiper-slide-active')) {
//if (avatarKey >= (2 * bannerLen + 1)) {
// if (avatarKey >= (2 * bannerLen + 1)) {
// avatarSwiperClone && avatarSwiperClone.slideTo(bannerLen + 1, 0);
// avatarSwiper.slideTo(bannerLen + 1, 0);
//} else if (avatarKey <= (bannerLen - 1)) {
// } else if (avatarKey <= (bannerLen - 1)) {
// avatarSwiperClone && avatarSwiperClone.slideTo(2 * bannerLen - 1, 0);
// avatarSwiper.slideTo(2 * bannerLen - (bannerLen - avatarKey), 0);
//} else {
avatarSwiperClone && avatarSwiperClone.slideTo(avatarKey, 200);
avatarSwiper.slideTo(avatarKey, 200);
//}
// } else {
// avatarSwiperClone && avatarSwiperClone.slideTo(avatarKey, 200);
avatarSwiper.slideTo(avatarKey, 200);
// }
return false;
}
}
function setIndexAction() {
$('.avatar').each(function(key, item) {
$(item).addClass('avatar-' + key);
});
// $('.avatar').each(function(key, item) {
// $(item).addClass('avatar-' + key);
// });
// 明星头像 swiper 初始化
if (bannerLen > 1) {
... ... @@ -125,7 +128,7 @@ function setIndexAction() {
lazyLoading: true,
lazyLoadingInPrevNextAmount: 3,
//loop: true,
// loop: true,
initialSlide: 2,
centeredSlides: true,
slidesPerView: 'auto',
... ... @@ -185,13 +188,13 @@ function initAction() {
$avatarWrap = $('.avatar-wrap');
bannerLen = $('.avatar-wrap').find('.swiper-slide').length;
if ($avatarClone) {
$avatarClone.remove();
}
// if ($avatarClone) {
// $avatarClone.remove();
// }
$loadingTip.before($('.avatar-swiper').clone().addClass('avatar-clone').hide());
$avatarClone = $('.avatar-clone');
// $avatarClone = $('.avatar-clone');
$('img.lazy').lazyload({
effect: 'fadeIn'
... ... @@ -212,10 +215,10 @@ getIndexHtml = function() {
})
.done(function(data) {
if (data) {
if (avatarSwiperClone) {
avatarSwiperClone.destroy(true, true);
avatarSwiperClone = null;
}
// if (avatarSwiperClone) {
// avatarSwiperClone.destroy(true, true);
// avatarSwiperClone = null;
// }
$mainContent.html(data);
... ... @@ -228,6 +231,13 @@ getIndexHtml = function() {
});
};
// $(window).ready(function() {
// topBannerH = $('.banner-top').height();
// console.log('init'+topBannerH);
// });
// 下拉刷新,上拉加载
starIScroll = new PullRefresh('.star-main', {
pullDown: function() {
... ... @@ -239,15 +249,16 @@ starIScroll = new PullRefresh('.star-main', {
});
starIScroll.iScroll.on('scrollStart', function() {
// 下拉
// if (this.directionY === -1) {
// $loadingTip.slideDown();
// }
// $gif.css('display', 'none');
bannerSwiper && bannerSwiper.startAutoplay();
// 下拉
// if (this.directionY === -1) {
// $loadingTip.slideDown();
// }
// $gif.css('display', 'none');
bannerSwiper && bannerSwiper.stopAutoplay();
});
starIScroll.iScroll.on('scroll', function() {
starIScroll.iScroll.on('scroll', function() {
$window.trigger('scroll');
// var avatarOffsetT;
//
// if (this.directionY !== -1) {
... ... @@ -289,14 +300,18 @@ starIScroll.iScroll.on('scroll', function() {
// } else {
// $avatarClone.hide();
// }
});
});
starIScroll.iScroll.on('scrollEnd', function() {
// $loadingTip.slideUp();
// $gif.css('display', 'block');
bannerSwiper && bannerSwiper.stopAutoplay();
// $loadingTip.slideUp();
// $gif.css('display', 'block');
if (-this.y <= topBanner.height()) {
bannerSwiper && bannerSwiper.startAutoplay();
}
});
window.setCookie('guangStarUid', window.queryString.uid);
// $('img').on('load', function() {
... ... @@ -359,3 +374,6 @@ function articleImgAction(dom, key) {
}
}
*/
... ...
/**
* 银行卡校验
* @author: wsl<shuiling.wang@yoho.cn>
* @date: 2016/08/25
*/
var $ = require('yoho-jquery');
var tip = require('../plugin/tip');
var debounce = require('lodash/debounce');
var debounceFn = debounce(function(cardNo, formModel) {
formModel.bankCode = '';
formModel.bankName = '';
// 获取银行信息
$.get('/home/installment/bank-info', {cardNo: cardNo}).then(function(result) {
if (result.code === 200) {
if (result.data.bankCode) {
formModel.bankCode = result.data.bankCode;
formModel.bankName = result.data.bankName;
// 设置银行名称
$('#bank-name').text(result.data.bankName);
// 设置银行图标
$('#bank-icon').show().attr('src',
window.STATIC_RESOURCE_PATH +
'/img/home/bank-icons/' + result.data.bankCode + '.png');
$('#bank-desc').show();
}
// 返回1不支持, 孟令阶
if (result && result.data && result.data.businessSupport === '1') {
$('#bank-name').text('暂不支持此银行卡');
$('#bank-desc').show();
$('#bank-icon').hide();
}
} else {
tip.show(result.message);
$('#bank-desc').hide();
}
});
}, 1000);
var checkCard = function(formModel) {
// 银行卡格式化
$('#cardNo').keyup(function() {
var value = $(this).val();
var cardNo = $(this).val().replace(/\s/g, '');
$(this).val(value.replace(/[^\d]/g, '').replace(/(\d{4})(?=\d)/g, '$1 ')).trigger('change');
if (cardNo && cardNo.length < 16) {
$('#bank-desc').hide();
}
}).blur(function() {
var cardNo = $(this).val().replace(/\s/g, '');
if (cardNo && cardNo.length >= 16) {
debounceFn(cardNo, formModel);
} else {
$('#bank-desc').hide();
}
});
};
module.exports = checkCard;
... ...
/**
* 新增银行卡
* @author: wsl<shuiling.wang@yoho.cn>
* @date: 2016/08/25
*/
var $ = require('yoho-jquery');
var tip = require('../plugin/tip');
var checkCard = require('./bind-card-check');
var applyButton = $('.open-btn');
var flag = true;
var formData = {
cardNo: '',
mobile: '',
bankName: '',
bankCode: ''
};
var validateForm = function() {
var ret = false;
if (formData.cardNo &&
formData.mobile.length === 11 &&
formData.bankName &&
formData.bankCode) {
applyButton.removeClass('disabled');
ret = true;
} else {
applyButton.addClass('disabled');
ret = false;
}
return ret;
};
checkCard(formData);
// 输入框改变时同时更新模型
$('input').on('input', function() {
var name = $(this).attr('name');
formData[name] = $(this).val();
validateForm();
});
applyButton.on('click', function() {
var self = this;
var ret = false;
if (!flag || $(this).hasClass('disabled') || !validateForm()) {
return false;
}
if (!/^1[3|4|5|8|7][0-9]{9}$/.test(formData.mobile)) {
tip.show('手机号输入不正确!');
return false;
}
flag = false;
$.ajax({
type: 'GET',
url: '/home/installment/post-account',
data: formData,
async: false,
success: function(data) {
var params = {
action: 'go.bindCardResult',
params: {
status: 0
}
};
var url = location.href + '&openby:yohobuy=';
if (data.code === 200) {
params.params.status = 1;
ret = true;
} else if (data.code === 500) {
tip.show('连接超时');
flag = true;
} else {
params.params.message = data.message;
ret = true;
}
url += encodeURIComponent(JSON.stringify(params));
$(self).attr('href', url);
},
error: function() {
tip.show('网络断开连接了~');
flag = true;
}
});
return ret;
});
... ...
var $ = require('yoho-jquery');
var tip = require('../plugin/tip');
var debounce = require('lodash/debounce');
var yohoApp = require('../yoho-app');
var Timer = function() {
this.counter = 0;
... ... @@ -16,7 +16,7 @@ var FormModel = function() {
bankCode: '',
mobile: '',
snsCheckCode: '',
agreements: ''
agreements: 'on'
});
};
... ... @@ -36,7 +36,9 @@ var validateForm = function() {
formModel.mobile &&
formModel.snsCheckCode &&
formModel.agreements === 'on') {
applyButton.removeClass('disabled');
if (!applyButton.data('running')) {
applyButton.removeClass('disabled');
}
ret = true;
} else {
applyButton.addClass('disabled');
... ... @@ -53,44 +55,15 @@ var validateForm = function() {
return ret;
};
const clearVerifyCode = function() {
var checkCard = require('./bind-card-check');
var clearVerifyCode = function() {
formModel.snsCheckCode = '';
$('#sns-check-code').val('');
};
var debounceFn = debounce(function(cardNo) {
formModel.bankCode = '';
formModel.bankName = '';
// 获取银行信息
$.get('/home/installment/bank-info', {cardNo: cardNo}).then(function(result) {
if (result.code === 200) {
if (result.data.bankCode) {
formModel.bankCode = result.data.bankCode;
formModel.bankName = result.data.bankName;
// 设置银行名称
$('#bank-name').text(result.data.bankName);
// 设置银行图标
$('#bank-icon').show().attr('src',
window.STATIC_RESOURCE_PATH +
'/img/home/bank-icons/' + result.data.bankCode + '.png');
$('#bank-desc').show();
}
// 返回1不支持, 孟令阶
if (result && result.data && result.data.businessSupport === '1') {
$('#bank-name').text('暂不支持此银行卡');
$('#bank-desc').show();
$('#bank-icon').hide();
}
} else {
tip.show(result.message);
$('#bank-desc').hide();
}
});
}, 200);
checkCard(formModel);
/**
* 倒计时
... ... @@ -166,6 +139,8 @@ $('#send-sms').click(function() {
return false;
}
$(self).data('running', true);
$.get('/home/installment/starting-service/verify-code', {
mobile: formModel.mobile
}).then(function(result) {
... ... @@ -185,46 +160,27 @@ $('#send-sms').click(function() {
tip.show(result.message);
$(self).data('running', false);
}
}).done(function() {
$(self).data('running', false);
});
return false;
});
/**
* 银行卡格式化
*/
$('#cardNo').keyup(function() {
var value = $(this).val();
var cardNo = $(this).val().replace(/\s/g, '');
$(this).val(value.replace(/[^\d]/g, '').replace(/(\d{4})(?=\d)/g, '$1 ')).trigger('change');
if (cardNo && cardNo.length < 16) {
$('#bank-desc').hide();
}
}).blur(function() {
var cardNo = $(this).val().replace(/\s/g, '');
if (cardNo && cardNo.length >= 16) {
debounceFn(cardNo);
} else {
$('#bank-desc').hide();
}
});
// 输入框改变时同时更新模型
/*
$('input').on('change', function() {
var name = $(this).attr('name');
$('input').on('change', function() {
var name = $(this).attr('name');
if ($(this).is(':checkbox')) {
formModel[name] = $(this).is(':checked') ? $(this).val() : null;
} else {
formModel[name] = $(this).val();
}
if ($(this).is(':checkbox')) {
formModel[name] = $(this).is(':checked') ? $(this).val() : null;
} else {
formModel[name] = $(this).val();
}
validateForm();
});
*/
validateForm();
});
*/
// validateForm();
... ... @@ -249,39 +205,17 @@ setInterval(function() {
$('#apply-button').click(function() {
var ret = false;
var that = $(this);
var asyncMode = yohoApp.isiOS;
if ($(this).hasClass('disabled') || !validateForm()) {
return false;
} else {
$(this).addClass('disabled').text('处理中...').data('running', true);
}
// $.ajax({
// method: 'post',
// url: '/home/installment/activate-service',
// data: formModel,
// async: false
// }).then(function(result) {
// if (result.code === 200) {
// if (result.data.result === 'success') {
// // 调用成功
// ret = true;
// } else {
// // 调用失败
// if (result.data.resultMsgType === '1') {
// tip.show(result.data.resultMsg);
// }
// clearVerifyCode();
// }
// } else {
// tip.show(result.message);
// clearVerifyCode();
// }
// });
$.ajax({
method: 'get',
async: false,
async: asyncMode,
url: '/home/installment/starting-service/check-verify-code',
data: {
mobile: formModel.mobile,
... ... @@ -293,7 +227,7 @@ $('#apply-button').click(function() {
method: 'post',
url: '/home/installment/activate-service',
data: formModel,
async: false
async: asyncMode
});
} else {
clearVerifyCode();
... ... @@ -302,6 +236,8 @@ $('#apply-button').click(function() {
}).then(function(result) {
var params;
that.removeClass('disabled').text('下一步').data('running', false);
if (!result) {
return;
}
... ... @@ -314,12 +250,21 @@ $('#apply-button').click(function() {
};
if (result.code === 200 && result.data) {
that.attr('href', location.pathname + '?openby:yohobuy=' + encodeURIComponent(JSON.stringify(params)));
if (asyncMode) {
yohoApp.invokeMethod('go.instalmentActivated', params.params);
} else {
that.attr('href', location.pathname + '?openby:yohobuy=' + encodeURIComponent(JSON.stringify(params)));
}
ret = true;
} else if (result.code === 500) {
// 接口可能超时返回审核中 by 孟令阶
params.params.status = '1';
that.attr('href', location.pathname + '?openby:yohobuy=' + encodeURIComponent(JSON.stringify(params)));
if (asyncMode) {
yohoApp.invokeMethod('go.instalmentActivated', params.params);
} else {
that.attr('href', location.pathname + '?openby:yohobuy=' + encodeURIComponent(JSON.stringify(params)));
}
ret = true;
} else {
tip.show(result.message);
... ... @@ -340,7 +285,7 @@ $('input[maxlength]').keyup(function() {
});
$('#agreements').click(function() {
const params = {
var params = {
action: 'go.instalmentProtocol',
params: {
protocolUrl: location.protocol + '//' + location.hostname + location.port + $(this).data('href')
... ...
... ... @@ -19,7 +19,7 @@ var repayment = new Repayment({
index: li.index(),
orderCode: li.data('billNo'),
termNo: li.data('currterm'),
amount: parseFloat(li.data('currnofeeamt')),
amount: parseFloat(li.data('curramt')),
fee: parseFloat(li.data('currfee')) + 0
};
... ... @@ -44,22 +44,26 @@ var repayment = new Repayment({
require('./overdue-notice');
$(CHECKBOX_SELECTOR + ':checkbox').click(function() {
var selection = repayment.getSelection();
var isSkipped = false;
var lastIndex = 0;
var self = this;
var isSkipped = false,
self = this,
billNo = $(self).parent().data('billNo'),
li = $('li[data-bill-no=' + billNo + ']'),
selection = li.find('input:checked'),
lastIndex = li.eq(0).data('currterm');
selection.forEach(function(sel) {
if ((sel.index + 1) - lastIndex > 1) {
selection.parent().each(function(index, sel) {
var key = $(sel).data('currterm');
if ((key + 1) - lastIndex > 1) {
isSkipped = true;
} else {
lastIndex = sel.index + 1;
lastIndex = key + 1;
}
});
if (isSkipped) {
setTimeout(function() {
tip.show($(self).is(':checked') ? '请按时间顺序取消选择,不可以跨期' : '请按时间顺序添加还款,不可以跨期');
tip.show('同一个分期订单不能跨期还款,请按时间顺序还款');
}, 0);
return false;
}
... ...
/**
* YOHO-SDK
*
* 与原生 APP 交互的代码
* 所有函数要做降级处理
* 假如不是 YOHO App,在浏览器实现对应的功能
* 浏览器不支持的功能,给出提示,控制台不能报错,不影响后续代码执行
*
* 希望能与 微信 JS-SDK 一样方便
*/
var tip = require('./plugin/tip');
/* 空方法 */
var emptyFn = function() {};
/* 提示信息 */
var tipInfo = '暂不支持,请在YOHO!BUY应用中打开';
var yoho = {
/**
* 判断是否是 APP
*/
isApp: /YohoBuy/i.test(navigator.userAgent || ''),
isiOS: /\(i[^;]+;( U;)? CPU.+Mac OS X/i.test(navigator.userAgent || ''),
isAndroid: /Android/i.test(navigator.userAgent || ''),
/**
* JS 与 APP 共享的对象
*/
data: window.yohoInterfaceData,
ready: function(callback) {
if (this.isApp) {
document.addEventListener('deviceready', callback);
} else {
return callback();
}
},
/**
* 调用APP原生方法
* @param method 方法名称
* @param args 传递给 APP 的参数 {"index":tab_index}
* @param success 调用成功的回调方法
* @param fail 调用失败的回调方法
*/
invokeMethod: function(method, args, success, fail) {
var appInterface = window.yohoInterface;
if (this.isApp && appInterface) {
appInterface.triggerEvent(success || emptyFn, fail || emptyFn, {
method: method,
arguments: args
});
} else {
tip.show(tipInfo);
}
},
/**
* 原生调用 JS 方法
* @param name 方法名
* @param callback 回调
*/
addNativeMethod: function(name, callback) {
var appInterface = window.yohoInterface;
// 延迟 500ms 注入
setTimeout(function() {
if (appInterface) {
appInterface[name] = callback;
}
}, 500);
}
};
module.exports = yoho;
... ...
... ... @@ -2,3 +2,4 @@
@import "star";
@import "special";
@import "collocation";
... ...
.add-account-page {
.add-form {
margin: 30px 0 80px;
background: #fff;
border-top: 1px solid #e0e0e0;
border-bottom: 1px solid #e0e0e0;
overflow: hidden;
box-sizing: border-box;
li {
width: 100%;
height: 86px;
border-top: 1px solid #e0e0e0;
margin-left: 30px;
box-sizing: border-box;
}
li:first-child {
border-top: none;
}
label {
color: #444;
font-size: 34px;
float: left;
line-height: 86px;
}
input {
font-size: 28px;
height: 40px;
line-height: 40px;
color: #444;
float: left;
border: none;
background: transparent;
margin: 23px 0 0 60px;
width: 410px;
font-family: helvetica, Arial, "黑体";
}
.username {
color: #b0b0b0;
float: left;
font-size: 28px;
width: 410px;
height: 40px;
margin: 23px 0 0 60px;
line-height: 40px;
}
.bank-info {
padding-left: 165px;
margin-top: 26px;
img {
width: 32px;
height: 32px;
display: inline-block;
}
span {
line-height: 32px;
position: absolute;
margin-left: 10px;
margin-top: 1px;
}
}
}
.disabled {
opacity: 0.5;
}
.success {
display: none;
.success-icon {
margin-top: 208px;
}
.success-txt {
text-align: center;
font-size: 24px;
color: #444;
margin-bottom: 90px;
}
}
.error {
display: none;
.error-txt1 {
color: #444;
font-size: 24px;
}
.error-txt2 {
color: #b0b0b0;
font-size: 22px;
line-height: 36px;
margin: 10px 0 105px;
}
.contact-cs {
width: 100%;
position: fixed;
bottom: 45px;
text-align: center;
color: #444;
font-size: 28px;
}
}
}
... ...
.bank-card-page {
.bank-card-list {
padding: 30px 30px 0;
}
li {
width: 580px;
height: 200px;
margin-bottom: 30px;
position: relative;
background: #000;
border-radius: 10px;
background-size: contain;
span {
position: absolute;
right: 30px;
bottom: 30px;
color: #fff;
font-size: 40px;
}
}
.card-bg-abc {
background: resolve("home/bank-icons/bank-ABC.png") no-repeat;
background-size: contain;
}
.card-bg-boc {
background: resolve("home/bank-icons/bank-BOC.png") no-repeat;
background-size: contain;
}
.card-bg-ccb {
background: resolve("home/bank-icons/bank-CCB.png") no-repeat;
background-size: contain;
}
.card-bg-ceb {
background: resolve("home/bank-icons/bank-CEB.png") no-repeat;
background-size: contain;
}
.card-bg-cib {
background: resolve("home/bank-icons/bank-CIB.png") no-repeat;
background-size: contain;
}
.card-bg-citic {
background: resolve("home/bank-icons/bank-CITIC.png") no-repeat;
background-size: contain;
}
.card-bg-cmbc {
background: resolve("home/bank-icons/bank-CMBC.png") no-repeat;
background-size: contain;
}
.card-bg-guangda {
background: resolve("home/bank-icons/bank-guangda.png") no-repeat;
background-size: contain;
}
.card-bg-icbc {
background: resolve("home/bank-icons/bank-ICBC.png") no-repeat;
background-size: contain;
}
.card-bg-payh {
background: resolve("home/bank-icons/bank-PAYH.png") no-repeat;
background-size: contain;
}
.card-bg-psbc {
background: resolve("home/bank-icons/bank-PSBC.png") no-repeat;
background-size: contain;
}
}
... ...
.installment-help {
padding: 30px;
margin: 0;
background-color: #fff;
font-family: "微软雅黑";
color: #444;
font-weight: 300;
.help-title {
text-align: center;
font-size: 28px;
margin-top: 10px;
font-weight: bold;
}
.help-group {
text-align: left;
margin: 0 5px 45px;
h2 {
font-size: 26px;
font-weight: bold;
}
p {
font-size: 26px;
line-height: 40px;
margin-top: 10px;
}
.remind {
color: #f00;
}
.underline {
text-decoration: underline;
}
.bold {
font-weight: bold;
}
ul {
list-style: disc;
list-style-position: inside;
margin-left: 22px;
}
table {
width: 92%;
text-align: center;
margin: 0 4%;
border: 1px solid #000;
font-size: 22px;
td {
text-align: center;
border-right: 1px solid #000;
}
tr:last-child {
border-top: 1px solid #000;
}
}
}
}
.installment-agreement {
p {
text-indent: 2em;
}
ul {
list-style-type: none;
li {
display: inline-block;
}
}
.indent2 {
text-indent: 2em;
display: inline-block;
}
}
.installment-help {
padding: 30px;
margin: 0;
background-color: #fff;
font-family: "微软雅黑";
color: #444;
font-weight: 300;
.help-title {
text-align: center;
font-size: 28px;
margin-top: 10px;
font-weight: bold;
}
.help-group {
text-align: left;
margin: 0 5px 45px;
h2 {
font-size: 26px;
font-weight: bold;
}
p {
font-size: 26px;
line-height: 40px;
margin-top: 10px;
}
.remind {
color: #f00;
}
.underline {
text-decoration: underline;
}
.bold {
font-weight: bold;
}
ul {
list-style: disc;
list-style-position: inside;
margin-left: 22px;
}
table {
width: 92%;
text-align: center;
margin: 0 4%;
border: 1px solid #000;
font-size: 22px;
td {
text-align: center;
border-right: 1px solid #000;
}
tr:last-child {
border-top: 1px solid #000;
}
}
}
}
.installment-agreement {
p {
text-indent: 2em;
}
ul {
list-style-type: none;
li {
display: inline-block;
}
}
.indent2 {
text-indent: 2em;
display: inline-block;
}
}
... ...
... ... @@ -2,7 +2,9 @@
@import "starting-service";
@import "repayment-list";
@import "order";
@import "add-account";
@import "help";
@import "bank-card";
.no-result {
.result-icon {
... ...
... ... @@ -64,6 +64,7 @@
border-radius: 6px;
margin: 0 auto;
display: block;
font-size: 28px;
}
.installment-only {
... ... @@ -71,6 +72,13 @@
margin-top: 30px;
border-top: 1px solid #dedee0;
.floor-header-more {
height: 85px;
line-height: 85px;
margin: 0;
border-top: none;
}
h2 {
height: 85px;
line-height: 85px;
... ... @@ -93,7 +101,7 @@
margin: 214px auto 50px;
}
.success-icon {
.error-icon {
background: resolve("home/review-img-2.png") no-repeat;
background-size: contain;
width: 208px;
... ... @@ -102,6 +110,33 @@
margin: 94px auto 60px;
}
.success-icon {
background: resolve("home/review-img-4.png") no-repeat;
background-size: contain;
width: 208px;
height: 208px;
display: block;
margin: 94px auto 60px;
}
.cancel-icon {
background: resolve("home/review-img-5.png") no-repeat;
background-size: contain;
width: 208px;
height: 208px;
display: block;
margin: 196px auto 60px;
}
.refresh-icon {
background: resolve("home/review-img-6.png") no-repeat;
background-size: contain;
width: 168px;
height: 168px;
display: block;
margin: 225px auto 35px;
}
.font-b {
font-size: 30px;
text-align: center;
... ... @@ -154,6 +189,33 @@
}
}
.cancel {
p {
text-align: center;
}
.cancel-txt1 {
font-size: 24px;
color: #444;
}
.cancel-txt2 {
color: #bbb;
font-size: 22px;
line-height: 40px;
margin: 10px 0 65px;
}
}
.server-crash {
p {
text-align: center;
color: #444;
font-size: 24px;
margin-bottom: 100px;
}
}
.detail-tab {
background: #000;
height: 90px;
... ...
... ... @@ -360,6 +360,10 @@
float: right;
color: #b1b1b1;
}
a {
display: block;
}
}
}
}
... ...
... ... @@ -53,16 +53,16 @@ a {
}
@font-face {
font-family: "iconfont";
src: resolve("iconfont.eot"); /* IE9 */
src: resolve("iconfont.eot?#iefix") format("embedded-opentype"), resolve("iconfont.woff") format("woff"), resolve("iconfont.ttf") format("truetype"), resolve("iconfont.svg#iconfont") format("svg"); /* iOS 4.1- */
font-family: 'iconfont';
src: resolve('iconfont.eot'); /* IE9 */
src: resolve('iconfont.eot?#iefix') format('embedded-opentype'), resolve('iconfont.woff') format('woff'), resolve('iconfont.ttf') format('truetype'), resolve('iconfont.svg#iconfont') format('svg'); /* iOS 4.1- */
}
.iconfont {
text-decoration: none;
font-style: normal;
font-size: 24px;
font-family: "iconfont" !important;
font-family: 'iconfont' !important;
-webkit-font-smoothing: antialiased;
-webkit-text-stroke-width: 0.4px;
-moz-osx-font-smoothing: grayscale;
... ... @@ -73,7 +73,7 @@ a {
display: none;
text-align: center;
width: 70%;
padding: 34PX 0;
padding: 18PX 55PX;
top: 50%;
left: 50%;
margin-left: -35%;
... ...