routes.dart 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522
  1. import 'package:get/get.dart';
  2. import 'package:vitalapp/pages/admin/controller.dart';
  3. import 'package:vitalapp/pages/admin/view.dart';
  4. import 'package:vitalapp/pages/check/traditional_chinese_medicine_consitution_record/controller.dart';
  5. import 'package:vitalapp/pages/check/traditional_chinese_medicine_consitution_record/view.dart';
  6. import 'package:vitalapp/pages/contract/package_list/widgets/capture_portrait.dart';
  7. import 'package:vitalapp/pages/contract/package_list/widgets/family_doctor_service_package.dart';
  8. import 'package:vitalapp/pages/contract/package_list/widgets/personal_information.dart';
  9. import 'package:vitalapp/pages/contract/package_list/widgets/remark.dart';
  10. import 'package:vitalapp/pages/contract/package_list/widgets/service_information.dart';
  11. import 'package:vitalapp/pages/data_sync/center/controller.dart';
  12. import 'package:vitalapp/pages/data_sync/center/view.dart';
  13. import 'package:vitalapp/pages/data_sync/index/controller.dart';
  14. import 'package:vitalapp/pages/data_sync/index/view.dart';
  15. import 'package:vitalapp/pages/from_page/controller.dart';
  16. import 'package:vitalapp/pages/check/follow_up_record/controller.dart';
  17. import 'package:vitalapp/pages/check/follow_up_record/view.dart';
  18. import 'package:vitalapp/pages/home/personal_center/controller.dart';
  19. import 'package:vitalapp/pages/home/personal_center/view.dart';
  20. import 'package:vitalapp/pages/medical/controller.dart';
  21. import 'package:vitalapp/pages/medical/records/controller.dart';
  22. import 'package:vitalapp/pages/medical/records/view.dart';
  23. import 'package:vitalapp/pages/medical/view.dart';
  24. import 'package:vitalapp/pages/medical/views/basic_check.dart';
  25. import 'package:vitalapp/pages/medical/views/biochemistry_check.dart';
  26. import 'package:vitalapp/pages/medical/views/blood_check.dart';
  27. import 'package:vitalapp/pages/medical/views/heart_check_new.dart';
  28. import 'package:vitalapp/pages/medical/views/traditional_chinese_check.dart';
  29. import 'package:vitalapp/pages/medical/views/urine_check.dart';
  30. import 'package:vitalapp/pages/medical/widgets/health_check/health_check_list/controller.dart';
  31. import 'package:vitalapp/pages/medical/widgets/health_heart_check/health_check_list/controller.dart';
  32. import 'package:vitalapp/pages/medical_checkup_station/appointment/controller.dart';
  33. import 'package:vitalapp/pages/medical_checkup_station/appointment/view.dart';
  34. import 'package:vitalapp/pages/medical_checkup_station/registration/controller.dart';
  35. import 'package:vitalapp/pages/medical_checkup_station/registration/view/index.dart';
  36. import 'package:vitalapp/pages/patient/create/widgets/quick_create.dart';
  37. import 'package:vitalapp/pages/redirect/redirect.dart';
  38. import 'package:vitalapp/pages/settings/center/controller.dart';
  39. import 'package:vitalapp/pages/settings/center/view.dart';
  40. import 'package:vitalapp/pages/settings/devices/controller.dart';
  41. import 'package:vitalapp/pages/settings/server/controller.dart';
  42. import 'package:vitalapp/pages/traditional_chinese_medicine_constitution/controller.dart';
  43. import 'package:vitalapp/routes/route_setting.dart';
  44. import 'package:vitalapp/pages/check/examination/controller.dart';
  45. import 'package:vitalapp/pages/check/examination/view.dart';
  46. import 'package:vitalapp/pages/check/follow_up/controller.dart';
  47. import 'package:vitalapp/pages/check/follow_up/view.dart';
  48. import 'package:vitalapp/pages/check/health_check_record/controller.dart';
  49. import 'package:vitalapp/pages/check/health_check_record/view.dart';
  50. import 'package:vitalapp/pages/contract/contract_record_html/controller.dart';
  51. import 'package:vitalapp/pages/contract/contract_records/controller.dart';
  52. import 'package:vitalapp/pages/contract/contract_records/view.dart';
  53. import 'package:vitalapp/pages/contract/contract_template/controller.dart';
  54. import 'package:vitalapp/pages/contract/contract_template/view.dart';
  55. import 'package:vitalapp/pages/contract/package_info/controller.dart';
  56. import 'package:vitalapp/pages/contract/package_info/view.dart';
  57. import 'package:vitalapp/pages/contract/package_list/controller.dart';
  58. import 'package:vitalapp/pages/contract/package_list/view.dart';
  59. import 'package:vitalapp/pages/contract/signature_board/controller.dart';
  60. import 'package:vitalapp/pages/contract/signature_board/view.dart';
  61. import 'package:vitalapp/pages/controllers/crowd_labels.dart';
  62. import 'package:vitalapp/pages/dashboard/controller.dart';
  63. import 'package:vitalapp/pages/dashboard/view.dart';
  64. import 'package:vitalapp/pages/home/controller.dart';
  65. import 'package:vitalapp/pages/home/view.dart';
  66. import 'package:vitalapp/pages/login/controller.dart';
  67. import 'package:vitalapp/pages/login/view.dart';
  68. import 'package:vitalapp/pages/login_gateway/controller.dart';
  69. import 'package:vitalapp/pages/login_gateway/view.dart';
  70. import 'package:vitalapp/pages/patient/create/controller.dart';
  71. import 'package:vitalapp/pages/patient/detail/controller.dart';
  72. import 'package:vitalapp/pages/patient/detail/view.dart';
  73. import 'package:vitalapp/pages/patient/info/controller.dart';
  74. import 'package:vitalapp/pages/patient/info/view.dart';
  75. import 'package:vitalapp/pages/patient/list/controller.dart';
  76. import 'package:vitalapp/pages/patient/list/view.dart';
  77. import 'package:vitalapp/pages/splash/controller.dart';
  78. import 'package:vitalapp/pages/splash/view.dart';
  79. import '../pages/contract/contract_record_html/view.dart';
  80. class Routes {
  81. static Map<String, dynamic> parameters = {};
  82. static final routes = [
  83. VRouteSetting(
  84. '/admin',
  85. () => const AdminPage(),
  86. binding: BindingsBuilder(
  87. () {
  88. Get.put(AdminController());
  89. },
  90. ),
  91. ),
  92. VRouteSetting(
  93. '/redirect',
  94. () => const RedirectPage(),
  95. ),
  96. VRouteSetting(
  97. "/splash",
  98. () => const SplashPage(),
  99. binding: BindingsBuilder(
  100. () {
  101. Get.put(SplashController());
  102. },
  103. ),
  104. ),
  105. VRouteSetting(
  106. "/login",
  107. () => const LoginPage(),
  108. binding: BindingsBuilder(
  109. () {
  110. Get.put(LoginController());
  111. },
  112. ),
  113. ),
  114. VRouteSetting(
  115. "/login/gateway",
  116. () => const LoginGatewayPage(),
  117. binding: BindingsBuilder(
  118. () {
  119. Get.put(LoginGatewayController());
  120. },
  121. ),
  122. ),
  123. VRouteSetting(
  124. "/",
  125. () => const HomePage(),
  126. binding: BindingsBuilder(
  127. () {
  128. Get.put(HomeController());
  129. },
  130. ),
  131. ),
  132. VRouteSetting(
  133. "/dashboard",
  134. // participatesInRootNavigator: false,
  135. // preventDuplicates: true,
  136. () => const DashboardPage(),
  137. binding: BindingsBuilder(
  138. () {
  139. Get.put(DashboardController());
  140. },
  141. ),
  142. ),
  143. // VRouteSetting(
  144. // "/settings",
  145. // () => const SettingsPage(),
  146. // binding: BindingsBuilder(
  147. // () {
  148. // Get.put(SettingsController());
  149. // },
  150. // ),
  151. // ),
  152. VRouteSetting(
  153. "/settings",
  154. () => const SettingCenterPage(),
  155. binding: BindingsBuilder(
  156. () {
  157. Get.lazyPut(() => DevicesSettingController());
  158. Get.lazyPut(() => ServerSettingController());
  159. Get.put(SettingCenterController());
  160. },
  161. ),
  162. ),
  163. VRouteSetting(
  164. "/data_sync",
  165. () => const DataSyncPage(),
  166. binding: BindingsBuilder(
  167. () {
  168. Get.put(DataSyncController());
  169. },
  170. ),
  171. ),
  172. VRouteSetting(
  173. "/sync/center",
  174. () => const SyncCenterPage(),
  175. binding: BindingsBuilder(
  176. () {
  177. Get.put(SyncCenterController());
  178. },
  179. ),
  180. ),
  181. VRouteSetting(
  182. "/patient/create",
  183. // participatesInRootNavigator: false,
  184. // preventDuplicates: true,
  185. () => const QuickCreatePatientPage(),
  186. binding: BindingsBuilder(
  187. () {
  188. Get.lazyPut(() => CrowdLabelsController());
  189. if (!Get.isRegistered<CreatePatientController>()) {
  190. Get.lazyPut(() => CreatePatientController());
  191. }
  192. Get.lazyPut(() => PatientListController());
  193. Get.lazyPut(() => PatientDetailController());
  194. },
  195. ),
  196. ),
  197. VRouteSetting(
  198. "/patient/list",
  199. // participatesInRootNavigator: false,
  200. // preventDuplicates: true,
  201. () => const PatientListPage(),
  202. binding: BindingsBuilder(
  203. () {
  204. Get.lazyPut(() => CrowdLabelsController());
  205. if (!Get.isRegistered<CreatePatientController>()) {
  206. Get.lazyPut(() => CreatePatientController());
  207. }
  208. Get.lazyPut(() => PatientListController());
  209. Get.lazyPut(() => PatientDetailController());
  210. },
  211. ),
  212. ),
  213. VRouteSetting(
  214. "/patient/detail",
  215. // preventDuplicates: true,
  216. () => const PatientDetailPage(),
  217. binding: BindingsBuilder(
  218. () {
  219. Get.put(CrowdLabelsController());
  220. Get.put(PatientDetailController());
  221. },
  222. ),
  223. ),
  224. VRouteSetting(
  225. "/patient/info",
  226. () => const PatientInfoPage(),
  227. binding: BindingsBuilder(
  228. () {
  229. Get.put(PatientInfoController());
  230. },
  231. ),
  232. ),
  233. VRouteSetting(
  234. "/contract/package_list",
  235. () => const ServicePackageContractPage(),
  236. binding: BindingsBuilder(
  237. () {
  238. Get.put(CrowdLabelsController());
  239. Get.put(ServicePackageContractController());
  240. Get.put(FromPageController());
  241. },
  242. ),
  243. ),
  244. VRouteSetting(
  245. "/contract/package_info",
  246. () => const PackageInfoPage(),
  247. binding: BindingsBuilder(
  248. () {
  249. Get.put(PackageInfoController());
  250. },
  251. ),
  252. ),
  253. VRouteSetting(
  254. "/contract/signature",
  255. () => SignatureBoardPage(),
  256. binding: BindingsBuilder(
  257. () {
  258. Get.put(SignatureBoardController());
  259. },
  260. ),
  261. ),
  262. VRouteSetting(
  263. "/contract/contract_template",
  264. () => ContractTemplatePage(),
  265. binding: BindingsBuilder(
  266. () {
  267. Get.put(ContractTemplateController());
  268. },
  269. ),
  270. ),
  271. VRouteSetting(
  272. "/check/form",
  273. () => const ExaminationPage(),
  274. binding: BindingsBuilder(
  275. () {
  276. Get.put(ExaminationController());
  277. },
  278. ),
  279. ),
  280. VRouteSetting(
  281. "/check/follow_up",
  282. () => const FollowUpPage(),
  283. binding: BindingsBuilder(
  284. () {
  285. Get.put(FollowUpController());
  286. },
  287. ),
  288. ),
  289. VRouteSetting(
  290. "/check/healthCheckRecord",
  291. () => const HealthCheckRecordPage(),
  292. binding: BindingsBuilder(
  293. () {
  294. Get.put(HealthCheckRecordController());
  295. },
  296. ),
  297. ),
  298. VRouteSetting(
  299. "/contract/contract_records",
  300. () => const ContractRecordsPage(),
  301. binding: BindingsBuilder(
  302. () {
  303. Get.put(ContractRecordsController());
  304. },
  305. ),
  306. ),
  307. VRouteSetting(
  308. "/contract/contract_record_html",
  309. () => const ContractRecordsHtmlPage(),
  310. binding: BindingsBuilder(
  311. () {
  312. Get.put(ContractRecordsHtmlController());
  313. },
  314. ),
  315. ),
  316. VRouteSetting(
  317. "/contract/package_list/capture_portrait",
  318. () => const CapturePortraitPage(),
  319. binding: BindingsBuilder(
  320. () {
  321. // Get.put(CrowdLabelsController());
  322. // Get.put(ServicePackageContractController());
  323. },
  324. ),
  325. ),
  326. VRouteSetting(
  327. "/contract/package_list/family_doctor_service_package",
  328. () => const FamilyDoctorServicePackagePage(),
  329. binding: BindingsBuilder(
  330. () {
  331. // Get.put(CrowdLabelsController());
  332. // Get.put(ServicePackageContractController());
  333. },
  334. ),
  335. ),
  336. VRouteSetting(
  337. "/contract/package_list/personal_information",
  338. () => const PersonalInformationPage(),
  339. binding: BindingsBuilder(
  340. () {
  341. // Get.put(CrowdLabelsController());
  342. // Get.put(ServicePackageContractController());
  343. },
  344. ),
  345. ),
  346. VRouteSetting(
  347. "/contract/package_list/remark",
  348. () => const RemarkPage(),
  349. binding: BindingsBuilder(
  350. () {
  351. // Get.put(CrowdLabelsController());
  352. // Get.put(ServicePackageContractController());
  353. },
  354. ),
  355. ),
  356. VRouteSetting(
  357. "/contract/package_list/service_information",
  358. () => const ServiceInformationPage(),
  359. binding: BindingsBuilder(() {
  360. // Get.put(CrowdLabelsController());
  361. // Get.put(ServicePackageContractController());
  362. }),
  363. ),
  364. VRouteSetting(
  365. '/check/follow_up_record',
  366. () => const FollowUpRecordPage(),
  367. binding: BindingsBuilder(
  368. () {
  369. Get.put(FollowUpRecordController());
  370. },
  371. ),
  372. ),
  373. VRouteSetting(
  374. '/medical',
  375. () => const MedicalPage(),
  376. binding: BindingsBuilder(
  377. () {
  378. if (!Get.isRegistered<MedicalController>()) {
  379. Get.lazyPut(() => MedicalController());
  380. }
  381. Get.put(PatientDetailController());
  382. },
  383. ),
  384. ),
  385. VRouteSetting(
  386. '/home/personal_center',
  387. () => const PersonalCenterPage(),
  388. binding: BindingsBuilder(
  389. () {
  390. Get.put(PersonalCenterController());
  391. },
  392. ),
  393. ),
  394. VRouteSetting(
  395. '/TraditionalChineseMedicineConstitution',
  396. () => TraditionalChineseCheck(),
  397. binding: BindingsBuilder(
  398. () {
  399. Get.put(TraditionalChineseMedicineConstitutionController());
  400. Get.put(HealthCheckListController(checkKey: 'HEITCMC'));
  401. },
  402. ),
  403. ),
  404. VRouteSetting(
  405. '/medical/records',
  406. () => const MedicalRecordsPage(),
  407. binding: BindingsBuilder(
  408. () {
  409. Get.put(MedicalRecordsController());
  410. },
  411. ),
  412. ),
  413. VRouteSetting(
  414. '/TraditionalChineseMedicineConsitutionRecord',
  415. () => const TraditionalChineseMedicineConsitutionRecordPage(),
  416. binding: BindingsBuilder(
  417. () {
  418. Get.put(TraditionalChineseMedicineConsitutionRecordController());
  419. },
  420. ),
  421. ),
  422. VRouteSetting(
  423. '/registrationList',
  424. () => RegistrationList(),
  425. binding: BindingsBuilder(
  426. () {
  427. Get.put(RegistrationController());
  428. },
  429. ),
  430. ),
  431. VRouteSetting(
  432. '/appointment',
  433. () => const AppointmentPage(),
  434. binding: BindingsBuilder(
  435. () {
  436. Get.put(AppointmentController());
  437. },
  438. ),
  439. ),
  440. // VRouteSetting(
  441. // '/basicCheck',
  442. // () => JiChuJianCha(),
  443. // binding: BindingsBuilder(
  444. // () {
  445. // // Get.put(RegistrationListController());
  446. // if (!Get.isRegistered<MedicalController>()) {
  447. // Get.lazyPut(() => MedicalController());
  448. // }
  449. // Get.put(PatientDetailController());
  450. // Get.put(HealthCheckListController());
  451. // },
  452. // ),
  453. // ),
  454. VRouteSetting(
  455. '/electrocardiogram',
  456. () => const HeartCheckNew(),
  457. binding: BindingsBuilder(
  458. () {
  459. if (!Get.isRegistered<MedicalController>()) {
  460. Get.lazyPut(() => MedicalController());
  461. }
  462. Get.put(PatientDetailController());
  463. Get.put(HealthCheckListController());
  464. Get.put(HeartCheckListController());
  465. },
  466. ),
  467. ),
  468. VRouteSetting(
  469. '/basicCheck',
  470. () => BasicCheck(),
  471. binding: BindingsBuilder(
  472. () {
  473. Get.put(PatientDetailController());
  474. Get.put(HealthCheckListController());
  475. },
  476. ),
  477. ),
  478. VRouteSetting(
  479. '/ncg',
  480. () => const UrineAnalysisCheck(),
  481. binding: BindingsBuilder(
  482. () {
  483. if (!Get.isRegistered<MedicalController>()) {
  484. Get.lazyPut(() => MedicalController());
  485. }
  486. Get.put(PatientDetailController());
  487. Get.put(HealthCheckListController());
  488. },
  489. ),
  490. ),
  491. VRouteSetting(
  492. '/bloodTest',
  493. () => BloodCheck(),
  494. binding: BindingsBuilder(
  495. () {
  496. if (!Get.isRegistered<MedicalController>()) {
  497. Get.lazyPut(() => MedicalController());
  498. }
  499. Get.put(PatientDetailController());
  500. Get.put(HealthCheckListController());
  501. },
  502. ),
  503. ),
  504. VRouteSetting(
  505. '/biochemistryTest',
  506. () => BiochemistryCheck(),
  507. binding: BindingsBuilder(
  508. () {
  509. if (!Get.isRegistered<MedicalController>()) {
  510. Get.lazyPut(() => MedicalController());
  511. }
  512. Get.put(PatientDetailController());
  513. Get.put(HealthCheckListController());
  514. },
  515. ),
  516. ),
  517. ];
  518. }