Authored by 毕凯

Merge branch 'hotfix/jit' into 'gray'

JIT详情页BUG



See merge request !394
... ... @@ -5,6 +5,7 @@ const helpers = global.yoho.helpers;
const paymentProcess = require(global.utils + '/payment-process');
const shoppingAPI = require('./shopping');
const logger = global.yoho.logger;
const payModel = require('../models/pay');
/**
* 转换价格
... ... @@ -326,6 +327,19 @@ exports.searchCoupon = (uid, couponCode) => {
*/
exports.jitDetailData = (uid, cartType, skuList, orderCode, sessionKey,
deliveryId, paymentType, couponCode, yohoCoin) => {
// 订单详情页拆单
if (orderCode) {
return payModel.getOtherDetail({
uid: uid,
orderCode: orderCode,
sessionKey: sessionKey
}).then(result => {
return paymentProcess.transformJit(_.get(result, 'data.package_list', []));
});
}
// 购物车拆单
if (deliveryId) {
// 购物车选择改变字段,重新运算订单数据
... ...
... ... @@ -312,17 +312,9 @@ const orderDetailData = (uid, orderCode) => {
// 为支付的拆单配送信息
if (orderDetail.isMultiPackage && orderDetail.isMultiPackage === 'Y') {
let jitInfo = {
deliveryId: orderDetail.deliveryId,
paymentType: orderDetail.paymentType,
couponCode: orderDetail.couponCode,
yohoCoin: orderDetail.yohoCoin,
cartType: 'ordinary'
};
orderDetail = _.assign(orderDetail, {
isJit: true,
jitDetailUrl: helpers.urlFormat('/cart/index/new/jitDetail', jitInfo)
jitDetailUrl: helpers.urlFormat('/cart/index/new/jitDetail', {orderCode: orderCode})
});
}
... ...
... ... @@ -74,7 +74,7 @@
{{!--搜索列表显示过少,显示猜您喜欢--}}
{{#if @root.suggestion.isMaybeLike}}
<div class="maybe-like-search">您可能喜欢的</div>
<div class="maybe-like-search">你可能喜欢</div>
<div class='maybe-like'>
<div id="goods-list" class="goods-list clearfix"></div>
</div>
... ...
... ... @@ -122,7 +122,7 @@
{{!--搜索列表显示过少,显示猜您喜欢--}}
{{#if @root.suggestion.isMaybeLike}}
<div class="maybe-like-search">您可能喜欢的</div>
<div class="maybe-like-search">你可能喜欢</div>
<div class='maybe-like maybe-like-word'>
<div id="goods-list" class="goods-list clearfix"></div>
</div>
... ...
... ... @@ -390,11 +390,11 @@
line-height: 60px;
background-color: #eee;
text-align: center;
font-size: 16px;
font-size: 20px;
}
.maybe-like-word {
margin-top: none;
margin-top: 0;
border-top: none;
}
}
... ...