From 66dcc0a49022cf23198f399f274abee89d876991 Mon Sep 17 00:00:00 2001 From: yangan <yangan0921@163.com> Date: 星期四, 25 四月 2024 09:58:55 +0800 Subject: [PATCH] feat:客户注册增加字段 --- pages/customer-page/customer-my/customer-my.vue | 44 ++++++++++++++++++++++++++++++++------------ 1 files changed, 32 insertions(+), 12 deletions(-) diff --git a/pages/customer-page/customer-my/customer-my.vue b/pages/customer-page/customer-my/customer-my.vue index 7d3cf26..3fd2897 100644 --- a/pages/customer-page/customer-my/customer-my.vue +++ b/pages/customer-page/customer-my/customer-my.vue @@ -75,6 +75,12 @@ type="primary" @click="userManage" v-if="roleType == 1 && userEntity.isHostUser === '0'"></u-button></view> + <view class="logout"><u-button text="淇敼瀵嗙爜" + type="primary" + @click="modifyPwd"></u-button></view> + <!-- <view class="logout"><u-button text="閲嶇疆瀵嗙爜" + type="primary" + @click="initPwd"></u-button></view> --> <view class="logout"><u-button text="閫�鍑虹櫥褰�" type="primary" @click="logout()"></u-button></view> @@ -103,9 +109,6 @@ border="none" placeholder="璇疯緭鍏ヨ溅闃熷悕绉�"></u--input> </u-form-item> - <!-- <u-form-item label="杞︾墝" borderBottom ref="cars" labelWidth="80"> - <u--textarea maxlength="2000" v-model="addGroupForm.carNums" placeholder="璇疯緭鍏ヨ溅鐗�" height="150"></u--textarea> - </u-form-item> --> </u--form> </view> <view class="addCarButton"><u-button text="娣诲姞" @@ -138,7 +141,7 @@ <view class="slot-content"><rich-text :nodes="deleteFleetContent"></rich-text></view> </u-modal> </view> - + <!-- 閫�鍑虹櫥褰曞脊鍑烘 --> <view class="logoutModel"> <u-modal :show="logoutShow" :title="logoutTitle" @@ -159,6 +162,7 @@ }, data() { return { + userInfo: {}, huoDaiData: [], fleetData: [], // 鏂板缓杞﹂槦 @@ -185,7 +189,10 @@ logoutTitle: '鎻愮ず', logoutContent: '鏄惁纭閫�鍑�', // 鐢ㄦ埛淇℃伅瀵硅薄 - userEntity: {} + userEntity: {}, + initPwdShow: false, + modifyPwdShow: false, + passwordModified: '' }; }, computed: { @@ -193,20 +200,19 @@ return uni.getStorageSync('roleType'); } }, - onShow() { - this.init(); - }, methods: { init() { this.getAllHuoDaiByCustomerId(); this.getFleet(); - this.getUserEntity(); + this.getUserEntity() }, - // 鑾峰彇鐢ㄦ埛淇℃伅 getUserEntity() { - this.$reqGet('getUserEntity').then(res => { - this.userEntity = res.data; + uni.showLoading({ + title: '鍔犺浇涓�...' }); + this.$reqGet('getUserEntity').then(res => { + this.userInfo = res.data; + }) }, // 鑾峰彇璐т唬鍒楄〃 getAllHuoDaiByCustomerId() { @@ -360,9 +366,18 @@ }, logoutConfirm() { redirectLogin(); + this.$store.commit('changeisLogin', false) + this.$store.dispatch('websocketOnClose') }, logoutCancel() { this.logoutShow = false; + }, + modifyPwd() { + this.$store.commit('changeisLogin', false) + this.$store.dispatch('websocketOnClose') + uni.reLaunch({ + url: `/pages/login/resetPassword/resetPassword?phone=${this.userInfo.phone}&idCard=${this.userInfo.idCard}` + }) }, // 璺宠浆鐢ㄦ埛绠$悊椤甸潰 userManage() { @@ -513,5 +528,10 @@ } } } + + .modifyPwd { + width: 100%; + border: 1rpx solid rgb(220, 223, 230); + } } </style> \ No newline at end of file -- Gitblit v1.9.1