attachment_page.dart 832 B

123456789101112131415161718192021222324252627282930313233
  1. import 'package:flutter/material.dart';
  2. import 'package:auto_route/auto_route.dart';
  3. import 'package:hooks_riverpod/hooks_riverpod.dart';
  4. import 'package:router/ext/auto_router_extensions.dart';
  5. import '../../router/page/form_page_router.dart';
  6. @RoutePage()
  7. class AttachmentPage extends HookConsumerWidget {
  8. const AttachmentPage({Key? key}) : super(key: key);
  9. //启动当前页面
  10. static void startInstance({BuildContext? context}) {
  11. if (context != null) {
  12. context.router.push(const AttachmentPageRoute());
  13. } else {
  14. appRouter.push(const AttachmentPageRoute());
  15. }
  16. }
  17. @override
  18. Widget build(BuildContext context, WidgetRef ref) {
  19. return Scaffold(
  20. appBar: AppBar(title: Text("NoteManagementPage")),
  21. body: Center(
  22. child: Text("NoteManagementPage"),
  23. ),
  24. );
  25. }
  26. }