From 31e386bd3cd31a683547c2346e4e06405d64c783 Mon Sep 17 00:00:00 2001 From: YeMingfei666 <1619116647@qq.com> Date: Mon, 29 Sep 2025 21:25:20 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E7=A1=AE=E8=AE=A4=E8=AE=A2?= =?UTF-8?q?=E5=8D=95=E6=98=AF=E5=90=A6=E8=BE=93=E5=85=A5=E5=AF=86=E7=A0=81?= =?UTF-8?q?=E5=88=A4=E6=96=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/order/confirm-order.vue | 39 +++++++------------------------ pages/user/member/setPassword.vue | 7 ++++++ 2 files changed, 15 insertions(+), 31 deletions(-) diff --git a/pages/order/confirm-order.vue b/pages/order/confirm-order.vue index 620b394..70ea57f 100644 --- a/pages/order/confirm-order.vue +++ b/pages/order/confirm-order.vue @@ -333,8 +333,6 @@ const storeMemberpay = Memberpay(); - - import { productStore } from '@/stores/user.js'; @@ -354,7 +352,7 @@ } from '@dcloudio/uni-app'; // 输入支付密码 const ispws = ref(false) - + const userInfo= uni.cache.get('userInfo') // 会员信息 const orderVIP = ref(uni.cache.get('orderVIP')) @@ -800,25 +798,6 @@ const goToPay = async (isCreateOrder = false) => { // 余额支付 if (paymentmethod.payType == 'accountPay') { - // if (orderVIP.value.isVip == 0) { - // uni.showModal({ - // title: '提示', - // content: '您还不是会员,是否去注册会员?', - // success: (res) => { - // if (res.confirm) { - // uni.pro.navigateTo('user/member/index', { - // shopId: orderVIP.value.shopId, - // type: 'detail' - // }) - // } else if (res.cancel) { - // console.log('用户点击取消'); - // } - // } - // }) - // return - - // } - if (orderVIP.value.payPwd == '') { uni.showModal({ title: '提示', @@ -834,16 +813,15 @@ } } }) - // } else if (orderVIP.value.amount == 0) { - // uni.showToast({ - // title: '您的余额不足', - // icon: 'none' - // }) - // } else { - } else { + return + } + console.log('userInfo.usePayPwd',userInfo.usePayPwd); + if(userInfo.usePayPwd){ ispws.value = true + return } - return false + accountPayevent() + return } const canPayRes = await search_pay_lock() @@ -959,7 +937,6 @@ const accountPayevent = async (pwd) => { ispws.value = false; - let checkOrderPay = { userId: uni.cache.get('userInfo').id, orderId: listinfo.id, diff --git a/pages/user/member/setPassword.vue b/pages/user/member/setPassword.vue index 60d7e3f..4400905 100644 --- a/pages/user/member/setPassword.vue +++ b/pages/user/member/setPassword.vue @@ -69,6 +69,7 @@ import { productStore } from '@/stores/user.js'; + import {APIuser} from '@/common/api/api.js' const storeuser = productStore(); const shopUserInfo = reactive({ shopInfo: uni.cache.get('orderVIP'), @@ -217,6 +218,12 @@ title:'修改成功' }) } + onMounted(()=>{ + APIuser().then(res=>{ + uni.cache.set('userInfo', res); + form.usePayPwd=res.usePayPwd + }) + })