import 'package:auto_route/auto_route.dart';
import 'package:flutter/material.dart';
import 'package:router/ext/auto_router_extensions.dart';
import 'package:router/path/router_path.dart';

import '../../modules/form/form_page.dart';
import '../../modules/form/apply/form_apply_screen.dart';
import '../../modules/form/submit/form_submit_screen.dart';
import '../../modules/form/approve/form_approve_screen.dart';
import '../../modules/form/not_approve/form_not_approve_screen.dart';
import '../../modules/apply/attachment_page.dart';
import '../../modules/apply/form_payment_page.dart';
import '../../modules/apply/guest_vehicle_page.dart';
import '../../modules/apply/large_text_box_page.dart';
import '../../modules/apply/moving_company_page.dart';
import '../../modules/apply/moving_date_page.dart';
import '../../modules/apply/note_management_page.dart';
import '../../modules/apply/renovation_company_page.dart';
import '../../modules/apply/renovation_date_page.dart';
import '../../modules/apply/signature_page.dart';
import '../../modules/apply/type_of_application_page.dart';
import '../../modules/apply/vehicle_info_page.dart';
import '../../modules/apply/form_terms_page.dart';
import '../../modules/detail/form_detail_page.dart';
import 'package:domain/entity/form_list_entity.dart';
import 'package:domain/entity/form_content_entity.dart';
part 'form_page_router.gr.dart';

/*\
 * Form模块的路由
 */
@AutoRouterConfig(replaceInRouteName: 'Page|Screen,PageRoute')
class FormPageRouter extends _$FormPageRouter {
  @override
  List<AutoRoute> get routes => [
        CustomRoute(
          page: FormPageRoute.page,
          path: RouterPath.form,
          transitionsBuilder: applySlideTransition,
          children: [
            AutoRoute(page: FormApplyPageRoute.page, path: 'apply'),
            AutoRoute(page: FormSubmitPageRoute.page, path: 'submit'),
            AutoRoute(page: FormApprovePageRoute.page, path: 'approve'),
            AutoRoute(page: FormNotApprovePageRoute.page, path: 'not_approve'),
          ],
        ),
        CustomRoute(page: AttachmentPageRoute.page, path: RouterPath.formAttachment, transitionsBuilder: applySlideTransition),
        CustomRoute(page: FormPaymentPageRoute.page, path: RouterPath.formPayment, transitionsBuilder: applySlideTransition),
        CustomRoute(page: GuestVehiclePageRoute.page, path: RouterPath.formGuestVehicle, transitionsBuilder: applySlideTransition),
        CustomRoute(page: LargeTextBoxPageRoute.page, path: RouterPath.formLargeTextBox, transitionsBuilder: applySlideTransition),
        CustomRoute(page: MovingCompanyPageRoute.page, path: RouterPath.formMovingCompany, transitionsBuilder: applySlideTransition),
        CustomRoute(page: MovingDatePageRoute.page, path: RouterPath.formMovingDate, transitionsBuilder: applySlideTransition),
        CustomRoute(page: NoteManagementPageRoute.page, path: RouterPath.formNoteManagement, transitionsBuilder: applySlideTransition),
        CustomRoute(page: RenovationCompanyPageRoute.page, path: RouterPath.formRenovationCompany, transitionsBuilder: applySlideTransition),
        CustomRoute(page: RenovationDatePageRoute.page, path: RouterPath.formRenovationDate, transitionsBuilder: applySlideTransition),
        CustomRoute(page: SignaturePageRoute.page, path: RouterPath.formSignature, transitionsBuilder: applySlideTransition),
        CustomRoute(page: TypeOfApplicationPageRoute.page, path: RouterPath.formTypeOfApplication, transitionsBuilder: applySlideTransition),
        CustomRoute(page: VehicleInfoPageRoute.page, path: RouterPath.formVehicleInfo, transitionsBuilder: applySlideTransition),
        CustomRoute(page: FormTermsPageRoute.page, path: RouterPath.formTerms, transitionsBuilder: applySlideTransition),
        CustomRoute(page: FormDetailPageRoute.page, path: "${RouterPath.formDetail}:applyId/:type", transitionsBuilder: applySlideTransition),
      ];
}
