From 0e3add1d6e8243245e355719be82f9569ebb68e4 Mon Sep 17 00:00:00 2001 From: tanlongsheng <252620078@qq.com> Date: Fri, 25 Jul 2025 22:06:31 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E4=BC=9A=E8=AE=AE=E5=8A=A9?= =?UTF-8?q?=E6=89=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../controllers/meeting_controller.dart | 2 + .../meeting/views/meeting_home_view.dart | 12 +- lib/modules/meeting/views/meeting_view.dart | 170 +++++++++--------- 3 files changed, 95 insertions(+), 89 deletions(-) diff --git a/lib/modules/meeting/controllers/meeting_controller.dart b/lib/modules/meeting/controllers/meeting_controller.dart index 4f7b41e36..f5ead752e 100644 --- a/lib/modules/meeting/controllers/meeting_controller.dart +++ b/lib/modules/meeting/controllers/meeting_controller.dart @@ -15,6 +15,8 @@ class MeetingController extends GetxController { const MeetingMineView(), ]; + int type = 1; + RxInt pageIndex = 0.obs; RxMap user = {}.obs; diff --git a/lib/modules/meeting/views/meeting_home_view.dart b/lib/modules/meeting/views/meeting_home_view.dart index 712078790..9c4d4ee84 100644 --- a/lib/modules/meeting/views/meeting_home_view.dart +++ b/lib/modules/meeting/views/meeting_home_view.dart @@ -87,8 +87,8 @@ class _MeetingHomeViewState extends State vertical: 10.w, ), decoration: BoxDecoration( - color: isDarkMode - ? MeetingUIUtils.getTranslucentWhite(0.05) + color: isDarkMode + ? MeetingUIUtils.getTranslucentWhite(0.05) : MeetingUIUtils.getCardColor(isDarkMode), borderRadius: BorderRadius.circular(12.w), boxShadow: MeetingUIUtils.getCardShadow(isDarkMode), @@ -127,8 +127,8 @@ class _MeetingHomeViewState extends State vertical: 10.w, ), decoration: BoxDecoration( - color: isDarkMode - ? MeetingUIUtils.getTranslucentWhite(0.05) + color: isDarkMode + ? MeetingUIUtils.getTranslucentWhite(0.05) : MeetingUIUtils.getCardColor(isDarkMode), borderRadius: BorderRadius.circular(50.w), boxShadow: MeetingUIUtils.getCardShadow(isDarkMode), @@ -220,8 +220,8 @@ class _MeetingHomeViewState extends State padding: EdgeInsets.symmetric(horizontal: 15.w, vertical: 10.w), margin: EdgeInsets.symmetric(vertical: 5.w), decoration: BoxDecoration( - color: isDarkMode - ? MeetingUIUtils.getTranslucentWhite(0.05) + color: isDarkMode + ? MeetingUIUtils.getTranslucentWhite(0.05) : MeetingUIUtils.getCardColor(isDarkMode), borderRadius: BorderRadius.circular(12.w), boxShadow: MeetingUIUtils.getCardShadow(isDarkMode), diff --git a/lib/modules/meeting/views/meeting_view.dart b/lib/modules/meeting/views/meeting_view.dart index 372cf8f24..e433fc38c 100644 --- a/lib/modules/meeting/views/meeting_view.dart +++ b/lib/modules/meeting/views/meeting_view.dart @@ -30,93 +30,97 @@ class MeetingView extends GetView { child: const FiltrateDrawer(), ), drawerEnableOpenDragGesture: false, - bottomNavigationBar: Stack( - alignment: Alignment.center, - clipBehavior: Clip.none, - children: [ - Obx( - () => BottomNavigationBar( - items: const [ - BottomNavigationBarItem( - icon: Icon(Icons.folder_outlined), - activeIcon: Icon(Icons.folder), - label: '文件', - ), - BottomNavigationBarItem( - icon: SizedBox(), - label: '', - ), - BottomNavigationBarItem( - icon: Icon(Icons.person_outline), - activeIcon: Icon(Icons.person), - label: '我的', - ), - ], - backgroundColor: - isDarkMode ? const Color(0xFF1A1A1A) : Colors.white, - currentIndex: controller.pageIndex.value, - unselectedItemColor: Colors.grey, - selectedItemColor: isDarkMode ? Colors.white : Colors.blue, - unselectedFontSize: 10.sp, - selectedFontSize: 10.sp, - onTap: (int index) { - if (index == 1 || index == controller.pageIndex.value) return; - if (index == 0) { - controller.pageIndex.value = 0; - controller.pageController.jumpToPage(0); - } else { - controller.pageIndex.value = 2; - controller.pageController.jumpToPage(1); - } - }, - ), - ), - Positioned( - top: -18.w, - child: GestureDetector( - onTap: () { - Get.bottomSheet( - BackdropFilter( - filter: ImageFilter.blur(sigmaX: 10.0, sigmaY: 10.0), - child: const NavigationBarBottomSheet(), + bottomNavigationBar: controller.type == 0 + ? Stack( + alignment: Alignment.center, + clipBehavior: Clip.none, + children: [ + Obx( + () => BottomNavigationBar( + items: const [ + BottomNavigationBarItem( + icon: Icon(Icons.folder_outlined), + activeIcon: Icon(Icons.folder), + label: '文件', + ), + BottomNavigationBarItem( + icon: SizedBox(), + label: '', + ), + BottomNavigationBarItem( + icon: Icon(Icons.person_outline), + activeIcon: Icon(Icons.person), + label: '我的', + ), + ], + backgroundColor: + isDarkMode ? const Color(0xFF1A1A1A) : Colors.white, + currentIndex: controller.pageIndex.value, + unselectedItemColor: Colors.grey, + selectedItemColor: isDarkMode ? Colors.white : Colors.blue, + unselectedFontSize: 10.sp, + selectedFontSize: 10.sp, + onTap: (int index) { + if (index == 1 || index == controller.pageIndex.value) + return; + if (index == 0) { + controller.pageIndex.value = 0; + controller.pageController.jumpToPage(0); + } else { + controller.pageIndex.value = 2; + controller.pageController.jumpToPage(1); + } + }, ), - isScrollControlled: true, - ); - }, - child: Container( - width: 60.w, - height: 60.w, - padding: EdgeInsets.all(5.w), - alignment: Alignment.center, - decoration: BoxDecoration( - color: isDarkMode ? const Color(0xFF1A1A1A) : Colors.white, - borderRadius: BorderRadius.circular(60.w), - boxShadow: [ - BoxShadow( - color: Colors.black - .withValues(alpha: isDarkMode ? 0.3 : 0.1), - blurRadius: 8, - offset: const Offset(0, 2), - ), - ], ), - child: Container( - alignment: Alignment.center, - decoration: BoxDecoration( - color: MeetingUIUtils.getButtonColor(isDarkMode), - borderRadius: BorderRadius.circular(60.w), - ), - child: Icon( - Icons.add, - color: Colors.white, - size: 30.w, + Positioned( + top: -18.w, + child: GestureDetector( + onTap: () { + Get.bottomSheet( + BackdropFilter( + filter: ImageFilter.blur(sigmaX: 10.0, sigmaY: 10.0), + child: const NavigationBarBottomSheet(), + ), + isScrollControlled: true, + ); + }, + child: Container( + width: 60.w, + height: 60.w, + padding: EdgeInsets.all(5.w), + alignment: Alignment.center, + decoration: BoxDecoration( + color: + isDarkMode ? const Color(0xFF1A1A1A) : Colors.white, + borderRadius: BorderRadius.circular(60.w), + boxShadow: [ + BoxShadow( + color: Colors.black + .withValues(alpha: isDarkMode ? 0.3 : 0.1), + blurRadius: 8, + offset: const Offset(0, 2), + ), + ], + ), + child: Container( + alignment: Alignment.center, + decoration: BoxDecoration( + color: MeetingUIUtils.getButtonColor(isDarkMode), + borderRadius: BorderRadius.circular(60.w), + ), + child: Icon( + Icons.add, + color: Colors.white, + size: 30.w, + ), + ), + ), ), ), - ), - ), - ), - ], - ), + ], + ) + : null, ); } }