|
@@ -43,7 +43,8 @@ export default defineComponent({
|
|
|
popupShow: false,
|
|
|
paymentStatus: false,
|
|
|
orderAmount: 0, // 订单金额,用于使用优惠券,余额,优惠等
|
|
|
- orderPrice: 0 // 支付金额,最后支付金额
|
|
|
+ orderPrice: 0, // 支付金额,最后支付金额
|
|
|
+ dataLoading: true
|
|
|
}
|
|
|
},
|
|
|
unmounted() {
|
|
@@ -63,6 +64,7 @@ export default defineComponent({
|
|
|
},
|
|
|
async mounted() {
|
|
|
// 判断是否是曲目购买(只有智能陪练才会有入口),其它地方不会有入口
|
|
|
+ this.dataLoading = true
|
|
|
if (this.orderType == 'MUSIC' && this.id) {
|
|
|
try {
|
|
|
const item = await getMusicDetail(this.id)
|
|
@@ -94,7 +96,7 @@ export default defineComponent({
|
|
|
}
|
|
|
this.orderAmount = orderStatus.orderObject.actualPrice || 0
|
|
|
this.orderPrice = orderStatus.orderObject.actualPrice || 0
|
|
|
-
|
|
|
+ this.dataLoading = false
|
|
|
// 0元支付特别处理
|
|
|
if (this.orderPrice === 0 && orderStatus.orderObject.orderType) {
|
|
|
this.loading = true
|
|
@@ -223,13 +225,15 @@ export default defineComponent({
|
|
|
})}
|
|
|
|
|
|
{/* 优惠券使用 */}
|
|
|
- <UseCoupon
|
|
|
- discountPrice={orderStatus.orderObject.discountPrice}
|
|
|
- orderType={this.orderType}
|
|
|
- orderAmount={this.orderAmount}
|
|
|
- onCouponSelect={this.onCouponSelect}
|
|
|
- disabled={orderStatus.orderObject.orderNo ? true : false}
|
|
|
- />
|
|
|
+ {!this.dataLoading && (
|
|
|
+ <UseCoupon
|
|
|
+ discountPrice={orderStatus.orderObject.discountPrice}
|
|
|
+ orderType={this.orderType}
|
|
|
+ orderAmount={this.orderAmount}
|
|
|
+ onCouponSelect={this.onCouponSelect}
|
|
|
+ disabled={orderStatus.orderObject.orderNo ? true : false}
|
|
|
+ />
|
|
|
+ )}
|
|
|
|
|
|
{/* <div class={styles.tips}>
|
|
|
<h3>
|