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/tabbar-page/myPage-tabbar/myPage-tabbar.vue |   29 +++++++++++++++++++++++++++++
 1 files changed, 29 insertions(+), 0 deletions(-)

diff --git a/pages/tabbar-page/myPage-tabbar/myPage-tabbar.vue b/pages/tabbar-page/myPage-tabbar/myPage-tabbar.vue
index 3c205a3..27fcafc 100644
--- a/pages/tabbar-page/myPage-tabbar/myPage-tabbar.vue
+++ b/pages/tabbar-page/myPage-tabbar/myPage-tabbar.vue
@@ -27,6 +27,21 @@
 		onLoad() {
 			this.init();
 		},
+		onShow() {
+			uni.$on('needRefresh', () => {
+				this.init();
+			})
+		},
+		onHide() {
+			uni.$off('needRefresh', () => {
+
+			})
+		},
+		onUnload() {
+			uni.$off('needRefresh', () => {
+
+			})
+		},
 		data() {
 			return {};
 		},
@@ -35,6 +50,20 @@
 				return uni.getStorageSync('roleType');
 			}
 		},
+		onPullDownRefresh() {
+			if (this.roleType === 3) {
+				this.$nextTick(() => {
+					this.$refs.driverMyRef.init();
+					uni.stopPullDownRefresh()
+				})
+			}
+			if (this.roleType === 1) {
+				this.$nextTick(() => {
+					this.$refs.customerMyPageRef.init();
+					uni.stopPullDownRefresh()
+				})
+			}
+		},
 		methods: {
 			init() {
 				switch (this.roleType) {

--
Gitblit v1.9.1