From d5183035f767ad966a263d4dc62b7939a18227b0 Mon Sep 17 00:00:00 2001 From: andy <1042025947@qq.com> Date: Wed, 23 Jul 2025 09:44:10 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=B9=E7=89=88=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/minePages/account/index.vue | 6 +++--- src/minePages/payment/index.vue | 4 ++-- src/pages/home/index.vue | 9 +++++---- src/pages/mine/index.vue | 8 ++++---- src/utils/service.ts | 6 +++--- 5 files changed, 17 insertions(+), 16 deletions(-) diff --git a/src/minePages/account/index.vue b/src/minePages/account/index.vue index e649eda..6f54466 100644 --- a/src/minePages/account/index.vue +++ b/src/minePages/account/index.vue @@ -37,7 +37,7 @@ +{{n.tradeTotalAmount/100}} - {{n.tradeTotalAmount/100}} + -{{n.tradeTotalAmount/100}} -{{n.tradeTotalAmount/100}} @@ -236,8 +236,8 @@ function getInfor() { getaccou(uni.getStorageSync('wxuid')).then((rps:any) => { - if(rps.data.records){ - totalAmount.value = rps.data.records[0].totalAmount + if(rps.data){ + totalAmount.value = rps.data.totalAmount uni.setStorageSync('totalAmount',totalAmount.value) } }) diff --git a/src/minePages/payment/index.vue b/src/minePages/payment/index.vue index 73c5cf6..563755f 100644 --- a/src/minePages/payment/index.vue +++ b/src/minePages/payment/index.vue @@ -62,8 +62,8 @@ orderNo.value = opt.orderNo getaccou(uni.getStorageSync('wxuid')).then((rps:any) => { - if(rps.data.records){ - totalAmount.value = rps.data.records[0].totalAmount + if(rps.data){ + totalAmount.value = rps.data.totalAmount iskt.value = true if(opt.amount*1 > totalAmount.value*1){ iskzf.value = false diff --git a/src/pages/home/index.vue b/src/pages/home/index.vue index cef357f..5648a96 100644 --- a/src/pages/home/index.vue +++ b/src/pages/home/index.vue @@ -284,6 +284,7 @@ function getinfo(){ //获取换电站 covers.value.splice(0) gethdz({ + longitudeAndLatitude: latitude.value+","+longitude.value //plateNum:formdata.plateNum }).then((rps:any) => { @@ -337,10 +338,10 @@ function getinfo(){ //获取账户信息 getaccou(uni.getStorageSync('wxuid')).then((rps:any) => { - if(rps.data.records){ - account.value = rps.data.records[0] - uni.setStorageSync('totalAmount', rps.data.records[0].totalAmount) - uni.setStorageSync('walletCode', rps.data.records[0].code) + if(rps.data){ + account.value = rps.data + uni.setStorageSync('totalAmount', rps.data.totalAmount) + uni.setStorageSync('walletCode', rps.data.code) } }) } diff --git a/src/pages/mine/index.vue b/src/pages/mine/index.vue index 9d205e1..eceb3d0 100644 --- a/src/pages/mine/index.vue +++ b/src/pages/mine/index.vue @@ -219,10 +219,10 @@ //获取账户信息 getaccou(uni.getStorageSync('wxuid')).then((rps:any) => { - if(rps.data.records){ - totalAmount.value = rps.data.records[0].totalAmount - uni.setStorageSync('totalAmount', rps.data.records[0].totalAmount) - uni.setStorageSync('walletCode', rps.data.records[0].code) + if(rps.data){ + totalAmount.value = rps.data.totalAmount + uni.setStorageSync('totalAmount', rps.data.totalAmount) + uni.setStorageSync('walletCode', rps.data.code) } }) diff --git a/src/utils/service.ts b/src/utils/service.ts index 7c97076..7ef825f 100644 --- a/src/utils/service.ts +++ b/src/utils/service.ts @@ -193,7 +193,7 @@ export function carlist(wuid:String){ // stationCode:String // } export function payment(parameter:any){ - return request('post_json','/wechat/wechatpay/xcx/prepay',parameter) + return request('post_json','/wechat/pay/wechatpay/applet',parameter) } //获取ip @@ -208,7 +208,7 @@ export function openaccou(wuid:string){ //查询钱包账户 export function getaccou(wuid:string){ - return request('post_form','/wechat/wechat/user/wallet/list',{wuid}) + return request('post_form','/wechat/wechat/user/wallet/one',{wuid}) } //余额明细列表 @@ -224,7 +224,7 @@ export function balancedetails(parameter:Balande){ //转出余额 export function zcbalan(wuid:string,total:string|number){ - return request('post_json','/wechat/wechatpay/xcx/refundsBalance',{ + return request('post_json','/wechat/pay/wechatpay/refunds',{ wuid, total })