From f0bc328d52077682195d4e021103a24b4d767c2b Mon Sep 17 00:00:00 2001 From: woody Date: Tue, 22 Jul 2025 15:28:02 +0800 Subject: [PATCH] =?UTF-8?q?feat(pay):=20=E5=88=86=E4=BA=AB=E4=B8=8B?= =?UTF-8?q?=E5=8D=95=E6=B3=A8=E5=86=8C=E6=94=AF=E4=BB=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- App.vue | 7 ++++--- config/request.js | 2 +- pages/pay/hiPay.vue | 26 +++++++++++++++++++----- pages/pay/success.vue | 41 ++++++++++++++++++++++++++++++++++---- pages/shareArea/hiList.vue | 26 +++++++++--------------- 5 files changed, 72 insertions(+), 30 deletions(-) diff --git a/App.vue b/App.vue index 445bdcd..d77f260 100644 --- a/App.vue +++ b/App.vue @@ -9,13 +9,14 @@ export default { } const whiteList = [ 'pages/shareRegist/index', - // 'pages/shareRegist/success', + 'pages/shareRegist/success', 'pages/login/index', + 'pages/pay/success', // 'pages/wechatPay/bfPay/', // 'pages/wechatPay/hfPay/', 'pages/shareArea/hiList', - // 'pages/shareArea/hiOrder', - // 'pages/pay/hiPay' + 'pages/shareArea/hiOrder', + 'pages/pay/hiPay', ] if (whiteList.indexOf(options.path) !== -1) return this.$store.dispatch('GetInfo') diff --git a/config/request.js b/config/request.js index b963395..79cf63e 100644 --- a/config/request.js +++ b/config/request.js @@ -19,7 +19,7 @@ module.exports = vm => { //#ifdef DEV_SERVER console.log('DEV_SERVER') - config.baseURL = 'http://localhost:8080' + config.baseURL = 'http://t-app.beida666.com/prod-api' //#endif //#ifdef QA_SERVER diff --git a/pages/pay/hiPay.vue b/pages/pay/hiPay.vue index b694c47..67e268e 100644 --- a/pages/pay/hiPay.vue +++ b/pages/pay/hiPay.vue @@ -329,6 +329,7 @@ import { PAY_AUTH, } from '@/util/constant.js' var payStatus +let getRegisterInfoTimeoutFlag = null export default { components: { successDialog, @@ -390,6 +391,10 @@ export default { // 获取银行卡 // this.getBankList() }, + onUnload() { + clearTimeout(getRegisterInfoTimeoutFlag) + clearInterval(payStatus) + }, methods: { closewxPopup() { this.wxPopup = false @@ -421,10 +426,16 @@ export default { }, fansOrder() { api.fansOrder(this.orderCode).then(res => { - this.isLoading = false - this.isPw = false - removeToken() - this.$refs.successDialog.showSuccess(res.data) + if (res.data) { + this.isLoading = false + this.isPw = false + removeToken() + this.$refs.successDialog.showSuccess(res.data) + } else { + getRegisterInfoTimeoutFlag = setTimeout(() => { + this.fansOrder() + }, 3000) + } }) }, payPw() { @@ -701,7 +712,12 @@ export default { clearInterval(payStatus) this.wxPopup = false // this.showSucce = true - this.fansOrder() + uni.showLoading({ + title: '正在获取注册信息,请不要关闭当前页面', + }) + setTimeout(() => { + this.fansOrder() + }, 2000) } else { api.payStatus(data).then(res => { that.sucPay = res.data diff --git a/pages/pay/success.vue b/pages/pay/success.vue index a520336..ebadf80 100644 --- a/pages/pay/success.vue +++ b/pages/pay/success.vue @@ -44,13 +44,18 @@ - + + @@ -60,7 +65,7 @@ diff --git a/pages/shareArea/hiList.vue b/pages/shareArea/hiList.vue index 3904588..67bb926 100644 --- a/pages/shareArea/hiList.vue +++ b/pages/shareArea/hiList.vue @@ -7,9 +7,9 @@ 新人专享特惠 精选好物·品质优选 - + @@ -89,7 +89,7 @@ export default { }, getCode() { api.fansConvertCode(this.pkParent).then(res => { - this.placeParent = res.msg + this.placeParent = res.data uni.setStorageSync('placeParent', this.placeParent) }) }, @@ -103,6 +103,10 @@ export default { }) }, goBuy(item) { + const params = { + ...item, + pkParent: this.pkParent, + } uni.navigateTo({ url: '/pages/shareArea/hiOrder?allData=' + JSON.stringify(item), }) @@ -298,17 +302,16 @@ export default { align-items: baseline; .currency { - color: #005bac; + color: #ff6b35; font-size: 24rpx; font-weight: 600; margin-right: 4rpx; } .price { - color: #005bac; + color: #ff6b35; font-size: 36rpx; font-weight: 700; - animation: priceHighlight 2s ease-in-out infinite 1s; } } @@ -428,17 +431,6 @@ export default { } } -@keyframes priceHighlight { - 0%, - 100% { - color: #005bac; - } - 50% { - color: #0066cc; - transform: scale(1.05); - } -} - @keyframes promoBreathe { 0%, 100% {