Commit 111fbdf6493b5d5db92b73b98c274c9f0d9f3365

Authored by yvan.ni
1 parent 103e51a8

防止多次打开支付

Showing 1 changed file with 5 additions and 1 deletions
pages/user/plus/plus.js
@@ -42,6 +42,9 @@ Page({ @@ -42,6 +42,9 @@ Page({
42 focus:false, 42 focus:false,
43 is_select: false, //是否选择营业员过 43 is_select: false, //是否选择营业员过
44 is_buy_card_id:"",//是否是链接直接过来购买的卡号id 44 is_buy_card_id:"",//是否是链接直接过来购买的卡号id
  45 +
  46 + is_fir_open:0 //防止多次打开
  47 +
45 }, 48 },
46 swiperChange: function (e) { 49 swiperChange: function (e) {
47 var currentId = e.detail.current; 50 var currentId = e.detail.current;
@@ -280,7 +283,7 @@ Page({ @@ -280,7 +283,7 @@ Page({
280 is_plusCard: parr, 283 is_plusCard: parr,
281 is_show: 1 284 is_show: 1
282 }) 285 })
283 - if(th.data.is_buy_card_id){ 286 + if(th.data.is_buy_card_id && !th.data.is_fir_open){
284 let i = parr.findIndex(item=>item.CardId==th.data.is_buy_card_id) 287 let i = parr.findIndex(item=>item.CardId==th.data.is_buy_card_id)
285 if(i>-1){ 288 if(i>-1){
286 // th.setData({ 289 // th.setData({
@@ -294,6 +297,7 @@ Page({ @@ -294,6 +297,7 @@ Page({
294 } 297 }
295 298
296 setTimeout(function (){ 299 setTimeout(function (){
  300 + th.data.is_fir_open=1; //保证不多次打开
297 th.Opening(e) 301 th.Opening(e)
298 },1000) 302 },1000)
299 303