浏览代码

feat:活动价格为0时取消支付

zhanghui 1 年之前
父节点
当前提交
d9359d7f41
共有 3 个文件被更改,包括 13 次插入2 次删除
  1. 1 0
      common/js/env.js
  2. 1 1
      components/pay/pay.vue
  3. 11 1
      orderPages/activityDetail/activityDetail.vue

+ 1 - 0
common/js/env.js

@@ -8,6 +8,7 @@ let trialBaseUrl = `https://jje.admin.xinyuekj.com.cn/test-api`
 
 /** 开发环境*/
 let developBaseUrl = `http://65i1sxopd9qp.ngrok.xiaomiqiu123.top`
+// let developBaseUrl = `https://jje.admin.xinyuekj.com.cn/test-api`
 // let developBaseUrl = `http://u2mu3zixu5wm.ngrok.xiaomiqiu123.top`
 // let developBaseUrl = `http://47.108.114.127:10888`
 

+ 1 - 1
components/pay/pay.vue

@@ -384,7 +384,7 @@
 
 	.payType {
 		font-size: 32rpx;
-		font-weight: bord;
+		font-weight: bold;
 		color: #111111;
 		line-height: 48rpx;
 	}

+ 11 - 1
orderPages/activityDetail/activityDetail.vue

@@ -225,11 +225,13 @@ export default {
       console.log(e)
       if(e.payResult){
         uni.showToast({
+          duration: 2000,
           title: '支付成功!'
         });
         this.isActivityCheck = true
       }else {
         uni.showToast({
+          duration: 2000,
           title: '支付失败!',
           icon: 'error'
         });
@@ -280,7 +282,15 @@ export default {
           console.log('++++++++++++++++++订单提交+++++++++++', res)
             uni.hideLoading();
             this.subOrderNo = res.data.data.orderNo
-            this.$refs.myPay.openPopup()
+            if (this.activity.salePrice *1 > 0){
+              this.$refs.myPay.openPopup()
+            }else {
+              uni.showToast({
+                duration: 2000,
+                title: '活动参与成功!'
+              });
+              this.isActivityCheck = true
+            }
           this.requestStatus = false
         }).catch(err => {
           this.requestStatus = false