Authored by htoooth

Merge branch 'feature/new-product-detail' into release/5.3.1

... ... @@ -386,7 +386,7 @@ const getCoupons = (uid) => api.get('', {
let unuse = [];
let use = [];
_.forEach(result.data.unusable_coupons, i => {
_.get(result, 'data.unusable_coupons', []).forEach(i => {
unuse.push({
code: i.coupon_code,
name: i.coupon_name,
... ... @@ -394,7 +394,8 @@ const getCoupons = (uid) => api.get('', {
canuse: false
});
});
_.forEach(result.data.usable_coupons, i => {
_.get(result, 'data.usable_coupons', []).forEach(i => {
use.push({
code: i.coupon_code,
name: i.coupon_name,
... ...
... ... @@ -59,11 +59,12 @@ const _handelUseYohoCoin = (info) => {
const _handelPaymentInfo = (d) => {
let resData = {};
// 地址信息加密
d.delivery_address.id = crypto.encryption('', `${d.delivery_address.address_id}`);
delete d.delivery_address.address_id;
resData.deliveryAddress = d.delivery_address;
if (d.delivery_address) {
// 地址信息加密
d.delivery_address.id = crypto.encryption('', `${d.delivery_address.address_id}`);
delete d.delivery_address.address_id;
resData.deliveryAddress = d.delivery_address;
}
d.shopping_cart_data.hasCoin = _.round(d.yoho_coin * 100); // 有货币稀释
... ...