Authored by TaoHuang

fix by huangtao

... ... @@ -8,7 +8,7 @@
<slot name="price">
<div class="price-info">
<div class="desc">{{desc}}</div>
<div class="price">{{price }}</div>
<div class="price">{{price }}</div>
</div>
</slot>
<slot name="content">
... ... @@ -128,39 +128,39 @@ export default {
this.hide();
this.$emit('paySuccess');
// this.$router.replace({
// name: 'OrderPay',
// query: {
// orderCode: this.orderCode,
// payParams: result.data.payParams,
// extra: this.extra
// }
// });
if (this.$xianyu.isAliApp) {
const page = JSON.parse(this.extra || '{}');
this.$router.replace({
name: 'OrderPay',
query: {
orderCode: this.orderCode,
payParams: result.data.payParams,
extra: this.extra
}
});
this.$xianyu.setXianyuPay({
payURL: result.data.payParams
}, () => {
if (page.forward) {
this.$router.replace(page.forward);
}
}, () => {
if (page.back) {
this.$router.replace(page.back);
}
});
} else {
this.$router.replace({
name: 'OrderPay',
query: {
orderCode: this.orderCode,
payParams: result.data.payParams,
extra: this.extra
}
});
}
// if (this.$xianyu.isAliApp) {
// const page = JSON.parse(this.extra || '{}');
//
// this.$xianyu.setXianyuPay({
// payURL: result.data.payParams
// }, () => {
// if (page.forward) {
// this.$router.replace(page.forward);
// }
// }, () => {
// if (page.back) {
// this.$router.replace(page.back);
// }
// });
// } else {
// this.$router.replace({
// name: 'OrderPay',
// query: {
// orderCode: this.orderCode,
// payParams: result.data.payParams,
// extra: this.extra
// }
// });
// }
}
}
};
... ...
... ... @@ -57,11 +57,25 @@ export default {
methods: {
...mapOrderAction(['fetchOrderStatus']),
openPay() {
const url = config.alipayUrl + '?' + this.payParams;
if (this.$xianyu.isAliApp) {
this.$xianyu.setXianyuPay({
payURL: this.payParams
}, () => {
if (this.page.forward) {
this.$router.replace(this.page.forward);
}
}, () => {
if (this.page.back) {
this.$router.replace(this.page.back);
}
});
} else {
const url = config.alipayUrl + '?' + this.payParams;
this.$xianyu.goXianyuNewPage({
url
});
this.$xianyu.goXianyuNewPage({
url
});
}
},
backAction() {
const page = JSON.parse(this.extra || '{}');
... ...
... ... @@ -9,7 +9,7 @@
@on-num-change="onNumChange"
>
</InputPrice>
<OrderMargin class="order-item order-margin" :data="fee" :super-sell="superSell"></OrderMargin>
<OrderMargin class="order-item order-margin" :data="fee" :super-sell="superSell" :url="tipUrl"></OrderMargin>
<OrderFee class="order-item" :data="fee"></OrderFee>
<AddressInfo :data="address" class="order-item"></AddressInfo>
</Scroll>
... ... @@ -63,7 +63,8 @@ export default {
addNumError: false,
scrollOption: {
bounce: false
}
},
tipUrl: 'https://activity.yoho.cn/feature/6773.html?share_id=9479&title=%E9%97%B2%E9%B1%BC%E6%BD%AE%E5%8D%96%E5%AE%B6%E5%8D%8F%E8%AE%AE'
};
},
activated() {
... ...