services_page_router.dart 5.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136
  1. import 'package:auto_route/auto_route.dart';
  2. import 'package:cpt_services/modules/services/service_order_confirm/service_order_confirm_vm.dart';
  3. import 'package:flutter/material.dart';
  4. import 'package:router/ext/auto_router_extensions.dart';
  5. import 'package:router/path/router_path.dart';
  6. import '../../modules/services/repair_homeService/home_service_page.dart';
  7. import '../../modules/services/services_main_page.dart';
  8. import '../../modules/services/homeService/home_service_page.dart';
  9. import '../../modules/services/inProgress/in_progress_page.dart';
  10. import '../../modules/services/history/history_page.dart';
  11. import '../../modules/services/service_clean_detail/service_clean_detail_page.dart';
  12. import '../../modules/services/service_evaluate_create/service_evaluate_create_page.dart';
  13. import '../../modules/services/service_evaluate_create_success/evaluate_create_success_page.dart';
  14. import '../../modules/services/service_evaluate_list/service_evaluate_list_page.dart';
  15. import '../../modules/services/service_order_confirm/service_order_confirm_page.dart';
  16. import '../../modules/services/service_pay_success/service_pay_success_page.dart';
  17. import '../../modules/services/service_repair_detail/service_repair_detail_page.dart';
  18. import '../../modules/services/services_page.dart';
  19. import '../../modules/services/clean_order_detail/clean_order_detail_page.dart';
  20. import '../../modules/services/clean_order_cancel_success/clean_order_cancel_success_page.dart';
  21. import '../../modules/services/repair/repair_page.dart';
  22. import '../../modules/services/repair_history/history_page.dart';
  23. import '../../modules/services/repair_homeService/home_service_page.dart';
  24. import '../../modules/services/repair_inProgress/in_progress_page.dart';
  25. part 'services_page_router.gr.dart';
  26. /*\
  27. * services模块的路由
  28. */
  29. @AutoRouterConfig(replaceInRouteName: 'Page|Screen,PageRoute')
  30. class ServicesPageRouter extends _$ServicesPageRouter {
  31. @override
  32. List<AutoRoute> get routes => [
  33. CustomRoute(
  34. page: ServicesMainPageRoute.page,
  35. path: RouterPath.servicesMain,
  36. transitionsBuilder: applySlideTransition,
  37. ),
  38. CustomRoute(
  39. page: RepairPageRoute.page,
  40. path: RouterPath.repairServices,
  41. transitionsBuilder: applySlideTransition,
  42. children: [
  43. CustomRoute(
  44. page: RepairHomeServicePageRoute.page,
  45. path: RouterPath.repairServicesHomeService,
  46. transitionsBuilder: applySlideTransition
  47. ),
  48. CustomRoute(
  49. page: RepairInProgressPageRoute.page,
  50. path: RouterPath.repairServicesInProgress,
  51. transitionsBuilder: applySlideTransition,
  52. ),
  53. CustomRoute(
  54. page: RepairHistoryPageRoute.page,
  55. path: RouterPath.repairServicesHistory,
  56. transitionsBuilder: applySlideTransition,
  57. ),
  58. ]
  59. ),
  60. CustomRoute(
  61. page: ServicesPageRoute.page,
  62. path: RouterPath.services,
  63. transitionsBuilder: applySlideTransition,
  64. children: [
  65. CustomRoute(
  66. page: HomeServicePageRoute.page,
  67. path: RouterPath.servicesHomeService,
  68. transitionsBuilder: applySlideTransition
  69. ),
  70. CustomRoute(
  71. page: InProgressPageRoute.page,
  72. path: RouterPath.servicesInProgress,
  73. transitionsBuilder: applySlideTransition,
  74. ),
  75. CustomRoute(
  76. page: HistoryPageRoute.page,
  77. path: RouterPath.servicesHistory,
  78. transitionsBuilder: applySlideTransition,
  79. ),
  80. ]
  81. ),
  82. CustomRoute(
  83. page: ServiceCleanDetailPageRoute.page,
  84. path: "${RouterPath.servicesCleanDetail}:id/:serviceTypeCode",
  85. transitionsBuilder: applySlideTransition,
  86. ),
  87. CustomRoute(
  88. page: ServiceRepairDetailPageRoute.page,
  89. path: "${RouterPath.servicesRepairDetail}:id/:serviceTypeCode",
  90. transitionsBuilder: applySlideTransition,
  91. ),
  92. CustomRoute(
  93. page: ServiceOrderConfirmPageRoute.page,
  94. path: "${RouterPath.servicesOrderConfirm}:id/:serviceTypeCode",
  95. transitionsBuilder: applySlideTransition,
  96. ),
  97. CustomRoute(
  98. page: CleanOrderDetailPageRoute.page,
  99. path: "${RouterPath.servicesOrderDetail}:id/:serviceTypeCode/:serviceStatusCode",
  100. transitionsBuilder: applySlideTransition,
  101. ),
  102. CustomRoute(
  103. page: ServicePaySuccessPageRoute.page,
  104. path: "${RouterPath.servicesOrderPaySuccess}:id/:serviceTypeCode",
  105. transitionsBuilder: applySlideTransition,
  106. ),
  107. CustomRoute(
  108. page: CleanOrderCancelSuccessPageRoute.page,
  109. path: RouterPath.servicesOrderCancelSuccess,
  110. transitionsBuilder: applySlideTransition,
  111. ),
  112. CustomRoute(
  113. page: ServiceEvaluateCreatePageRoute.page,
  114. path: "${RouterPath.servicesEvaluateCreate}:id/:serviceTypeCode",
  115. transitionsBuilder: applySlideTransition,
  116. ),
  117. CustomRoute(
  118. page: EvaluateCreateSuccessPageRoute.page,
  119. path: RouterPath.servicesEvaluateCreateSuccess,
  120. transitionsBuilder: applySlideTransition,
  121. ),
  122. CustomRoute(
  123. page: ServiceEvaluateListPageRoute.page,
  124. path: "${RouterPath.servicesEvaluateList}:id/:serviceTypeCode",
  125. transitionsBuilder: applySlideTransition,
  126. ),
  127. ];
  128. }