From 2ffa1418445f35cdf59a676e6ee0e1daa153b571 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B5=B5=E6=AF=85?= <1335909236@qq.com> Date: Tue, 12 Aug 2025 18:04:29 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=8E=A5=E5=8D=95=E6=B4=BE?= =?UTF-8?q?=E5=8D=95=E6=8C=89=E9=92=AE=E7=9A=84=E6=98=BE=E7=A4=BA=E9=80=BB?= =?UTF-8?q?=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/index/index.vue | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/pages/index/index.vue b/pages/index/index.vue index 7988d1d4..d0ce3c3b 100644 --- a/pages/index/index.vue +++ b/pages/index/index.vue @@ -231,6 +231,11 @@ import { apiArr as apiArr2 } from '../../api/v2Home.js' +import { + apiArr as apiArr3 +} from '../../api/v2User.js' + + import { apiArr as citys } from '../../api/area.js'; @@ -327,7 +332,13 @@ export default { }) }, - goToWuye() { + async goToWuye() { + uni.removeStorageSync('order_dispatch_permission'); + uni.removeStorageSync('work_order_permission'); + const res = await request(apiArr3.getUserInfo, 'POST', {}); + const { community_worker } = res; + uni.setStorageSync('order_dispatch_permission', community_worker && community_worker[0].order_dispatch_permission == 1 || false); + uni.setStorageSync('work_order_permission', community_worker && community_worker[0].work_order_permission == 1 || false); uni.navigateTo({ url: '/packages/workOrderDashboard/guide/index' }) @@ -483,7 +494,7 @@ export default { }, headerServerClick2(e) { - if(e.title == '更多'){ + if (e.title == '更多') { NavgateTo('/packages/localLife/index/index') } const cate_id = this.categoryList.find(item => item.cate_name == e.title)?.id; @@ -987,7 +998,7 @@ export default { toggleDropdown() { this.showDropdown = !this.showDropdown; - // 当展开下拉菜单时,页面向上滑动50px + // 当展开下拉菜单时,页面滑动 if (this.showDropdown) { uni.pageScrollTo({ scrollTop: 2500,