From bcf7914e7b55e72cc453b559086255a56fe53a64 Mon Sep 17 00:00:00 2001 From: yangan <yangan0921@163.com> Date: 星期一, 20 一月 2025 08:59:44 +0800 Subject: [PATCH] feat:电子提煤单下载显示 --- pages/login/resetPassword/resetPassword.vue | 36 +++++++++++++++++++++++------------- 1 files changed, 23 insertions(+), 13 deletions(-) diff --git a/pages/login/resetPassword/resetPassword.vue b/pages/login/resetPassword/resetPassword.vue index a29cf20..cf6bb6c 100644 --- a/pages/login/resetPassword/resetPassword.vue +++ b/pages/login/resetPassword/resetPassword.vue @@ -14,12 +14,12 @@ <u-input v-if='inputType==="password"' v-model="modelForm.originalPassword" border="surround" - placeholder="璇疯緭鍏ュ瘑鐮�(浠呮敮鎸佹暟瀛楀瓧姣嶄笅鍒掔嚎)" + placeholder="瀵嗙爜搴旂敱8-16浣嶆暟瀛椼�佸瓧姣嶃�佺鍙风粍鎴愩��" :type='inputType' /> <u-input v-else v-model="modelForm.originalPassword" border="surround" - placeholder="璇疯緭鍏ュ瘑鐮�(浠呮敮鎸佹暟瀛楀瓧姣嶄笅鍒掔嚎)" + placeholder="瀵嗙爜搴旂敱8-16浣嶆暟瀛椼�佸瓧姣嶃�佺鍙风粍鎴愩��" :type='inputType' /> </u-form-item> </template> @@ -30,12 +30,12 @@ <u-input v-if='inputType==="password"' v-model="modelForm.password" border="surround" - placeholder="璇疯緭鍏ュ瘑鐮�(浠呮敮鎸佹暟瀛楀瓧姣嶄笅鍒掔嚎)" + placeholder="瀵嗙爜搴旂敱8-16浣嶆暟瀛椼�佸瓧姣嶃�佺鍙风粍鎴愩��" :type='inputType' /> <u-input v-else v-model="modelForm.password" border="surround" - placeholder="璇疯緭鍏ュ瘑鐮�(浠呮敮鎸佹暟瀛楀瓧姣嶄笅鍒掔嚎)" + placeholder="瀵嗙爜搴旂敱8-16浣嶆暟瀛椼�佸瓧姣嶃�佺鍙风粍鎴愩��" :type='inputType' /> </u-form-item> <view class="intensity"> @@ -60,12 +60,12 @@ <u-input v-if='inputType==="password"' v-model="modelForm.secondPassword" border="surround" - placeholder="璇峰啀娆¤緭鍏ュ瘑鐮�(浠呮敮鎸佹暟瀛楀瓧姣嶄笅鍒掔嚎)" + placeholder="璇峰啀娆¤緭鍏ュ瘑鐮�" type='password' /> <u-input v-else v-model="modelForm.secondPassword" border="surround" - placeholder="璇峰啀娆¤緭鍏ュ瘑鐮�(浠呮敮鎸佹暟瀛楀瓧姣嶄笅鍒掔嚎)" + placeholder="璇峰啀娆¤緭鍏ュ瘑鐮�" type='text' /> </u-form-item> <u-form-item> @@ -73,7 +73,7 @@ <u-button type="primary" text="纭畾" :loading="processLoading" - @click.stop="process"></u-button> + @click="process"></u-button> </view> </u-form-item> <u-form-item prop="checkboxValue"> @@ -129,7 +129,7 @@ const regex2 = /^[A-Za-z]+$/ // 鏍¢獙绗﹀彿 const regex3 = - /^[`~!@#$%^&*()_\-+=<>?:"{}|,.\/;'\\[\]路~锛丂#锟�%鈥︹��&*锛堬級鈥斺�擻-+={}|銆娿�嬶紵锛氣�溾�濄�愩�戙�侊紱鈥�'锛屻�傘�乚+$/ + /^[`~!@#$%^&*()_\-+=<>?:"{}|,.\/;'\\[\]路~锛丂#锟�%鈥︹��&*锛堬級鈥斺�擻-+={}|銆娿�嬶紵锛氣�溾�濄�愩�戙�侊紱鈥�'锛屻�傘�乚+$/; if(regex1.test(value)) { this.level.push('low') return callback('瀵嗙爜寮哄害杩囦綆') @@ -181,7 +181,8 @@ originalPassword:'', //鍘熷瀵嗙爜 password: '', //鏂板瘑鐮� secondPassword: '', //浜屾纭瀵嗙爜 - username:'' + username:'', + userId:'' }, processLoading: false, rules: { @@ -210,6 +211,9 @@ return uni.getStorageSync('roleType') }, userId() { + if(uni.getStorageSync('userId')) { + this.modelForm.userId = uni.getStorageSync('userId') + } return uni.getStorageSync('userId') } }, @@ -217,11 +221,14 @@ if (this.roleType === 3) { this.userInfo = JSON.parse(params.userInfo) } else { - this.getUserInfo(params.phone, params.idCard) + if(params.phone && params.idCard){ + this.getUserInfo(params.phone, params.idCard) + } } if(params.userInfo) { console.log(JSON.parse(params.userInfo),'userInfo====') this.modelForm.username = JSON.parse(params.userInfo).username + this.modelForm.userId = JSON.parse(params.userInfo).userId.toString() //userId if(JSON.parse(params.userInfo).isShowPassword) { this.isShowPassword = false }else { @@ -229,6 +236,11 @@ } }else { this.isShowPassword = true + } + //鏄笉鏄痓ug + if(uni.getStorageSync('userInfo')){ + this.modelForm.username = uni.getStorageSync('userInfo').username + this.modelForm.userId = uni.getStorageSync('userInfo').userId.toString() } }, onReady() { @@ -264,9 +276,7 @@ } this.$refs.uForm.validate().then(res => { this.processLoading = true; - let params = Object.assign({},this.modelForm, {userId:this.userId.toString()}) - console.log(params,'params=====') - this.$reqAllJson('appUpdateById', params, { method: 'PUT', 'Content-type': 'application/json' }).then(res => { + this.$reqAllJson('appUpdateById', this.modelForm, { method: 'PUT', 'Content-type': 'application/json' }).then(res => { this.processLoading = false; if (res.code === 0) { this.$u.toast('淇敼鎴愬姛,鍗冲皢鍥炲埌棣栭〉') -- Gitblit v1.9.1