shuishen
2025-12-17 53329147810d588bf427fbf9c4c259303062e3c6
feat:更新我的页面,2的跳转方式
1 files modified
31 ■■■■■ changed files
src/pages/user/index.vue 31 ●●●●● patch | view | raw | blame | history
src/pages/user/index.vue
@@ -28,20 +28,14 @@
          <div class="messagebox">个人信息</div>
          <div class="editInfo" @click="handelEdit(1)">
            点击编辑
            <image
              :src="rightImage"
              alt=""
            />
            <image :src="rightImage" alt="" />
          </div>
        </div>
        <div class="passwordBox">
          <div class="messagebox">修改密码</div>
          <div class="editInfo" @click="handelEdit(2)">
            点击编辑
            <image
              :src="rightImage"
              alt=""
            />
            <image :src="rightImage" alt="" />
          </div>
        </div>
      </view>
@@ -50,10 +44,7 @@
        <div class="goOutStyle" @click="logOut">退出登录</div>
      </view>
      <div class="bottomLogo">
        <image
          :src="logoImage"
          alt=""
        />
        <image :src="logoImage" alt="" />
      </div>
    </view>
  </view>
@@ -101,17 +92,15 @@
    });
  }
};
// 登录鉴权,微信小程序端点击tabbar的底层逻辑不触发uni.switchTab,需要在页面onShow生命周期中校验权限
onShow(async () => {
  getDeviceRegion();
onShow(() => {
  getUserInfoData();
  uni.setStorageSync("lastTab", "user");
  uni.setTabBarItem({
    index: 2, // Tab 的索引(从0开始)
    visible: false,
  });
  uni.setTabBarItem({
    index: 3, // Tab
    visible: true,
    index: 2,
    text: "",
    iconPath: "static/images/tabbar/drone.png",
    selectedIconPath: "static/images/tabbar/drone.png",
  });
});
</script>