rewards_page_router.dart 5.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118
  1. import 'package:auto_route/auto_route.dart';
  2. import 'package:domain/entity/rewards_buy_entity.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/rewards/rewards_page.dart';
  7. import '../../modules/rewards_my/rewards_my_page.dart';
  8. import '../../modules/rewards_my/rewards_my_active/rewards_my_active_page.dart';
  9. import '../../modules/rewards_my/rewards_my_expired/rewards_my_expired_page.dart';
  10. import '../../modules/rewards_my/rewards_my_used/rewards_my_used_page.dart';
  11. import '../../modules/rewards_list/rewards_list_page.dart';
  12. import '../../modules/rewards_address/rewards_address_page.dart';
  13. import '../../modules/rewards_code/rewards_code_page.dart';
  14. import '../../modules/rewards_detail/rewards_detail_page.dart';
  15. import '../../modules/rewards_confirm/rewards_confirm_page.dart';
  16. import '../../modules/rewards_successful/rewards_successful_page.dart';
  17. import '../../modules/rewards_redeem/rewards_redeem_page.dart';
  18. import '../../modules/rewards_transaction/rewards_transaction_page.dart';
  19. import '../../modules/rewards_home/rewards_home_page.dart';
  20. import '../../modules/rewards_search/rewards_search_page.dart';
  21. import '../../modules/rewards_history/rewards_history_page.dart';
  22. import '../../modules/rewards_history/rewards_history_earned/rewards_history_earned_page.dart';
  23. import '../../modules/rewards_history/rewards_history_spent/rewards_history_spent_page.dart';
  24. part 'rewards_page_router.gr.dart';
  25. /*\
  26. * rewards 模块的路由
  27. */
  28. @AutoRouterConfig(replaceInRouteName: 'Page|Screen,PageRoute')
  29. class RewardsPageRouter extends _$RewardsPageRouter {
  30. @override
  31. List<AutoRoute> get routes => [
  32. CustomRoute(
  33. page: RewardsPageRoute.page,
  34. path: RouterPath.rewards,
  35. transitionsBuilder: applySlideTransition),
  36. CustomRoute(
  37. page: RewardsMyPageRoute.page,
  38. path: RouterPath.rewardsMy,
  39. transitionsBuilder: applySlideTransition,
  40. children: [
  41. CustomRoute(
  42. page: RewardsMyActivePageRoute.page,
  43. path: RouterPath.rewardsMyActive,
  44. transitionsBuilder: applySlideTransition),
  45. CustomRoute(
  46. page: RewardsMyExpiredPageRoute.page,
  47. path: RouterPath.rewardsMyExpired,
  48. transitionsBuilder: applySlideTransition),
  49. CustomRoute(
  50. page: RewardsMyUsedPageRoute.page,
  51. path: RouterPath.rewardsMyUsed,
  52. transitionsBuilder: applySlideTransition),
  53. ]),
  54. CustomRoute(
  55. page: RewardsHistoryPageRoute.page,
  56. path: RouterPath.rewardsHistory,
  57. transitionsBuilder: applySlideTransition,
  58. children: [
  59. CustomRoute(
  60. page: RewardsHistoryEarnedPageRoute.page,
  61. path: RouterPath.rewardsHistoryEarned,
  62. transitionsBuilder: applySlideTransition),
  63. CustomRoute(
  64. page: RewardsHistorySpentPageRoute.page,
  65. path: RouterPath.rewardsHistorySpent,
  66. transitionsBuilder: applySlideTransition),
  67. ]),
  68. CustomRoute(
  69. page: RewardsListPageRoute.page,
  70. path: RouterPath.rewardsList,
  71. transitionsBuilder: applySlideTransition),
  72. CustomRoute(
  73. page: RewardsAddressPageRoute.page,
  74. path: RouterPath.rewardsAddress,
  75. transitionsBuilder: applySlideTransition),
  76. CustomRoute(
  77. page: RewardsCodePageRoute.page,
  78. path: RouterPath.rewardsCode,
  79. transitionsBuilder: applySlideTransition),
  80. CustomRoute(
  81. page: RewardsDetailPageRoute.page,
  82. path: RouterPath.rewardsDetail,
  83. transitionsBuilder: applySlideTransition),
  84. CustomRoute(
  85. page: RewardsConfirmPageRoute.page,
  86. path: RouterPath.rewardsConfirm,
  87. transitionsBuilder: applySlideTransition),
  88. CustomRoute(
  89. page: RewardsSuccessfulPageRoute.page,
  90. path: RouterPath.rewardsSuccessful,
  91. transitionsBuilder: applySlideTransition),
  92. CustomRoute(
  93. page: RewardsRedeemPageRoute.page,
  94. path: RouterPath.rewardsRedeem,
  95. transitionsBuilder: applySlideTransition),
  96. CustomRoute(
  97. page: RewardsTransactionPageRoute.page,
  98. path: RouterPath.rewardsTransaction,
  99. transitionsBuilder: applySlideTransition),
  100. CustomRoute(
  101. page: RewardsTransactionPageRoute.page,
  102. path: RouterPath.rewardsTransaction,
  103. transitionsBuilder: applySlideTransition),
  104. CustomRoute(
  105. page: RewardsHomePageRoute.page,
  106. path: RouterPath.rewardsHome,
  107. transitionsBuilder: applySlideTransition),
  108. CustomRoute(
  109. page: RewardsSearchPageRoute.page,
  110. path: RouterPath.rewardsSearch,
  111. transitionsBuilder: applySlideTransition),
  112. ];
  113. }