浏览代码

Merge branch '2025鹅状元数学' of https://gogs.mtavip.com/wangguoyu/uniProject into 2025鹅状元数学

tanxue 1 天之前
父节点
当前提交
90f083f223
共有 2 个文件被更改,包括 17 次插入5 次删除
  1. 9 1
      pages/chanpinMy/order.vue
  2. 8 4
      pages/chanpinShop/cp1/dingdan.vue

+ 9 - 1
pages/chanpinMy/order.vue

@@ -40,6 +40,9 @@
 	import { reactive, ref } from "vue";
 	import {orderList} from '@/api/shop.js'
 	import { onLoad, onShow } from "@dcloudio/uni-app"
+	import {
+		getUserIsYouke
+	} from "@/utils/common.js"
     const data = reactive({
         page: 0,
         list: [],
@@ -125,9 +128,14 @@
 	}
 	
 
-	onLoad(() => {
+	onLoad((options) => {
 		getMore();
 		// 判断游客 如果是弹出弹窗,忽略和绑定, 忽略删除缓存,绑定更新用户userName 删除缓存
+		// 此时支付成功+游客模式支付进来的情况
+		if(options.zhifu &&getUserIsYouke()){
+			// 弹出绑定手机号弹窗
+			
+		}
 	})
 </script>
 

+ 8 - 4
pages/chanpinShop/cp1/dingdan.vue

@@ -140,9 +140,12 @@
 		checkError: () => {}, // 校验失败
 		payError: () => {}, // 支付失败
 		paySuccess: () => {
+			// 支付成功删除contentInfo 缓存
+			cacheManager.remove("contentInfo");
 			uni.navigateTo({
-				url: "/pages/chanpinMy/order"
+				url: "/pages/chanpinMy/order?zhifu='success'"	
 			})
+
 		}, //支付成功
 		applePayError: () => {}, // 苹果内购失败
 	});
@@ -155,15 +158,16 @@
 			current.value = -1;
 		}
 	})
-	function ykIoszhifu(){
+
+	function ykIoszhifu() {
 		console.log('12311');
 		const options = {
 			chanpinId: data.chanpinId,
 			taocanId: activeTaocan.value.taocanId
 		};
 		options.applePid = activeTaocan.value.applePid;
-		console.log('options',options);
-		console.log('activeTaocan.value.applePid',activeTaocan.value.applePid);
+		console.log('options', options);
+		console.log('activeTaocan.value.applePid', activeTaocan.value.applePid);
 		OrderPay('apple', options)
 	}