首页的权限交接的弹窗(关闭了释放权限)+添加日志过滤功能,支持通过 shouldLog参数控制日志输出

This commit is contained in:
2026-04-29 14:25:46 +08:00
parent c3c9db5447
commit 19add5ad51
8 changed files with 124 additions and 32 deletions

View File

@@ -8,6 +8,7 @@ import 'package:maibu_satabot_v2/features/home/presentation/pages/productDesc.da
import '../../../../core/di/injection.dart';
import '../../../../core/router/route_paths.dart';
import '../../../devices/presentation/bloc/device_status_bloc.dart';
import '../../presentation/bloc/permission_request_bloc.dart';
import '../../../remote_control/presentation/bloc/remote_control_cubit.dart';
import '../../../remote_control/presentation/pages/remote_control_page.dart';
import '../pages/route_plan_page.dart';
@@ -41,6 +42,12 @@ class HomeRoutes {
/// 2. 首页 Tab 分支(带导航栏)
/// 仅保留真正的首页入口
static StatefulShellBranch get branch => StatefulShellBranch(
routes: [GoRoute(path: RoutePaths.home, builder: (context, state) => const HomePage())],
routes: [GoRoute(
path: RoutePaths.home,
builder: (context, state) => BlocProvider.value(
value: sl<PermissionRequestBloc>(), // 使用全局单例,持久监听 0x12
child: const HomePage(),
),
)],
);
}