From 154213e8530a53cb64bfc8452e176a63d6a3b4f6 Mon Sep 17 00:00:00 2001 From: chenbiao Date: Mon, 1 Apr 2019 10:52:53 +0800 Subject: [PATCH] add 兑换券 --- js/billCodePay.js | 8 ++++++-- js/dynCodePay.js | 4 +++- js/pay.js | 10 +++++++--- 3 files changed, 16 insertions(+), 6 deletions(-) diff --git a/js/billCodePay.js b/js/billCodePay.js index cc9d897..48ec713 100644 --- a/js/billCodePay.js +++ b/js/billCodePay.js @@ -168,7 +168,9 @@ var webAppClass = { flag = 1 webAppClass.okPay(tmpObj);//唤醒支付 }else{ - $discountBtn.disabled = false + $btnLoad.style.display = "none"; + $btnObj.style.display = "block"; + $discountBtn.disabled = false; document.getElementById("discountTip").innerHTML = res.message } }) @@ -212,7 +214,9 @@ var webAppClass = { document.getElementById("discountBox").setAttribute('readonly','readonly'); flag = 1 }else{ - $discountBtn.disabled = false + $btnLoad.style.display = "none"; + $btnObj.style.display = "block"; + $discountBtn.disabled = false; document.getElementById("discountTip").innerHTML = res.message } }) diff --git a/js/dynCodePay.js b/js/dynCodePay.js index ab4613f..945eecd 100644 --- a/js/dynCodePay.js +++ b/js/dynCodePay.js @@ -83,7 +83,9 @@ var webAppClass = { document.getElementById("discountBox").setAttribute('readonly','readonly'); // flag = 1 }else{ - $discountBtn.disabled = false + $btnLoad.style.display = "none"; + $btnObj.style.display = "block"; + $discountBtn.disabled = false; document.getElementById("discountTip").innerHTML = res.message } }) diff --git a/js/pay.js b/js/pay.js index 62bd0cd..25c9f27 100644 --- a/js/pay.js +++ b/js/pay.js @@ -79,10 +79,12 @@ var webAppClass = { document.getElementById("discountDesc").style.display="none" $btnLoad.style.display = "none"; $btnObj.style.display = "block"; - flag = 1 + flag = 1; webAppClass.okPay(tmpObj);//唤醒支付 }else{ - $discountBtn.disabled = false + $btnLoad.style.display = "none"; + $btnObj.style.display = "block"; + $discountBtn.disabled = false; document.getElementById("discountTip").innerHTML = res.message } }) @@ -126,7 +128,9 @@ var webAppClass = { document.getElementById("discountBox").setAttribute('readonly','readonly'); flag = 1 }else{ - $discountBtn.disabled = false + $btnLoad.style.display = "none"; + $btnObj.style.display = "block"; + $discountBtn.disabled = false; document.getElementById("discountTip").innerHTML = res.message } }) -- libgit2 0.21.4