From 416f0a02c2bf02b38111b72d72645c5baddb956d Mon Sep 17 00:00:00 2001 From: Wik-T <812952667@qq.com> Date: Wed, 11 Jan 2023 15:33:05 +0800 Subject: [PATCH] =?UTF-8?q?1.=E4=BC=98=E5=8C=962.0=E8=AF=9D=E8=B4=B9?= =?UTF-8?q?=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/pay/success/success.vue | 2 +- subPages/recharge-centre/recharge-centre.vue | 2 +- .../trade-union-recharge.vue | 94 +++++++++---------- 3 files changed, 49 insertions(+), 49 deletions(-) diff --git a/pages/pay/success/success.vue b/pages/pay/success/success.vue index 98755ea..c5c2e68 100644 --- a/pages/pay/success/success.vue +++ b/pages/pay/success/success.vue @@ -73,7 +73,7 @@ 请告知加油员用码商支付 - + diff --git a/subPages/recharge-centre/recharge-centre.vue b/subPages/recharge-centre/recharge-centre.vue index e8bb4d3..844141a 100644 --- a/subPages/recharge-centre/recharge-centre.vue +++ b/subPages/recharge-centre/recharge-centre.vue @@ -170,7 +170,7 @@ // #endif let params = { operatorType: item, - regionId: app.globalData.cityId, + "companyId": app.globalData.companyId, platformId: showType, // rechargeType: this.swiperCurrent } diff --git a/subPages/trade-union-recharge/trade-union-recharge.vue b/subPages/trade-union-recharge/trade-union-recharge.vue index b0bd326..0bbf674 100644 --- a/subPages/trade-union-recharge/trade-union-recharge.vue +++ b/subPages/trade-union-recharge/trade-union-recharge.vue @@ -68,7 +68,7 @@ import { create, wechatPay, - getHuiLianTongCardBalance, + getHuiLianTongCardBalance, getThirdPartyByDetail } from "../../Utils/Api.js"; // #ifdef H5 @@ -85,41 +85,41 @@ imgadres: 'wxpay.png', tongCardPrice: 0, cardId: '', //工会卡号 - typevas: '', + typevas: '', paytypeList: [] //支付方式 }; }, onLoad(options) { this.cardId = options.cardId; - this.typevas = options.RechargeType; + this.typevas = options.RechargeType; }, onShow() { - this.user = app.globalData.userInfo; + this.user = app.globalData.userInfo; this.getThirdPartyByDetail(); }, methods: { select(amount) { this.inputAmount = amount; - }, - //查询支付方式 - getThirdPartyByDetail() { - // #ifdef H5 - this.showType = 2; - // #endif - // #ifdef MP - this.showType = 1; - // #endif - let datas = { - platformId: this.showType, - "companyId": app.globalData.companyId, - productType: 8 - } - getThirdPartyByDetail(datas).then(res => { - if (res.return_code == '000000') { - this.paytypeList = res.return_data.productPayType.split(','); - this.paytypeList = this.paytypeList.slice(0, this.paytypeList.length - 1); - } - }); + }, + //查询支付方式 + getThirdPartyByDetail() { + // #ifdef H5 + this.showType = 2; + // #endif + // #ifdef MP + this.showType = 1; + // #endif + let datas = { + platformId: this.showType, + "companyId": app.globalData.companyId, + productType: 8 + } + getThirdPartyByDetail(datas).then(res => { + if (res.return_code == '000000') { + this.paytypeList = res.return_data.productPayType.split(','); + this.paytypeList = this.paytypeList.slice(0, this.paytypeList.length - 1); + } + }); }, doDeposit() { if (!this.cardId) { @@ -165,34 +165,34 @@ uni.showLoading({ title: '正在提交订单...' }) - let datas = { - "childOrderList": [{ - "goodsId": app.globalData.userInfo.id, - "goodsPrice": this.inputAmount, - "goodsType": 8, - "saleCount": 1, - goodsSpecName:this.cardId - }] - } - + let datas = { + "childOrderList": [{ + "goodsId": app.globalData.userInfo.id, + "goodsPrice": this.inputAmount, + "goodsType": 8, + "saleCount": 1, + goodsSpecName: this.cardId + }] + } + let that = this; create(datas).then(res => { uni.hideLoading(); if (res.return_code == '000000') { - //模板模拟支付,实际应用请调起微信/支付宝 - // #ifdef H5 - let params = { - "orderNo": res.return_data.orderNo, - "openId": app.globalData.openId, - "openIdType": 2 - } - // #endif + //模板模拟支付,实际应用请调起微信/支付宝 + // #ifdef H5 + let params = { + "orderNo": res.return_data.orderNo, + "openId": app.globalData.openId, + "openIdType": 2 + } + // #endif // #ifdef MP let params = { "orderNo": res.return_data.orderNo, - "openId": app.globalData.openId, + "openId": app.globalData.openId, "openIdType": 1 - } + } // #endif wechatPay(params).then(res => { if (res.return_code == '000000') { @@ -215,11 +215,11 @@ duration: 2000, success() { setTimeout(() => { - if (that.typevas == 'Hlt') { + if (that.typevas == + 'Hlt') { uni.navigateTo({ url: '../union-card-success/union-card-success?price=' + - that - .inputAmount + that.inputAmount }) } else { uni.navigateBack({})