Commit e66dfe1233fd3523761911a45808d09da2f4ec24

Authored by liuqimichale
1 parent 2947f4d1

动态码 动态appid

Showing 1 changed file with 9 additions and 7 deletions
src/components/dynCodePay.vue
... ... @@ -69,7 +69,7 @@ export default {
69 69 outtime: '', // 出场时间
70 70 staytime: '', // 停车时长
71 71 orderFee: '', // 需要支付的费用
72   -
  72 + urlAppid:'',
73 73 arrearageActFee: 0,
74 74 arrearageDiscFee: 0,
75 75 arrearageActFee: 0,
... ... @@ -100,10 +100,12 @@ export default {
100 100 this.webAppCode = this.getCode();
101 101 }
102 102  
  103 + this.urlAppid = this.$route.query.appId
103 104 },
104 105 methods: {
105 106 getCode() {
106   - var appID = this.$utils.myVxAppId;
  107 +
  108 + var appID = this.urlAppid;
107 109 // alert(appID)
108 110 var code = this.getUrlParam('code');
109 111 var local = window.location.href;
... ... @@ -165,8 +167,8 @@ export default {
165 167 bankabcParams.terminalSource = 7;//请求端来源 1: 任你停 2:pda 3:微信公共号 7:H5扫码 10页面支付
166 168 bankabcParams.paySrcType = this.paySrcType;//101停车支付
167 169 bankabcParams.orgId = this.$utils.myOrgId,
168   - bankabcParams.backType = 2,
169   - bankabcParams.PaymentLinkType = 1
  170 + bankabcParams.backType = 2,
  171 + bankabcParams.PaymentLinkType = 1
170 172 bankabcParams.recordArreaInfos = JSON.stringify(this.orderId);
171 173 console.log(bankabcParams)
172 174  
... ... @@ -221,7 +223,7 @@ export default {
221 223 //第一步获取openid
222 224 var codeParams = {
223 225 code: this.webAppCode,
224   - appId: this.$utils.myVxAppId
  226 + appId: this.urlAppid
225 227 };
226 228 getOpenId(codeParams).then(res => {
227 229 if (res.code == 0) {
... ... @@ -243,13 +245,13 @@ export default {
243 245 wxParams.orderId = orderIdData;
244 246 // wxParams.backType = 2,
245 247 // wxParams.orgId = this.$utils.myOrgId,
246   - wxParams.payType = 4;// 1:支付宝 2:微信 3:银联 10:H5 4微信公众号
  248 + wxParams.payType = 4;// 1:支付宝 2:微信 3:银联 10:H5 4微信公众号
247 249 wxParams.terminalSource = 7;//请求端来源 1: 任你停 2:pda 3:微信公共号 7:H5扫码 10页面支付
248 250 // wxParams.carNumber = this.carNumber;
249 251 // wxParams.paySrcType = this.paySrcType;//101停车支付
250 252 // wxParams.recordArreaInfos = JSON.stringify(orderIdData);
251 253 wxParams.openId = openIdData;
252   - wxParams.appId = this.$utils.myVxAppId;
  254 + wxParams.appId = this.urlAppid
253 255 vxPayQuery(wxParams).then(res => {
254 256 if (res.code == 0) { //
255 257 if (res.data) {
... ...