From 551b1ccb1ebce7a895393f139621a780c980e877 Mon Sep 17 00:00:00 2001 From: yangjie <812952667@qq.com> Date: Mon, 13 Sep 2021 15:48:16 +0800 Subject: [PATCH] =?UTF-8?q?1.=E4=BF=AE=E6=94=B9=E6=A0=B7=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages.json | 2 +- pages/goods/refuel-confirm/refuel-confirm.vue | 2 +- pages/login/updatePas/updatePas.vue | 105 ++++++++++++------ pages/order/confirmation.vue | 6 +- pages/pay/payment/payment.vue | 2 +- pages/tabBar/home/home.vue | 36 ++++-- pages/tabBar/user/user.vue | 4 +- pages/userLogin/userLogin.vue | 48 +++++--- uni.scss | 4 + 9 files changed, 138 insertions(+), 71 deletions(-) diff --git a/pages.json b/pages.json index 1217a3a..b2c8d06 100644 --- a/pages.json +++ b/pages.json @@ -497,7 +497,7 @@ "path" : "pages/user/bindingCard/bindingCard", "style" : { - "navigationBarTitleText": "绑定定卡号", + "navigationBarTitleText": "绑定卡号", "navigationBarBackgroundColor": "#0083f5", "backgroundColorTop": "#0083f5", "navigationBarTextStyle": "white", diff --git a/pages/goods/refuel-confirm/refuel-confirm.vue b/pages/goods/refuel-confirm/refuel-confirm.vue index 73a2085..dfdc36f 100644 --- a/pages/goods/refuel-confirm/refuel-confirm.vue +++ b/pages/goods/refuel-confirm/refuel-confirm.vue @@ -59,7 +59,7 @@ - 工会卡支付余额: {{tongCardPrice}}元 + 汇联通工会卡余额: {{tongCardPrice}}元 diff --git a/pages/login/updatePas/updatePas.vue b/pages/login/updatePas/updatePas.vue index d9dfeb1..3173c93 100644 --- a/pages/login/updatePas/updatePas.vue +++ b/pages/login/updatePas/updatePas.vue @@ -9,8 +9,14 @@ - + + + + + + 确 认 @@ -21,11 +27,12 @@ import { setUserPayPwd } from "../../../Utils/Api.js"; - let app =getApp(); + let app = getApp(); export default { data() { return { passwd: '', + qrpasswd: '' } }, methods: { @@ -36,49 +43,73 @@ title: '请填写密码', icon: "none" }); - return false; + return; + } + if (this.qrpasswd == '') { + uni.showToast({ + title: '请确认密码', + icon: "none" + }); + return; } - uni.showLoading({ - title: '设置中...' - }) - let datas = { - "password": this.passwd + if (this.qrpasswd != this.passwd) { + uni.showToast({ + title: '您输入的两次密码不相同', + icon: "none" + }); + return; } - setUserPayPwd(datas).then(res => { - if (res.return_code == '000000') { - uni.hideLoading(); - uni.showToast({ - title: '设置成功', - icon: "none", - duration:2000 - }); - app.globalData.userInfo = res.return_data - .object - .highUser; - uni.setStorage({ - key: "user", - data: res.return_data - .object - .highUser - }) - uni.navigateBack({ - }) - } else { - uni.hideLoading(); - uni.showToast({ - title: res.return_msg, - icon: "none" - }) + uni.showModal({ + title: '设置密码', + content: '是否确认设置密码', + success: (res) => { + if (res.confirm) { + uni.showLoading({ + title: '设置中...' + }) + let datas = { + "password": this.passwd + } + setUserPayPwd(datas).then(res => { + if (res.return_code == '000000') { + uni.hideLoading(); + uni.showToast({ + title: '设置成功', + icon: "none", + duration: 2000 + }); + app.globalData.userInfo = res.return_data + .object + .highUser; + uni.setStorage({ + key: "user", + data: res.return_data + .object + .highUser + }) + uni.navigateBack({}) + } else { + uni.hideLoading(); + uni.showToast({ + title: res.return_msg, + icon: "none" + }) + } + }) + } else if (res.cancel) { + console.log('用户点击取消'); + } } - }) + }); } } }