Browse Source

蛋破壳

tanxue 4 months ago
parent
commit
c035b9bb79
2 changed files with 15 additions and 16 deletions
  1. 4 1
      common/styles/global/pages.scss
  2. 11 15
      pages/pay/svip.vue

+ 4 - 1
common/styles/global/pages.scss

@@ -1324,4 +1324,7 @@
 		.not-confirm-btn{background-image: url("@/static/images/common/tip-cancel-btn.png");}
 		.not-confirm-btn{background-image: url("@/static/images/common/tip-cancel-btn.png");}
 		.confirm-btn{background-image: url("@/static/images/pay/svip-btn.png");}
 		.confirm-btn{background-image: url("@/static/images/pay/svip-btn.png");}
 	}
 	}
-}
+}
+
+// 蛋破壳
+.ezy-pay-success-dialog{width: 769rpx;height: 769rpx;@include ezy-no-repeat-cover;background-image: url("@/static/images/pay/pay-success-img.gif");}

+ 11 - 15
pages/pay/svip.vue

@@ -42,7 +42,8 @@
 			<view class="open-svip-btn" @click="creatOrder">立即开通</view>
 			<view class="open-svip-btn" @click="creatOrder">立即开通</view>
 		</view>
 		</view>
 		<CustomTabBar></CustomTabBar>
 		<CustomTabBar></CustomTabBar>
-		<tip-middle-dialog ref="daoPokeRef" @confirm-btn="daoPokeConfirm" :content="daoPokeContent"></tip-middle-dialog>
+		<!-- 蛋破壳 -->
+		<pay-success ref="daoPokeRef"></pay-success>
 	</view>
 	</view>
 </template>
 </template>
 
 
@@ -55,7 +56,7 @@
 	} from "@/api/order.js"
 	} from "@/api/order.js"
 	import CustomTabBar from '@/components/custom-tabbar/custom-tabbar.vue';
 	import CustomTabBar from '@/components/custom-tabbar/custom-tabbar.vue';
 	import cacheManager from "@/utils/cacheManager.js";
 	import cacheManager from "@/utils/cacheManager.js";
-	import tipMiddleDialog from '@/components/dialog/tipMiddleDialog.vue';
+	import paySuccess from './paySuccess.vue';
 	import {
 	import {
 		onLoad,
 		onLoad,
 		onReady
 		onReady
@@ -66,7 +67,6 @@
 	} from "@/utils/common";
 	} from "@/utils/common";
 	let payType = ref('weixin')
 	let payType = ref('weixin')
 	let cardId = ref('')
 	let cardId = ref('')
-	const daoPokeContent = '蛋破壳了!';
 	const daoPokeRef = ref(null);
 	const daoPokeRef = ref(null);
 	const svipArr = [{
 	const svipArr = [{
 			iconPath: 'static/images/pay/svip-list-icon1.png',
 			iconPath: 'static/images/pay/svip-list-icon1.png',
@@ -93,30 +93,26 @@
 		cardId.value = options.cardId
 		cardId.value = options.cardId
 	})
 	})
 
 
-	function daoPokeConfirm() {
-		daoPokeRef.value.handleClose();
-	}
-
 	function radioChange(data) {
 	function radioChange(data) {
 		payType.value = data.detail.value;
 		payType.value = data.detail.value;
 	}
 	}
 
 
 	function creatOrder(data) {
 	function creatOrder(data) {
+		
+		
+		
 		let req = {
 		let req = {
 			cardId: cardId.value
 			cardId: cardId.value
 		}
 		}
 		orderAdd(req).then(res => {
 		orderAdd(req).then(res => {
-			console.log('res');
 			cacheManager.updateVipStatus('auth', cardId.value)
 			cacheManager.updateVipStatus('auth', cardId.value)
-			toast('开通成功!')
 			daoPokeRef.value.handleShow();
 			daoPokeRef.value.handleShow();
 			setTimeout(() => {
 			setTimeout(() => {
-				daoPokeConfirm()
-			},2000)
-			return
-			uni.redirectTo({
-				url: '/pages/study/index'
-			})
+				daoPokeRef.value.handleClose();
+				uni.redirectTo({
+					url: '/pages/study/index'
+				})
+			},3000)
 		})
 		})
 	}
 	}