Commit f9763f68 by liuquan

3.1.4

U:修改认证提示
U:修改支付按钮置灰问题
parent 54956fa4
...@@ -332,7 +332,7 @@ Page({ ...@@ -332,7 +332,7 @@ Page({
if (that.data.idType == 1) { if (that.data.idType == 1) {
that.servicePay(); that.servicePay();
} else { } else {
Util.verifyIdCardAnName(that.data.name, that.data.idCard, res => { Util.verifyIdCardAnName(that.data.name, that.data.idCard, (res) => {
switch (res) { switch (res) {
case 0: case 0:
if (that.data.phoneYes) { if (that.data.phoneYes) {
...@@ -375,16 +375,10 @@ Page({ ...@@ -375,16 +375,10 @@ Page({
}) })
return; return;
case 6004: case 6004:
wx.showModal({
title: '提示',
content: '每人当天最多认证三次',
showCancel: false,
})
return;
case 6005: case 6005:
wx.showModal({ wx.showModal({
title: '提示', title: '提示',
content: '身份证和姓名不一致', content: '每人当天最多认证三次',
showCancel: false, showCancel: false,
}) })
return; return;
......
...@@ -27,7 +27,8 @@ Page({ ...@@ -27,7 +27,8 @@ Page({
value: '1' value: '1'
}, },
], ],
isInvoice:0 isInvoice:0,//是否开具发票
isBtnAsh:true,//支付按钮置灰
}, },
/** /**
* 生命周期函数--监听页面加载 * 生命周期函数--监听页面加载
...@@ -318,7 +319,7 @@ Page({ ...@@ -318,7 +319,7 @@ Page({
applyPay: Util.debouce(function () { applyPay: Util.debouce(function () {
let that = this; let that = this;
that.setData({ that.setData({
agree: false isBtnAsh: false
}) })
if (that.data.receiveAddress.id == undefined) { if (that.data.receiveAddress.id == undefined) {
wx.showToast({ wx.showToast({
...@@ -326,7 +327,7 @@ Page({ ...@@ -326,7 +327,7 @@ Page({
icon: 'none' icon: 'none'
}) })
that.setData({ that.setData({
agree: true isBtnAsh: true
}) })
return return
} }
...@@ -337,7 +338,7 @@ Page({ ...@@ -337,7 +338,7 @@ Page({
icon: 'none' icon: 'none'
}) })
that.setData({ that.setData({
agree: true isBtnAsh: true
}) })
return return
} }
...@@ -349,7 +350,7 @@ Page({ ...@@ -349,7 +350,7 @@ Page({
success(res) { success(res) {
if (res.confirm) { if (res.confirm) {
that.setData({ that.setData({
agree: true isBtnAsh: true
}) })
wx.navigateTo({ wx.navigateTo({
url: "/packageA/editPatientInfo/editPatientInfo?item=" + JSON.stringify(that.data.item) + "&btid=1", url: "/packageA/editPatientInfo/editPatientInfo?item=" + JSON.stringify(that.data.item) + "&btid=1",
...@@ -358,7 +359,7 @@ Page({ ...@@ -358,7 +359,7 @@ Page({
} }
}) })
that.setData({ that.setData({
agree: true isBtnAsh: true
}) })
return; return;
} }
...@@ -412,7 +413,7 @@ Page({ ...@@ -412,7 +413,7 @@ Page({
signType: 'MD5', signType: 'MD5',
paySign: res.data.parameter.paySign, paySign: res.data.parameter.paySign,
success(res) { success(res) {
console.log('res') console.log("success",res);
if (res.errMsg && res.errMsg == "requestPayment:ok") { if (res.errMsg && res.errMsg == "requestPayment:ok") {
console.log("requestPayment:ok") console.log("requestPayment:ok")
wx.reLaunch({ wx.reLaunch({
...@@ -429,12 +430,13 @@ Page({ ...@@ -429,12 +430,13 @@ Page({
} }
}, },
fail(res) { fail(res) {
console.log("fail",res);
wx.showToast({ wx.showToast({
title: '支付失败', title: '支付失败',
icon: 'none' icon: 'none'
}) })
that.setData({ that.setData({
agree: true isBtnAsh: true
}) })
that.data.main = true; that.data.main = true;
that.onShow(); that.onShow();
...@@ -464,7 +466,7 @@ Page({ ...@@ -464,7 +466,7 @@ Page({
content: res.msg, content: res.msg,
}) })
that.setData({ that.setData({
agree: true isBtnAsh: true
}) })
return; return;
case 5: case 5:
...@@ -476,7 +478,7 @@ Page({ ...@@ -476,7 +478,7 @@ Page({
errList: res.data errList: res.data
}) })
that.setData({ that.setData({
agree: true isBtnAsh: true
}) })
return; return;
} }
......
...@@ -143,8 +143,8 @@ ...@@ -143,8 +143,8 @@
<text class="text">¥ </text> <text class="text">¥ </text>
<text>{{list.money}}</text> <text>{{list.money}}</text>
</view> </view>
<view wx:if='{{!agree}}' class="qzf1">立即支付</view> <view wx:if='{{!agree||!isBtnAsh}}' class="qzf1">立即支付</view>
<view wx:if='{{agree}}' class="qzf" bindtap="applyPay">立即支付</view> <view wx:if='{{agree&&isBtnAsh}}' class="qzf" bindtap="applyPay">立即支付</view>
</view> </view>
</view> </view>
<!-- <view class="btn" bindtap="applyPay">微信支付</view> --> <!-- <view class="btn" bindtap="applyPay">微信支付</view> -->
......
...@@ -271,7 +271,7 @@ Page({ ...@@ -271,7 +271,7 @@ Page({
this.data.weight = e.detail.value; this.data.weight = e.detail.value;
}, },
//保存 //保存
sava: Util.debouce(function() { sava: Util.debouce(function () {
var that = this; var that = this;
if (that.data.name == "") { if (that.data.name == "") {
wx.showModal({ wx.showModal({
...@@ -481,29 +481,11 @@ Page({ ...@@ -481,29 +481,11 @@ Page({
case 6001: case 6001:
case 6002: case 6002:
case 6003: case 6003:
wx.showModal({
title: '提示',
content: '服务器异常',
showCancel: false,
})
that.setData({
sava: true
})
return;
case 6004: case 6004:
wx.showModal({
title: '提示',
content: '每人当天最多认证三次',
showCancel: false,
})
that.setData({
sava: true
})
return;
case 6005: case 6005:
wx.showModal({ wx.showModal({
title: '提示', title: '提示',
content: '身份证和姓名不一致', content: res.msg,
showCancel: false, showCancel: false,
}) })
that.setData({ that.setData({
......
...@@ -7,7 +7,7 @@ Page({ ...@@ -7,7 +7,7 @@ Page({
reportRedD: false, //报告红点展示 reportRedD: false, //报告红点展示
reportRedNum: 0, //未作报告数量 reportRedNum: 0, //未作报告数量
disabled:true,//防止重复点击 disabled:true,//防止重复点击
version:'3.1.2', version:'3.1.4',
isShow:false, isShow:false,
showClose:true, showClose:true,
}, },
......
...@@ -18,16 +18,15 @@ Page({ ...@@ -18,16 +18,15 @@ Page({
ishow: true, ishow: true,
paySuccess: false, paySuccess: false,
errshow: false, errshow: false,
items: [ items: [{
{ name: '不需要',
name: '不需要', value: '0'
value: '0' }, {
},{ name: '需要',
name: '需要', value: '1'
value: '1' }, ],
}, isInvoice: 0, //是否开具发票
], isBtnAsh: true, //支付按钮置灰
isInvoice:0
}, },
/** /**
* 生命周期函数--监听页面加载 * 生命周期函数--监听页面加载
...@@ -229,10 +228,10 @@ Page({ ...@@ -229,10 +228,10 @@ Page({
* 是否需要开具纸质发票 * 是否需要开具纸质发票
* @param {*} e * @param {*} e
*/ */
radioChange: function (e) { radioChange: function (e) {
this.setData({ this.setData({
isInvoice: e.detail.value, isInvoice: e.detail.value,
}) })
}, },
/** /**
* 拨打电话 * 拨打电话
...@@ -286,7 +285,7 @@ Page({ ...@@ -286,7 +285,7 @@ Page({
applyPay: Util.debouce(function () { applyPay: Util.debouce(function () {
let that = this; let that = this;
that.setData({ that.setData({
agree: false isBtnAsh: false
}) })
if (that.data.receiveAddress.id == undefined) { if (that.data.receiveAddress.id == undefined) {
wx.showToast({ wx.showToast({
...@@ -294,7 +293,7 @@ Page({ ...@@ -294,7 +293,7 @@ Page({
icon: 'none' icon: 'none'
}) })
that.setData({ that.setData({
agree: true isBtnAsh: true
}) })
return return
} }
...@@ -305,7 +304,7 @@ Page({ ...@@ -305,7 +304,7 @@ Page({
icon: 'none' icon: 'none'
}) })
that.setData({ that.setData({
agree: true isBtnAsh: true
}) })
return return
} }
...@@ -317,7 +316,7 @@ Page({ ...@@ -317,7 +316,7 @@ Page({
success(res) { success(res) {
if (res.confirm) { if (res.confirm) {
that.setData({ that.setData({
agree: true isBtnAsh: true
}) })
wx.navigateTo({ wx.navigateTo({
url: "/packageA/editPatientInfo/editPatientInfo?item=" + JSON.stringify(that.data.item) + "&btid=1", url: "/packageA/editPatientInfo/editPatientInfo?item=" + JSON.stringify(that.data.item) + "&btid=1",
...@@ -326,7 +325,7 @@ Page({ ...@@ -326,7 +325,7 @@ Page({
} }
}) })
that.setData({ that.setData({
agree: true isBtnAsh: true
}) })
return; return;
} }
...@@ -402,7 +401,7 @@ Page({ ...@@ -402,7 +401,7 @@ Page({
icon: 'none' icon: 'none'
}) })
that.setData({ that.setData({
agree: true isBtnAsh: true
}) })
that.data.main = true; that.data.main = true;
that.onShow(); that.onShow();
...@@ -432,7 +431,7 @@ Page({ ...@@ -432,7 +431,7 @@ Page({
content: res.msg, content: res.msg,
}) })
that.setData({ that.setData({
agree: true isBtnAsh: true
}) })
return; return;
case 5: case 5:
...@@ -444,7 +443,7 @@ Page({ ...@@ -444,7 +443,7 @@ Page({
errList: res.data errList: res.data
}) })
that.setData({ that.setData({
agree: true isBtnAsh: true
}) })
return; return;
} }
......
...@@ -139,8 +139,8 @@ ...@@ -139,8 +139,8 @@
<text class="text">¥ </text> <text class="text">¥ </text>
<text>{{list.money}}</text> <text>{{list.money}}</text>
</view> </view>
<view wx:if='{{!agree}}' class="qzf1">立即支付</view> <view wx:if='{{!agree||!isBtnAsh}}' class="qzf1">立即支付</view>
<view wx:if='{{agree}}' class="qzf" bindtap="applyPay">立即支付</view> <view wx:if='{{agree&&isBtnAsh}}' class="qzf" bindtap="applyPay">立即支付</view>
</view> </view>
</view> </view>
<!-- <view class="btn" bindtap="applyPay">微信支付</view> --> <!-- <view class="btn" bindtap="applyPay">微信支付</view> -->
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment