|
|
|
@ -8,6 +8,7 @@ import 'package:hmg_patient_app_new/core/app_export.dart';
|
|
|
|
import 'package:hmg_patient_app_new/core/app_state.dart';
|
|
|
|
import 'package:hmg_patient_app_new/core/app_state.dart';
|
|
|
|
import 'package:hmg_patient_app_new/core/dependencies.dart';
|
|
|
|
import 'package:hmg_patient_app_new/core/dependencies.dart';
|
|
|
|
import 'package:hmg_patient_app_new/core/utils/date_util.dart';
|
|
|
|
import 'package:hmg_patient_app_new/core/utils/date_util.dart';
|
|
|
|
|
|
|
|
import 'package:hmg_patient_app_new/core/utils/size_config.dart';
|
|
|
|
import 'package:hmg_patient_app_new/core/utils/size_utils.dart';
|
|
|
|
import 'package:hmg_patient_app_new/core/utils/size_utils.dart';
|
|
|
|
import 'package:hmg_patient_app_new/core/utils/utils.dart';
|
|
|
|
import 'package:hmg_patient_app_new/core/utils/utils.dart';
|
|
|
|
import 'package:hmg_patient_app_new/extensions/string_extensions.dart';
|
|
|
|
import 'package:hmg_patient_app_new/extensions/string_extensions.dart';
|
|
|
|
@ -34,19 +35,19 @@ import 'package:hmg_patient_app_new/presentation/insurance/widgets/insurance_upd
|
|
|
|
import 'package:hmg_patient_app_new/presentation/insurance/widgets/patient_insurance_card.dart';
|
|
|
|
import 'package:hmg_patient_app_new/presentation/insurance/widgets/patient_insurance_card.dart';
|
|
|
|
import 'package:hmg_patient_app_new/presentation/lab/lab_orders_page.dart';
|
|
|
|
import 'package:hmg_patient_app_new/presentation/lab/lab_orders_page.dart';
|
|
|
|
import 'package:hmg_patient_app_new/presentation/lab/lab_result_item_view.dart';
|
|
|
|
import 'package:hmg_patient_app_new/presentation/lab/lab_result_item_view.dart';
|
|
|
|
import 'package:hmg_patient_app_new/presentation/my_family/my_family.dart';
|
|
|
|
|
|
|
|
import 'package:hmg_patient_app_new/services/dialog_service.dart';
|
|
|
|
|
|
|
|
import 'package:hmg_patient_app_new/presentation/radiology/radiology_orders_page.dart';
|
|
|
|
|
|
|
|
import 'package:hmg_patient_app_new/widgets/appbar/collapsing_list_view.dart';
|
|
|
|
|
|
|
|
import 'package:hmg_patient_app_new/presentation/medical_report/medical_reports_page.dart';
|
|
|
|
|
|
|
|
import 'package:hmg_patient_app_new/presentation/medical_file/patient_sickleaves_list_page.dart';
|
|
|
|
import 'package:hmg_patient_app_new/presentation/medical_file/patient_sickleaves_list_page.dart';
|
|
|
|
import 'package:hmg_patient_app_new/presentation/medical_file/vaccine_list_page.dart';
|
|
|
|
import 'package:hmg_patient_app_new/presentation/medical_file/vaccine_list_page.dart';
|
|
|
|
import 'package:hmg_patient_app_new/presentation/medical_file/widgets/lab_rad_card.dart';
|
|
|
|
import 'package:hmg_patient_app_new/presentation/medical_file/widgets/lab_rad_card.dart';
|
|
|
|
import 'package:hmg_patient_app_new/presentation/medical_file/widgets/medical_file_card.dart';
|
|
|
|
import 'package:hmg_patient_app_new/presentation/medical_file/widgets/medical_file_card.dart';
|
|
|
|
import 'package:hmg_patient_app_new/presentation/medical_file/widgets/patient_sick_leave_card.dart';
|
|
|
|
import 'package:hmg_patient_app_new/presentation/medical_file/widgets/patient_sick_leave_card.dart';
|
|
|
|
|
|
|
|
import 'package:hmg_patient_app_new/presentation/medical_report/medical_reports_page.dart';
|
|
|
|
|
|
|
|
import 'package:hmg_patient_app_new/presentation/my_family/my_family.dart';
|
|
|
|
import 'package:hmg_patient_app_new/presentation/prescriptions/prescriptions_list_page.dart';
|
|
|
|
import 'package:hmg_patient_app_new/presentation/prescriptions/prescriptions_list_page.dart';
|
|
|
|
|
|
|
|
import 'package:hmg_patient_app_new/presentation/radiology/radiology_orders_page.dart';
|
|
|
|
|
|
|
|
import 'package:hmg_patient_app_new/services/dialog_service.dart';
|
|
|
|
import 'package:hmg_patient_app_new/services/navigation_service.dart';
|
|
|
|
import 'package:hmg_patient_app_new/services/navigation_service.dart';
|
|
|
|
import 'package:hmg_patient_app_new/theme/colors.dart';
|
|
|
|
import 'package:hmg_patient_app_new/theme/colors.dart';
|
|
|
|
|
|
|
|
import 'package:hmg_patient_app_new/widgets/appbar/collapsing_list_view.dart';
|
|
|
|
import 'package:hmg_patient_app_new/widgets/buttons/custom_button.dart';
|
|
|
|
import 'package:hmg_patient_app_new/widgets/buttons/custom_button.dart';
|
|
|
|
import 'package:hmg_patient_app_new/widgets/chip/app_custom_chip_widget.dart';
|
|
|
|
import 'package:hmg_patient_app_new/widgets/chip/app_custom_chip_widget.dart';
|
|
|
|
import 'package:hmg_patient_app_new/widgets/common_bottom_sheet.dart';
|
|
|
|
import 'package:hmg_patient_app_new/widgets/common_bottom_sheet.dart';
|
|
|
|
@ -61,7 +62,7 @@ import '../prescriptions/prescription_detail_page.dart';
|
|
|
|
import 'widgets/medical_file_appointment_card.dart';
|
|
|
|
import 'widgets/medical_file_appointment_card.dart';
|
|
|
|
|
|
|
|
|
|
|
|
class MedicalFilePage extends StatefulWidget {
|
|
|
|
class MedicalFilePage extends StatefulWidget {
|
|
|
|
MedicalFilePage({super.key});
|
|
|
|
const MedicalFilePage({super.key});
|
|
|
|
|
|
|
|
|
|
|
|
@override
|
|
|
|
@override
|
|
|
|
State<MedicalFilePage> createState() => _MedicalFilePageState();
|
|
|
|
State<MedicalFilePage> createState() => _MedicalFilePageState();
|
|
|
|
@ -104,15 +105,35 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
title: "Medical File".needTranslation,
|
|
|
|
title: "Medical File".needTranslation,
|
|
|
|
trailing: Row(
|
|
|
|
trailing: Row(
|
|
|
|
children: [
|
|
|
|
children: [
|
|
|
|
Wrap(spacing: -15, children: [
|
|
|
|
Wrap(
|
|
|
|
Utils.buildImgWithAssets(icon: AppAssets.babyGirlImg, width: 32.h, height: 32.h, border: 1.5.h, borderRadius: 50.h),
|
|
|
|
children: [
|
|
|
|
Utils.buildImgWithAssets(icon: AppAssets.femaleImg, width: 32.h, height: 32.h, border: 1.5.h, borderRadius: 50.h),
|
|
|
|
Utils.buildImgWithAssets(
|
|
|
|
Utils.buildImgWithAssets(icon: AppAssets.male_img, width: 32.h, height: 32.h, border: 1.5.h, borderRadius: 50.h),
|
|
|
|
icon: AppAssets.babyGirlImg,
|
|
|
|
]),
|
|
|
|
height: 32.h,
|
|
|
|
|
|
|
|
border: 1.5,
|
|
|
|
|
|
|
|
fit: BoxFit.contain,
|
|
|
|
|
|
|
|
borderRadius: 50.r,
|
|
|
|
|
|
|
|
),
|
|
|
|
|
|
|
|
Utils.buildImgWithAssets(
|
|
|
|
|
|
|
|
icon: AppAssets.femaleImg,
|
|
|
|
|
|
|
|
height: 32.h,
|
|
|
|
|
|
|
|
border: 1.5,
|
|
|
|
|
|
|
|
borderRadius: 50.r,
|
|
|
|
|
|
|
|
fit: BoxFit.contain,
|
|
|
|
|
|
|
|
),
|
|
|
|
|
|
|
|
Utils.buildImgWithAssets(
|
|
|
|
|
|
|
|
icon: AppAssets.male_img,
|
|
|
|
|
|
|
|
height: 32.h,
|
|
|
|
|
|
|
|
border: 1.5,
|
|
|
|
|
|
|
|
borderRadius: 50.r,
|
|
|
|
|
|
|
|
fit: BoxFit.contain,
|
|
|
|
|
|
|
|
),
|
|
|
|
|
|
|
|
],
|
|
|
|
|
|
|
|
),
|
|
|
|
SizedBox(width: 4.h),
|
|
|
|
SizedBox(width: 4.h),
|
|
|
|
Utils.buildSvgWithAssets(icon: AppAssets.arrow_down)
|
|
|
|
Utils.buildSvgWithAssets(icon: AppAssets.arrow_down, height: 22.h, width: 22.w)
|
|
|
|
],
|
|
|
|
],
|
|
|
|
).onPress(() {
|
|
|
|
).withHorizontalPadding(24.w).onPress(() {
|
|
|
|
DialogService dialogService = getIt.get<DialogService>();
|
|
|
|
DialogService dialogService = getIt.get<DialogService>();
|
|
|
|
dialogService.showFamilyBottomSheetWithoutH(
|
|
|
|
dialogService.showFamilyBottomSheetWithoutH(
|
|
|
|
label: "Who do you want to book for?".needTranslation,
|
|
|
|
label: "Who do you want to book for?".needTranslation,
|
|
|
|
@ -140,21 +161,21 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
isAllowLeadingIcon: true,
|
|
|
|
isAllowLeadingIcon: true,
|
|
|
|
padding: EdgeInsets.symmetric(vertical: 8.h, horizontal: 8.h),
|
|
|
|
padding: EdgeInsets.symmetric(vertical: 8.h, horizontal: 8.h),
|
|
|
|
leadingIcon: AppAssets.student_card,
|
|
|
|
leadingIcon: AppAssets.student_card,
|
|
|
|
).paddingSymmetrical(24.h, 0.0),
|
|
|
|
).paddingSymmetrical(24.w, 0.0),
|
|
|
|
SizedBox(height: 16.h),
|
|
|
|
SizedBox(height: 16.h),
|
|
|
|
Container(
|
|
|
|
Container(
|
|
|
|
width: double.infinity,
|
|
|
|
width: double.infinity,
|
|
|
|
decoration: RoundedRectangleBorder().toSmoothCornerDecoration(color: AppColors.whiteColor, borderRadius: 24),
|
|
|
|
decoration: RoundedRectangleBorder().toSmoothCornerDecoration(color: AppColors.whiteColor, borderRadius: 12.r),
|
|
|
|
child: Padding(
|
|
|
|
child: Padding(
|
|
|
|
padding: EdgeInsets.all(16.h),
|
|
|
|
padding: EdgeInsets.all(16.w),
|
|
|
|
child: Column(
|
|
|
|
child: Column(
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
children: [
|
|
|
|
children: [
|
|
|
|
Row(
|
|
|
|
Row(
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
children: [
|
|
|
|
children: [
|
|
|
|
Image.asset(appState.getAuthenticatedUser()?.gender == 1 ? AppAssets.male_img : AppAssets.femaleImg, width: 56.h, height: 56.h),
|
|
|
|
Image.asset(appState.getAuthenticatedUser()?.gender == 1 ? AppAssets.male_img : AppAssets.femaleImg, width: 56.w, height: 56.h),
|
|
|
|
SizedBox(width: 8.h),
|
|
|
|
SizedBox(width: 8.w),
|
|
|
|
Column(
|
|
|
|
Column(
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
children: [
|
|
|
|
children: [
|
|
|
|
@ -163,12 +184,13 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
SizedBox(height: 4.h),
|
|
|
|
SizedBox(height: 4.h),
|
|
|
|
Wrap(
|
|
|
|
Wrap(
|
|
|
|
direction: Axis.horizontal,
|
|
|
|
direction: Axis.horizontal,
|
|
|
|
spacing: 4.h,
|
|
|
|
spacing: 4.w,
|
|
|
|
runSpacing: 4.h,
|
|
|
|
runSpacing: 6.w,
|
|
|
|
children: [
|
|
|
|
children: [
|
|
|
|
AppCustomChipWidget(
|
|
|
|
AppCustomChipWidget(
|
|
|
|
icon: AppAssets.file_icon,
|
|
|
|
icon: AppAssets.file_icon,
|
|
|
|
labelText: "${LocaleKeys.fileNo.tr(context: context)}: ${appState.getAuthenticatedUser()!.patientId}",
|
|
|
|
labelText: "${LocaleKeys.fileNo.tr(context: context)}: ${appState.getAuthenticatedUser()!.patientId}",
|
|
|
|
|
|
|
|
labelPadding: EdgeInsetsDirectional.only(end: 6.w),
|
|
|
|
onChipTap: () {
|
|
|
|
onChipTap: () {
|
|
|
|
navigationService.pushPage(
|
|
|
|
navigationService.pushPage(
|
|
|
|
page: FamilyMedicalScreen(
|
|
|
|
page: FamilyMedicalScreen(
|
|
|
|
@ -181,6 +203,7 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
icon: AppAssets.checkmark_icon,
|
|
|
|
icon: AppAssets.checkmark_icon,
|
|
|
|
labelText: LocaleKeys.verified.tr(context: context),
|
|
|
|
labelText: LocaleKeys.verified.tr(context: context),
|
|
|
|
iconColor: AppColors.successColor,
|
|
|
|
iconColor: AppColors.successColor,
|
|
|
|
|
|
|
|
labelPadding: EdgeInsetsDirectional.only(end: 6.w),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
],
|
|
|
|
],
|
|
|
|
),
|
|
|
|
),
|
|
|
|
@ -203,7 +226,7 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
icon: AppAssets.blood_icon,
|
|
|
|
icon: AppAssets.blood_icon,
|
|
|
|
labelText: "Blood: ${appState.getUserBloodGroup}",
|
|
|
|
labelText: "Blood: ${appState.getUserBloodGroup}",
|
|
|
|
iconColor: AppColors.primaryRedColor,
|
|
|
|
iconColor: AppColors.primaryRedColor,
|
|
|
|
labelPadding: EdgeInsetsDirectional.only(start: -4.h, end: 8.h),
|
|
|
|
labelPadding: EdgeInsetsDirectional.only(start: 4.w, end: 8.w),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
Consumer<InsuranceViewModel>(builder: (context, insuranceVM, child) {
|
|
|
|
Consumer<InsuranceViewModel>(builder: (context, insuranceVM, child) {
|
|
|
|
return AppCustomChipWidget(
|
|
|
|
return AppCustomChipWidget(
|
|
|
|
@ -211,9 +234,10 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
labelText: insuranceVM.isInsuranceExpired ? "Insurance Expired".needTranslation : "Insurance Active".needTranslation,
|
|
|
|
labelText: insuranceVM.isInsuranceExpired ? "Insurance Expired".needTranslation : "Insurance Active".needTranslation,
|
|
|
|
iconColor: insuranceVM.isInsuranceExpired ? AppColors.primaryRedColor : AppColors.successColor,
|
|
|
|
iconColor: insuranceVM.isInsuranceExpired ? AppColors.primaryRedColor : AppColors.successColor,
|
|
|
|
textColor: insuranceVM.isInsuranceExpired ? AppColors.primaryRedColor : AppColors.successColor,
|
|
|
|
textColor: insuranceVM.isInsuranceExpired ? AppColors.primaryRedColor : AppColors.successColor,
|
|
|
|
iconSize: 12,
|
|
|
|
iconSize: 12.w,
|
|
|
|
backgroundColor: insuranceVM.isInsuranceExpired ? AppColors.primaryRedColor.withOpacity(0.1) : AppColors.successColor.withOpacity(0.1),
|
|
|
|
backgroundColor:
|
|
|
|
labelPadding: EdgeInsetsDirectional.only(start: -4.h, end: 8.h),
|
|
|
|
insuranceVM.isInsuranceExpired ? AppColors.primaryRedColor.withOpacity(0.1) : AppColors.successColor.withOpacity(0.1),
|
|
|
|
|
|
|
|
labelPadding: EdgeInsetsDirectional.only(start: 4.w, end: 8.w),
|
|
|
|
);
|
|
|
|
);
|
|
|
|
}),
|
|
|
|
}),
|
|
|
|
],
|
|
|
|
],
|
|
|
|
@ -221,7 +245,7 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
],
|
|
|
|
],
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
).paddingSymmetrical(24.h, 0.0),
|
|
|
|
).paddingSymmetrical(24.w, 0.0),
|
|
|
|
SizedBox(height: 16.h),
|
|
|
|
SizedBox(height: 16.h),
|
|
|
|
Consumer<MedicalFileViewModel>(builder: (context, medicalFileVM, child) {
|
|
|
|
Consumer<MedicalFileViewModel>(builder: (context, medicalFileVM, child) {
|
|
|
|
return Column(
|
|
|
|
return Column(
|
|
|
|
@ -238,7 +262,7 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
onTabChange: (index) {
|
|
|
|
onTabChange: (index) {
|
|
|
|
medicalFileVM.onTabChanged(index);
|
|
|
|
medicalFileVM.onTabChanged(index);
|
|
|
|
},
|
|
|
|
},
|
|
|
|
).paddingSymmetrical(24.h, 0.0),
|
|
|
|
).paddingSymmetrical(24.w, 0.0),
|
|
|
|
SizedBox(height: 24.h),
|
|
|
|
SizedBox(height: 24.h),
|
|
|
|
getSelectedTabData(medicalFileVM.selectedTabIndex),
|
|
|
|
getSelectedTabData(medicalFileVM.selectedTabIndex),
|
|
|
|
],
|
|
|
|
],
|
|
|
|
@ -309,31 +333,16 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
],
|
|
|
|
],
|
|
|
|
),
|
|
|
|
),
|
|
|
|
],
|
|
|
|
],
|
|
|
|
).paddingSymmetrical(24.h, 0.h).onPress(() {
|
|
|
|
).paddingSymmetrical(24.w, 0.h).onPress(() {
|
|
|
|
Navigator.of(context).push(
|
|
|
|
Navigator.of(context).push(
|
|
|
|
CustomPageRoute(
|
|
|
|
CustomPageRoute(
|
|
|
|
page: MyAppointmentsPage(),
|
|
|
|
page: MyAppointmentsPage(),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
);
|
|
|
|
);
|
|
|
|
}),
|
|
|
|
}),
|
|
|
|
|
|
|
|
SizedBox(height: 16.h),
|
|
|
|
Consumer<MyAppointmentsViewModel>(builder: (context, myAppointmentsVM, child) {
|
|
|
|
Consumer<MyAppointmentsViewModel>(builder: (context, myAppointmentsVM, child) {
|
|
|
|
return SizedBox(
|
|
|
|
return SizedBox(
|
|
|
|
height: myAppointmentsVM.patientAppointmentsHistoryList.isNotEmpty ? 200.h : 175.h,
|
|
|
|
|
|
|
|
child: ListView.separated(
|
|
|
|
|
|
|
|
scrollDirection: Axis.horizontal,
|
|
|
|
|
|
|
|
padding: EdgeInsets.only(top: 16.h, left: 24.h, right: 24.h, bottom: 0.h),
|
|
|
|
|
|
|
|
shrinkWrap: true,
|
|
|
|
|
|
|
|
itemCount: myAppointmentsVM.isMyAppointmentsLoading ? 5 : (myAppointmentsVM.patientAppointmentsHistoryList.isNotEmpty ? myAppointmentsVM.patientAppointmentsHistoryList.length : 1),
|
|
|
|
|
|
|
|
itemBuilder: (context, index) {
|
|
|
|
|
|
|
|
return AnimationConfiguration.staggeredList(
|
|
|
|
|
|
|
|
position: index,
|
|
|
|
|
|
|
|
duration: const Duration(milliseconds: 500),
|
|
|
|
|
|
|
|
child: SlideAnimation(
|
|
|
|
|
|
|
|
horizontalOffset: 100.0,
|
|
|
|
|
|
|
|
child: FadeInAnimation(
|
|
|
|
|
|
|
|
child: AnimatedContainer(
|
|
|
|
|
|
|
|
duration: Duration(milliseconds: 300),
|
|
|
|
|
|
|
|
curve: Curves.easeInOut,
|
|
|
|
|
|
|
|
child: myAppointmentsVM.isMyAppointmentsLoading
|
|
|
|
child: myAppointmentsVM.isMyAppointmentsLoading
|
|
|
|
? MedicalFileAppointmentCard(
|
|
|
|
? MedicalFileAppointmentCard(
|
|
|
|
patientAppointmentHistoryResponseModel: PatientAppointmentHistoryResponseModel(),
|
|
|
|
patientAppointmentHistoryResponseModel: PatientAppointmentHistoryResponseModel(),
|
|
|
|
@ -341,20 +350,11 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
onRescheduleTap: () {},
|
|
|
|
onRescheduleTap: () {},
|
|
|
|
onAskDoctorTap: () {},
|
|
|
|
onAskDoctorTap: () {},
|
|
|
|
)
|
|
|
|
)
|
|
|
|
: myAppointmentsVM.patientAppointmentsHistoryList.isNotEmpty
|
|
|
|
: myAppointmentsVM.patientAppointmentsHistoryList.isEmpty
|
|
|
|
? MedicalFileAppointmentCard(
|
|
|
|
? Container(
|
|
|
|
patientAppointmentHistoryResponseModel: myAppointmentsVM.patientAppointmentsHistoryList[index],
|
|
|
|
padding: EdgeInsets.all(12.w),
|
|
|
|
myAppointmentsViewModel: myAppointmentsViewModel,
|
|
|
|
width: MediaQuery.of(context).size.width,
|
|
|
|
onRescheduleTap: () {
|
|
|
|
decoration: RoundedRectangleBorder().toSmoothCornerDecoration(color: AppColors.whiteColor, borderRadius: 12.r, hasShadow: true),
|
|
|
|
openDoctorScheduleCalendar(myAppointmentsVM.patientAppointmentsHistoryList[index]);
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
onAskDoctorTap: () {},
|
|
|
|
|
|
|
|
)
|
|
|
|
|
|
|
|
: Container(
|
|
|
|
|
|
|
|
width: MediaQuery.of(context).size.width - 48.h,
|
|
|
|
|
|
|
|
decoration: RoundedRectangleBorder().toSmoothCornerDecoration(color: AppColors.whiteColor, borderRadius: 24, hasShadow: true),
|
|
|
|
|
|
|
|
child: Padding(
|
|
|
|
|
|
|
|
padding: EdgeInsets.all(12.h),
|
|
|
|
|
|
|
|
child: Column(
|
|
|
|
child: Column(
|
|
|
|
children: [
|
|
|
|
children: [
|
|
|
|
Utils.buildSvgWithAssets(icon: AppAssets.home_calendar_icon, width: 32.h, height: 32.h),
|
|
|
|
Utils.buildSvgWithAssets(icon: AppAssets.home_calendar_icon, width: 32.h, height: 32.h),
|
|
|
|
@ -373,29 +373,49 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
backgroundColor: Color(0xffFEE9EA),
|
|
|
|
backgroundColor: Color(0xffFEE9EA),
|
|
|
|
borderColor: Color(0xffFEE9EA),
|
|
|
|
borderColor: Color(0xffFEE9EA),
|
|
|
|
textColor: Color(0xffED1C2B),
|
|
|
|
textColor: Color(0xffED1C2B),
|
|
|
|
fontSize: 14,
|
|
|
|
fontSize: 14.f,
|
|
|
|
fontWeight: FontWeight.w500,
|
|
|
|
fontWeight: FontWeight.w500,
|
|
|
|
borderRadius: 12,
|
|
|
|
borderRadius: 12.r,
|
|
|
|
padding: EdgeInsets.fromLTRB(10, 0, 10, 0),
|
|
|
|
padding: EdgeInsets.fromLTRB(10.w, 0, 10.w, 0),
|
|
|
|
height: 40,
|
|
|
|
height: 40.h,
|
|
|
|
icon: AppAssets.add_icon,
|
|
|
|
icon: AppAssets.add_icon,
|
|
|
|
iconColor: AppColors.primaryRedColor,
|
|
|
|
iconColor: AppColors.primaryRedColor,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
],
|
|
|
|
],
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
)
|
|
|
|
),
|
|
|
|
: ListView.separated(
|
|
|
|
),
|
|
|
|
scrollDirection: Axis.horizontal,
|
|
|
|
|
|
|
|
shrinkWrap: true,
|
|
|
|
|
|
|
|
itemCount: myAppointmentsVM.patientAppointmentsHistoryList.length,
|
|
|
|
|
|
|
|
itemBuilder: (context, index) {
|
|
|
|
|
|
|
|
return AnimationConfiguration.staggeredList(
|
|
|
|
|
|
|
|
position: index,
|
|
|
|
|
|
|
|
duration: const Duration(milliseconds: 500),
|
|
|
|
|
|
|
|
child: SlideAnimation(
|
|
|
|
|
|
|
|
horizontalOffset: 100.0,
|
|
|
|
|
|
|
|
child: FadeInAnimation(
|
|
|
|
|
|
|
|
child: AnimatedContainer(
|
|
|
|
|
|
|
|
duration: Duration(milliseconds: 300),
|
|
|
|
|
|
|
|
curve: Curves.easeInOut,
|
|
|
|
|
|
|
|
child: MedicalFileAppointmentCard(
|
|
|
|
|
|
|
|
patientAppointmentHistoryResponseModel: myAppointmentsVM.patientAppointmentsHistoryList[index],
|
|
|
|
|
|
|
|
myAppointmentsViewModel: myAppointmentsViewModel,
|
|
|
|
|
|
|
|
onRescheduleTap: () {
|
|
|
|
|
|
|
|
openDoctorScheduleCalendar(myAppointmentsVM.patientAppointmentsHistoryList[index]);
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
onAskDoctorTap: () {},
|
|
|
|
|
|
|
|
)),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
);
|
|
|
|
);
|
|
|
|
},
|
|
|
|
},
|
|
|
|
separatorBuilder: (BuildContext cxt, int index) => SizedBox(width: 12.h),
|
|
|
|
separatorBuilder: (BuildContext cxt, int index) => SizedBox(width: 12.h),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
);
|
|
|
|
).paddingSymmetrical(24.w, 0);
|
|
|
|
}),
|
|
|
|
}),
|
|
|
|
SizedBox(height: 24.h),
|
|
|
|
SizedBox(height: 24.h),
|
|
|
|
"Lab & Radiology".needTranslation.toText18(isBold: true).paddingSymmetrical(24.h, 0.h),
|
|
|
|
"Lab & Radiology".needTranslation.toText18(isBold: true).paddingSymmetrical(24.w, 0.h),
|
|
|
|
SizedBox(height: 16.h),
|
|
|
|
SizedBox(height: 16.h),
|
|
|
|
Row(
|
|
|
|
Row(
|
|
|
|
children: [
|
|
|
|
children: [
|
|
|
|
@ -431,27 +451,27 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
}),
|
|
|
|
}),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
],
|
|
|
|
],
|
|
|
|
).paddingSymmetrical(24.h, 0.h),
|
|
|
|
).paddingSymmetrical(24.w, 0.h),
|
|
|
|
SizedBox(height: 24.h),
|
|
|
|
SizedBox(height: 24.h),
|
|
|
|
"Active Medications & Prescriptions".needTranslation.toText18(isBold: true).paddingSymmetrical(24.h, 0.h),
|
|
|
|
"Active Medications & Prescriptions".needTranslation.toText18(isBold: true).paddingSymmetrical(24.w, 0.h),
|
|
|
|
SizedBox(height: 16.h),
|
|
|
|
SizedBox(height: 16.h),
|
|
|
|
Consumer<PrescriptionsViewModel>(builder: (context, prescriptionVM, child) {
|
|
|
|
Consumer<PrescriptionsViewModel>(builder: (context, prescriptionVM, child) {
|
|
|
|
return prescriptionVM.isPrescriptionsOrdersLoading
|
|
|
|
return prescriptionVM.isPrescriptionsOrdersLoading
|
|
|
|
? const MoviesShimmerWidget().paddingSymmetrical(24.h, 0.h)
|
|
|
|
? const MoviesShimmerWidget().paddingSymmetrical(24.w, 0.h)
|
|
|
|
: prescriptionVM.patientPrescriptionOrders.isNotEmpty
|
|
|
|
: prescriptionVM.patientPrescriptionOrders.isNotEmpty
|
|
|
|
? Container(
|
|
|
|
? Container(
|
|
|
|
decoration: RoundedRectangleBorder().toSmoothCornerDecoration(
|
|
|
|
decoration: RoundedRectangleBorder().toSmoothCornerDecoration(
|
|
|
|
color: Colors.white,
|
|
|
|
color: Colors.white,
|
|
|
|
borderRadius: 20.h,
|
|
|
|
borderRadius: 12.r,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
child: Padding(
|
|
|
|
child: Padding(
|
|
|
|
padding: EdgeInsets.all(16.h),
|
|
|
|
padding: EdgeInsets.all(16.w),
|
|
|
|
child: Column(
|
|
|
|
child: Column(
|
|
|
|
children: [
|
|
|
|
children: [
|
|
|
|
ListView.separated(
|
|
|
|
ListView.separated(
|
|
|
|
itemCount: prescriptionVM.patientPrescriptionOrders.length,
|
|
|
|
itemCount: prescriptionVM.patientPrescriptionOrders.length,
|
|
|
|
shrinkWrap: true,
|
|
|
|
shrinkWrap: true,
|
|
|
|
padding: const EdgeInsets.only(left: 0, right: 8),
|
|
|
|
padding: EdgeInsets.only(left: 0, right: 8.w),
|
|
|
|
physics: NeverScrollableScrollPhysics(),
|
|
|
|
physics: NeverScrollableScrollPhysics(),
|
|
|
|
itemBuilder: (context, index) {
|
|
|
|
itemBuilder: (context, index) {
|
|
|
|
return AnimationConfiguration.staggeredList(
|
|
|
|
return AnimationConfiguration.staggeredList(
|
|
|
|
@ -464,11 +484,11 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
children: [
|
|
|
|
children: [
|
|
|
|
Image.network(
|
|
|
|
Image.network(
|
|
|
|
prescriptionVM.patientPrescriptionOrders[index].doctorImageURL!,
|
|
|
|
prescriptionVM.patientPrescriptionOrders[index].doctorImageURL!,
|
|
|
|
width: 40.h,
|
|
|
|
width: 40.w,
|
|
|
|
height: 40.h,
|
|
|
|
height: 40.h,
|
|
|
|
fit: BoxFit.cover,
|
|
|
|
fit: BoxFit.cover,
|
|
|
|
).circle(100),
|
|
|
|
).circle(100.r),
|
|
|
|
SizedBox(width: 16.h),
|
|
|
|
SizedBox(width: 16.w),
|
|
|
|
Expanded(
|
|
|
|
Expanded(
|
|
|
|
child: Column(
|
|
|
|
child: Column(
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
@ -477,13 +497,16 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
SizedBox(height: 4.h),
|
|
|
|
SizedBox(height: 4.h),
|
|
|
|
Wrap(
|
|
|
|
Wrap(
|
|
|
|
direction: Axis.horizontal,
|
|
|
|
direction: Axis.horizontal,
|
|
|
|
spacing: 3.h,
|
|
|
|
spacing: 3.w,
|
|
|
|
runSpacing: 4.h,
|
|
|
|
runSpacing: 4.w,
|
|
|
|
children: [
|
|
|
|
children: [
|
|
|
|
AppCustomChipWidget(labelText: prescriptionVM.patientPrescriptionOrders[index].clinicDescription!),
|
|
|
|
AppCustomChipWidget(labelText: prescriptionVM.patientPrescriptionOrders[index].clinicDescription!),
|
|
|
|
AppCustomChipWidget(
|
|
|
|
AppCustomChipWidget(
|
|
|
|
icon: AppAssets.doctor_calendar_icon,
|
|
|
|
icon: AppAssets.doctor_calendar_icon,
|
|
|
|
labelText: DateUtil.formatDateToDate(DateUtil.convertStringToDate(prescriptionVM.patientPrescriptionOrders[index].appointmentDate), false),
|
|
|
|
labelText: DateUtil.formatDateToDate(
|
|
|
|
|
|
|
|
DateUtil.convertStringToDate(prescriptionVM.patientPrescriptionOrders[index].appointmentDate),
|
|
|
|
|
|
|
|
false,
|
|
|
|
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
],
|
|
|
|
],
|
|
|
|
),
|
|
|
|
),
|
|
|
|
@ -494,7 +517,11 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
Transform.flip(
|
|
|
|
Transform.flip(
|
|
|
|
flipX: appState.isArabic(),
|
|
|
|
flipX: appState.isArabic(),
|
|
|
|
child: Utils.buildSvgWithAssets(
|
|
|
|
child: Utils.buildSvgWithAssets(
|
|
|
|
icon: AppAssets.forward_arrow_icon_small, width: 15.h, height: 15.h, fit: BoxFit.contain, iconColor: AppColors.textColor)),
|
|
|
|
icon: AppAssets.forward_arrow_icon_small,
|
|
|
|
|
|
|
|
width: 15.w,
|
|
|
|
|
|
|
|
height: 15.h,
|
|
|
|
|
|
|
|
fit: BoxFit.contain,
|
|
|
|
|
|
|
|
iconColor: AppColors.textColor)),
|
|
|
|
],
|
|
|
|
],
|
|
|
|
).onPress(() {
|
|
|
|
).onPress(() {
|
|
|
|
prescriptionVM.setPrescriptionsDetailsLoading();
|
|
|
|
prescriptionVM.setPrescriptionsDetailsLoading();
|
|
|
|
@ -510,9 +537,9 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
},
|
|
|
|
},
|
|
|
|
separatorBuilder: (BuildContext cxt, int index) => SizedBox(height: 16.h),
|
|
|
|
separatorBuilder: (BuildContext cxt, int index) => SizedBox(height: 16.h),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
SizedBox(height: 16.h),
|
|
|
|
SizedBox(height: 24.h),
|
|
|
|
const Divider(color: AppColors.dividerColor),
|
|
|
|
const Divider(color: AppColors.dividerColor),
|
|
|
|
SizedBox(height: 16.h),
|
|
|
|
SizedBox(height: 24.h),
|
|
|
|
Row(
|
|
|
|
Row(
|
|
|
|
children: [
|
|
|
|
children: [
|
|
|
|
Expanded(
|
|
|
|
Expanded(
|
|
|
|
@ -528,16 +555,16 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
backgroundColor: AppColors.secondaryLightRedColor,
|
|
|
|
backgroundColor: AppColors.secondaryLightRedColor,
|
|
|
|
borderColor: AppColors.secondaryLightRedColor,
|
|
|
|
borderColor: AppColors.secondaryLightRedColor,
|
|
|
|
textColor: AppColors.primaryRedColor,
|
|
|
|
textColor: AppColors.primaryRedColor,
|
|
|
|
fontSize: 12,
|
|
|
|
fontSize: 12.f,
|
|
|
|
fontWeight: FontWeight.w500,
|
|
|
|
fontWeight: FontWeight.w500,
|
|
|
|
borderRadius: 12.h,
|
|
|
|
borderRadius: 12.r,
|
|
|
|
height: 40.h,
|
|
|
|
height: 56.h,
|
|
|
|
icon: AppAssets.requests,
|
|
|
|
icon: AppAssets.requests,
|
|
|
|
iconColor: AppColors.primaryRedColor,
|
|
|
|
iconColor: AppColors.primaryRedColor,
|
|
|
|
iconSize: 16.h,
|
|
|
|
iconSize: 16.w,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
SizedBox(width: 10.h),
|
|
|
|
SizedBox(width: 10.w),
|
|
|
|
Expanded(
|
|
|
|
Expanded(
|
|
|
|
child: CustomButton(
|
|
|
|
child: CustomButton(
|
|
|
|
text: "All Medications".needTranslation,
|
|
|
|
text: "All Medications".needTranslation,
|
|
|
|
@ -545,10 +572,10 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
backgroundColor: AppColors.secondaryLightRedColor,
|
|
|
|
backgroundColor: AppColors.secondaryLightRedColor,
|
|
|
|
borderColor: AppColors.secondaryLightRedColor,
|
|
|
|
borderColor: AppColors.secondaryLightRedColor,
|
|
|
|
textColor: AppColors.primaryRedColor,
|
|
|
|
textColor: AppColors.primaryRedColor,
|
|
|
|
fontSize: 12,
|
|
|
|
fontSize: 12.f,
|
|
|
|
fontWeight: FontWeight.w500,
|
|
|
|
fontWeight: FontWeight.w500,
|
|
|
|
borderRadius: 12.h,
|
|
|
|
borderRadius: 12.h,
|
|
|
|
height: 40.h,
|
|
|
|
height: 56.h,
|
|
|
|
icon: AppAssets.all_medications_icon,
|
|
|
|
icon: AppAssets.all_medications_icon,
|
|
|
|
iconColor: AppColors.primaryRedColor,
|
|
|
|
iconColor: AppColors.primaryRedColor,
|
|
|
|
iconSize: 16.h,
|
|
|
|
iconSize: 16.h,
|
|
|
|
@ -559,15 +586,21 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
],
|
|
|
|
],
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
).paddingSymmetrical(24.h, 0.h)
|
|
|
|
).paddingSymmetrical(24.w, 0.h)
|
|
|
|
: Container(
|
|
|
|
: Container(
|
|
|
|
decoration: RoundedRectangleBorder().toSmoothCornerDecoration(
|
|
|
|
decoration: RoundedRectangleBorder().toSmoothCornerDecoration(
|
|
|
|
color: AppColors.whiteColor,
|
|
|
|
color: AppColors.whiteColor,
|
|
|
|
borderRadius: 20.h,
|
|
|
|
borderRadius: 12.r,
|
|
|
|
hasShadow: false,
|
|
|
|
hasShadow: false,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
child: Utils.getNoDataWidget(context, noDataText: "You don't have any prescriptions yet.".needTranslation, isSmallWidget: true, width: 62, height: 62))
|
|
|
|
child: Utils.getNoDataWidget(
|
|
|
|
.paddingSymmetrical(24.h, 0.h);
|
|
|
|
context,
|
|
|
|
|
|
|
|
noDataText: "You don't have any prescriptions yet.".needTranslation,
|
|
|
|
|
|
|
|
isSmallWidget: true,
|
|
|
|
|
|
|
|
width: 62.w,
|
|
|
|
|
|
|
|
height: 62.h,
|
|
|
|
|
|
|
|
),
|
|
|
|
|
|
|
|
).paddingSymmetrical(24.w, 0.h);
|
|
|
|
}),
|
|
|
|
}),
|
|
|
|
SizedBox(height: 24.h),
|
|
|
|
SizedBox(height: 24.h),
|
|
|
|
//My Doctor Section
|
|
|
|
//My Doctor Section
|
|
|
|
@ -578,7 +611,7 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
Row(
|
|
|
|
Row(
|
|
|
|
children: [
|
|
|
|
children: [
|
|
|
|
LocaleKeys.viewAll.tr().toText12(color: AppColors.primaryRedColor, fontWeight: FontWeight.w500),
|
|
|
|
LocaleKeys.viewAll.tr().toText12(color: AppColors.primaryRedColor, fontWeight: FontWeight.w500),
|
|
|
|
SizedBox(width: 2.h),
|
|
|
|
SizedBox(width: 2.w),
|
|
|
|
Icon(Icons.arrow_forward_ios, color: AppColors.primaryRedColor, size: 10.h),
|
|
|
|
Icon(Icons.arrow_forward_ios, color: AppColors.primaryRedColor, size: 10.h),
|
|
|
|
],
|
|
|
|
],
|
|
|
|
).onPress(() {
|
|
|
|
).onPress(() {
|
|
|
|
@ -590,58 +623,63 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
);
|
|
|
|
);
|
|
|
|
}),
|
|
|
|
}),
|
|
|
|
],
|
|
|
|
],
|
|
|
|
).paddingSymmetrical(24.h, 0.h),
|
|
|
|
).paddingSymmetrical(24.w, 0.h),
|
|
|
|
SizedBox(height: 16.h),
|
|
|
|
SizedBox(height: 16.h),
|
|
|
|
Consumer<MyAppointmentsViewModel>(builder: (context, myAppointmentsVM, child) {
|
|
|
|
Consumer<MyAppointmentsViewModel>(builder: (context, myAppointmentsVM, child) {
|
|
|
|
return SizedBox(
|
|
|
|
|
|
|
|
height: 120.h,
|
|
|
|
|
|
|
|
child: ListView.separated(
|
|
|
|
|
|
|
|
scrollDirection: Axis.horizontal,
|
|
|
|
|
|
|
|
itemCount: myAppointmentsVM.isPatientMyDoctorsLoading
|
|
|
|
|
|
|
|
? 5
|
|
|
|
|
|
|
|
: myAppointmentsVM.patientMyDoctorsList.isNotEmpty
|
|
|
|
|
|
|
|
? myAppointmentsVM.patientMyDoctorsList.length
|
|
|
|
|
|
|
|
: 1,
|
|
|
|
|
|
|
|
shrinkWrap: true,
|
|
|
|
|
|
|
|
padding: EdgeInsets.only(left: 24.h, right: 24.h),
|
|
|
|
|
|
|
|
itemBuilder: (context, index) {
|
|
|
|
|
|
|
|
return myAppointmentsVM.isPatientMyDoctorsLoading
|
|
|
|
return myAppointmentsVM.isPatientMyDoctorsLoading
|
|
|
|
? SizedBox(
|
|
|
|
? Column(
|
|
|
|
width: 80.h,
|
|
|
|
|
|
|
|
child: Column(
|
|
|
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.center,
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.center,
|
|
|
|
children: [
|
|
|
|
children: [
|
|
|
|
Image.network(
|
|
|
|
Image.network(
|
|
|
|
"https://hmgwebservices.com/Images/MobileImages/DUBAI/unkown_female.png",
|
|
|
|
"https://hmgwebservices.com/Images/MobileImages/DUBAI/unkown_female.png",
|
|
|
|
width: 64.h,
|
|
|
|
width: 64.w,
|
|
|
|
height: 64.h,
|
|
|
|
height: 64.h,
|
|
|
|
fit: BoxFit.cover,
|
|
|
|
fit: BoxFit.cover,
|
|
|
|
).circle(100).toShimmer2(isShow: true, radius: 50.h),
|
|
|
|
).circle(100).toShimmer2(isShow: true, radius: 50.r),
|
|
|
|
SizedBox(height: 8.h),
|
|
|
|
SizedBox(height: 8.h),
|
|
|
|
Expanded(
|
|
|
|
("Dr. John Smith Smith Smith").toString().toText12(fontWeight: FontWeight.w500, isCenter: true, maxLine: 2).toShimmer2(isShow: true),
|
|
|
|
child: ("Dr. John Smith Smith Smith").toString().toText12(fontWeight: FontWeight.w500, isCenter: true, maxLine: 2).toShimmer2(isShow: true),
|
|
|
|
|
|
|
|
),
|
|
|
|
|
|
|
|
],
|
|
|
|
],
|
|
|
|
),
|
|
|
|
|
|
|
|
)
|
|
|
|
)
|
|
|
|
: myAppointmentsVM.patientMyDoctorsList.isNotEmpty
|
|
|
|
: myAppointmentsVM.patientMyDoctorsList.isEmpty
|
|
|
|
? AnimationConfiguration.staggeredList(
|
|
|
|
? Container(
|
|
|
|
|
|
|
|
width: SizeConfig.screenWidth,
|
|
|
|
|
|
|
|
decoration: RoundedRectangleBorder().toSmoothCornerDecoration(
|
|
|
|
|
|
|
|
color: AppColors.whiteColor,
|
|
|
|
|
|
|
|
borderRadius: 12.r,
|
|
|
|
|
|
|
|
hasShadow: false,
|
|
|
|
|
|
|
|
),
|
|
|
|
|
|
|
|
child: Utils.getNoDataWidget(
|
|
|
|
|
|
|
|
context,
|
|
|
|
|
|
|
|
noDataText: "You don't have any completed visits yet".needTranslation,
|
|
|
|
|
|
|
|
isSmallWidget: true,
|
|
|
|
|
|
|
|
width: 62.w,
|
|
|
|
|
|
|
|
height: 62.h,
|
|
|
|
|
|
|
|
),
|
|
|
|
|
|
|
|
).paddingSymmetrical(24.w, 0.h)
|
|
|
|
|
|
|
|
: SizedBox(
|
|
|
|
|
|
|
|
height: 200.h,
|
|
|
|
|
|
|
|
child: ListView.separated(
|
|
|
|
|
|
|
|
scrollDirection: Axis.horizontal,
|
|
|
|
|
|
|
|
itemCount: myAppointmentsVM.patientMyDoctorsList.length,
|
|
|
|
|
|
|
|
shrinkWrap: true,
|
|
|
|
|
|
|
|
itemBuilder: (context, index) {
|
|
|
|
|
|
|
|
return AnimationConfiguration.staggeredList(
|
|
|
|
position: index,
|
|
|
|
position: index,
|
|
|
|
duration: const Duration(milliseconds: 1000),
|
|
|
|
duration: const Duration(milliseconds: 1000),
|
|
|
|
child: SlideAnimation(
|
|
|
|
child: SlideAnimation(
|
|
|
|
horizontalOffset: 100.0,
|
|
|
|
horizontalOffset: 100.0,
|
|
|
|
child: FadeInAnimation(
|
|
|
|
child: FadeInAnimation(
|
|
|
|
child: SizedBox(
|
|
|
|
child: SizedBox(
|
|
|
|
width: 80.h,
|
|
|
|
// width: 80.w,
|
|
|
|
child: Column(
|
|
|
|
child: Column(
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.center,
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.center,
|
|
|
|
children: [
|
|
|
|
children: [
|
|
|
|
Image.network(
|
|
|
|
Image.network(
|
|
|
|
myAppointmentsVM.patientMyDoctorsList[index].doctorImageURL!,
|
|
|
|
myAppointmentsVM.patientMyDoctorsList[index].doctorImageURL!,
|
|
|
|
width: 64.h,
|
|
|
|
width: 64.w,
|
|
|
|
height: 64.h,
|
|
|
|
height: 64.h,
|
|
|
|
fit: BoxFit.cover,
|
|
|
|
fit: BoxFit.cover,
|
|
|
|
).circle(100).toShimmer2(isShow: false, radius: 50.h),
|
|
|
|
).circle(100).toShimmer2(isShow: false, radius: 50.r),
|
|
|
|
SizedBox(height: 8.h),
|
|
|
|
SizedBox(height: 8.h),
|
|
|
|
Expanded(
|
|
|
|
Expanded(
|
|
|
|
child: (myAppointmentsVM.patientMyDoctorsList[index].doctorName)
|
|
|
|
child: (myAppointmentsVM.patientMyDoctorsList[index].doctorName)
|
|
|
|
@ -678,29 +716,21 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
}),
|
|
|
|
}),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
)
|
|
|
|
);
|
|
|
|
: Container(
|
|
|
|
|
|
|
|
decoration: RoundedRectangleBorder().toSmoothCornerDecoration(
|
|
|
|
|
|
|
|
color: AppColors.whiteColor,
|
|
|
|
|
|
|
|
borderRadius: 20.h,
|
|
|
|
|
|
|
|
hasShadow: false,
|
|
|
|
|
|
|
|
),
|
|
|
|
|
|
|
|
child: Utils.getNoDataWidget(context, noDataText: "You don't have any completed visits yet.".needTranslation, isSmallWidget: true, width: 62, height: 62),
|
|
|
|
|
|
|
|
).paddingSymmetrical(24.h, 0.h);
|
|
|
|
|
|
|
|
},
|
|
|
|
},
|
|
|
|
separatorBuilder: (BuildContext cxt, int index) => SizedBox(width: 8.h),
|
|
|
|
separatorBuilder: (BuildContext cxt, int index) => SizedBox(width: 8.h),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
);
|
|
|
|
);
|
|
|
|
}),
|
|
|
|
}),
|
|
|
|
SizedBox(height: 24.h),
|
|
|
|
SizedBox(height: 24.h),
|
|
|
|
"Others".needTranslation.toText18(isBold: true).paddingSymmetrical(24.h, 0.h),
|
|
|
|
"Others".needTranslation.toText18(isBold: true).paddingSymmetrical(24.w, 0.h),
|
|
|
|
SizedBox(height: 16.h),
|
|
|
|
SizedBox(height: 16.h),
|
|
|
|
GridView(
|
|
|
|
GridView(
|
|
|
|
gridDelegate: SliverGridDelegateWithFixedCrossAxisCount(
|
|
|
|
gridDelegate: SliverGridDelegateWithFixedCrossAxisCount(
|
|
|
|
crossAxisCount: 3,
|
|
|
|
crossAxisCount: 3,
|
|
|
|
crossAxisSpacing: 16,
|
|
|
|
crossAxisSpacing: 16.h,
|
|
|
|
mainAxisSpacing: 16,
|
|
|
|
mainAxisSpacing: 16.w,
|
|
|
|
mainAxisExtent: 130,
|
|
|
|
mainAxisExtent: 130.h,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
physics: NeverScrollableScrollPhysics(),
|
|
|
|
physics: NeverScrollableScrollPhysics(),
|
|
|
|
padding: EdgeInsets.zero,
|
|
|
|
padding: EdgeInsets.zero,
|
|
|
|
@ -712,7 +742,7 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
backgroundColor: AppColors.whiteColor,
|
|
|
|
backgroundColor: AppColors.whiteColor,
|
|
|
|
svgIcon: AppAssets.eye_result_icon,
|
|
|
|
svgIcon: AppAssets.eye_result_icon,
|
|
|
|
isLargeText: true,
|
|
|
|
isLargeText: true,
|
|
|
|
iconSize: 36.h,
|
|
|
|
iconSize: 36.w,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
MedicalFileCard(
|
|
|
|
MedicalFileCard(
|
|
|
|
label: "Allergy Info".needTranslation,
|
|
|
|
label: "Allergy Info".needTranslation,
|
|
|
|
@ -720,7 +750,7 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
backgroundColor: AppColors.whiteColor,
|
|
|
|
backgroundColor: AppColors.whiteColor,
|
|
|
|
svgIcon: AppAssets.allergy_info_icon,
|
|
|
|
svgIcon: AppAssets.allergy_info_icon,
|
|
|
|
isLargeText: true,
|
|
|
|
isLargeText: true,
|
|
|
|
iconSize: 36.h,
|
|
|
|
iconSize: 36.w,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
MedicalFileCard(
|
|
|
|
MedicalFileCard(
|
|
|
|
label: "Vaccine Info".needTranslation,
|
|
|
|
label: "Vaccine Info".needTranslation,
|
|
|
|
@ -728,7 +758,7 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
backgroundColor: AppColors.whiteColor,
|
|
|
|
backgroundColor: AppColors.whiteColor,
|
|
|
|
svgIcon: AppAssets.vaccine_info_icon,
|
|
|
|
svgIcon: AppAssets.vaccine_info_icon,
|
|
|
|
isLargeText: true,
|
|
|
|
isLargeText: true,
|
|
|
|
iconSize: 36.h,
|
|
|
|
iconSize: 36.w,
|
|
|
|
).onPress(() {
|
|
|
|
).onPress(() {
|
|
|
|
Navigator.of(context).push(
|
|
|
|
Navigator.of(context).push(
|
|
|
|
CustomPageRoute(
|
|
|
|
CustomPageRoute(
|
|
|
|
@ -737,7 +767,7 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
);
|
|
|
|
);
|
|
|
|
}),
|
|
|
|
}),
|
|
|
|
],
|
|
|
|
],
|
|
|
|
).paddingSymmetrical(24.h, 0.0),
|
|
|
|
).paddingSymmetrical(24.w, 0.0),
|
|
|
|
SizedBox(height: 24.h),
|
|
|
|
SizedBox(height: 24.h),
|
|
|
|
],
|
|
|
|
],
|
|
|
|
);
|
|
|
|
);
|
|
|
|
@ -752,7 +782,7 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
labOrder: null,
|
|
|
|
labOrder: null,
|
|
|
|
index: index,
|
|
|
|
index: index,
|
|
|
|
isLoading: true,
|
|
|
|
isLoading: true,
|
|
|
|
).paddingSymmetrical(24.h, 0.0)
|
|
|
|
).paddingSymmetrical(24.w, 0.0)
|
|
|
|
: insuranceVM.patientInsuranceList.isNotEmpty
|
|
|
|
: insuranceVM.patientInsuranceList.isNotEmpty
|
|
|
|
? PatientInsuranceCard(
|
|
|
|
? PatientInsuranceCard(
|
|
|
|
insuranceCardDetailsModel: insuranceVM.patientInsuranceList.first,
|
|
|
|
insuranceCardDetailsModel: insuranceVM.patientInsuranceList.first,
|
|
|
|
@ -763,15 +793,15 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
: Container(
|
|
|
|
: Container(
|
|
|
|
decoration: RoundedRectangleBorder().toSmoothCornerDecoration(
|
|
|
|
decoration: RoundedRectangleBorder().toSmoothCornerDecoration(
|
|
|
|
color: AppColors.whiteColor,
|
|
|
|
color: AppColors.whiteColor,
|
|
|
|
borderRadius: 20.h,
|
|
|
|
borderRadius: 12.r,
|
|
|
|
hasShadow: false,
|
|
|
|
hasShadow: false,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
child: Utils.getNoDataWidget(
|
|
|
|
child: Utils.getNoDataWidget(
|
|
|
|
context,
|
|
|
|
context,
|
|
|
|
noDataText: "You don't have insurance registered with HMG.".needTranslation,
|
|
|
|
noDataText: "You don't have insurance registered with HMG.".needTranslation,
|
|
|
|
isSmallWidget: true,
|
|
|
|
isSmallWidget: true,
|
|
|
|
width: 62,
|
|
|
|
width: 62.w,
|
|
|
|
height: 62,
|
|
|
|
height: 62.h,
|
|
|
|
callToActionButton: CustomButton(
|
|
|
|
callToActionButton: CustomButton(
|
|
|
|
icon: AppAssets.update_insurance_card_icon,
|
|
|
|
icon: AppAssets.update_insurance_card_icon,
|
|
|
|
iconColor: AppColors.successColor,
|
|
|
|
iconColor: AppColors.successColor,
|
|
|
|
@ -781,30 +811,31 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
insuranceViewModel.setIsInsuranceUpdateDetailsLoading(true);
|
|
|
|
insuranceViewModel.setIsInsuranceUpdateDetailsLoading(true);
|
|
|
|
insuranceViewModel.getPatientInsuranceDetailsForUpdate(
|
|
|
|
insuranceViewModel.getPatientInsuranceDetailsForUpdate(
|
|
|
|
appState.getAuthenticatedUser()!.patientId.toString(), appState.getAuthenticatedUser()!.patientIdentificationNo.toString());
|
|
|
|
appState.getAuthenticatedUser()!.patientId.toString(), appState.getAuthenticatedUser()!.patientIdentificationNo.toString());
|
|
|
|
showCommonBottomSheetWithoutHeight(context, child: PatientInsuranceCardUpdateCard(), callBackFunc: () {}, title: "", isCloseButtonVisible: false, isFullScreen: false);
|
|
|
|
showCommonBottomSheetWithoutHeight(context,
|
|
|
|
|
|
|
|
child: PatientInsuranceCardUpdateCard(), callBackFunc: () {}, title: "", isCloseButtonVisible: false, isFullScreen: false);
|
|
|
|
},
|
|
|
|
},
|
|
|
|
backgroundColor: AppColors.bgGreenColor.withOpacity(0.20),
|
|
|
|
backgroundColor: AppColors.bgGreenColor.withOpacity(0.20),
|
|
|
|
borderColor: AppColors.bgGreenColor.withOpacity(0.0),
|
|
|
|
borderColor: AppColors.bgGreenColor.withOpacity(0.0),
|
|
|
|
textColor: AppColors.bgGreenColor,
|
|
|
|
textColor: AppColors.bgGreenColor,
|
|
|
|
fontSize: 14,
|
|
|
|
fontSize: 14.f,
|
|
|
|
fontWeight: FontWeight.w500,
|
|
|
|
fontWeight: FontWeight.w500,
|
|
|
|
borderRadius: 12,
|
|
|
|
borderRadius: 12.r,
|
|
|
|
padding: EdgeInsets.fromLTRB(10, 0, 10, 0),
|
|
|
|
padding: EdgeInsets.fromLTRB(10.w, 0, 10.w, 0),
|
|
|
|
height: 40.h,
|
|
|
|
height: 56.h,
|
|
|
|
).paddingOnly(left: 12.h, right: 12.h, bottom: 12.h),
|
|
|
|
).paddingOnly(left: 12.w, right: 12.w, bottom: 12.h),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
).paddingSymmetrical(24.h, 0.h);
|
|
|
|
).paddingSymmetrical(24.w, 0.h);
|
|
|
|
}),
|
|
|
|
}),
|
|
|
|
SizedBox(height: 10.h),
|
|
|
|
SizedBox(height: 10.h),
|
|
|
|
GridView(
|
|
|
|
GridView(
|
|
|
|
gridDelegate: SliverGridDelegateWithFixedCrossAxisCount(
|
|
|
|
gridDelegate: SliverGridDelegateWithFixedCrossAxisCount(
|
|
|
|
crossAxisCount: 3,
|
|
|
|
crossAxisCount: 3,
|
|
|
|
crossAxisSpacing: 16,
|
|
|
|
crossAxisSpacing: 16.h,
|
|
|
|
mainAxisSpacing: 16,
|
|
|
|
mainAxisSpacing: 16.w,
|
|
|
|
mainAxisExtent: 140,
|
|
|
|
mainAxisExtent: 150.h,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
physics: NeverScrollableScrollPhysics(),
|
|
|
|
physics: NeverScrollableScrollPhysics(),
|
|
|
|
padding: EdgeInsets.only(top: 12),
|
|
|
|
padding: EdgeInsets.only(top: 12.h),
|
|
|
|
shrinkWrap: true,
|
|
|
|
shrinkWrap: true,
|
|
|
|
children: [
|
|
|
|
children: [
|
|
|
|
MedicalFileCard(
|
|
|
|
MedicalFileCard(
|
|
|
|
@ -813,13 +844,9 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
backgroundColor: AppColors.whiteColor,
|
|
|
|
backgroundColor: AppColors.whiteColor,
|
|
|
|
svgIcon: AppAssets.eye_result_icon,
|
|
|
|
svgIcon: AppAssets.eye_result_icon,
|
|
|
|
isLargeText: true,
|
|
|
|
isLargeText: true,
|
|
|
|
iconSize: 36.h)
|
|
|
|
iconSize: 36.w,
|
|
|
|
.onPress(() {
|
|
|
|
).onPress(() {
|
|
|
|
Navigator.of(context).push(
|
|
|
|
Navigator.of(context).push(CustomPageRoute(page: InsuranceHomePage()));
|
|
|
|
CustomPageRoute(
|
|
|
|
|
|
|
|
page: InsuranceHomePage(),
|
|
|
|
|
|
|
|
),
|
|
|
|
|
|
|
|
);
|
|
|
|
|
|
|
|
}),
|
|
|
|
}),
|
|
|
|
MedicalFileCard(
|
|
|
|
MedicalFileCard(
|
|
|
|
label: "${LocaleKeys.insurance.tr(context: context)} ${LocaleKeys.approvals.tr(context: context)}",
|
|
|
|
label: "${LocaleKeys.insurance.tr(context: context)} ${LocaleKeys.approvals.tr(context: context)}",
|
|
|
|
@ -827,7 +854,8 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
backgroundColor: AppColors.whiteColor,
|
|
|
|
backgroundColor: AppColors.whiteColor,
|
|
|
|
svgIcon: AppAssets.eye_result_icon,
|
|
|
|
svgIcon: AppAssets.eye_result_icon,
|
|
|
|
isLargeText: true,
|
|
|
|
isLargeText: true,
|
|
|
|
iconSize: 36.h).onPress(() {
|
|
|
|
iconSize: 36.w,
|
|
|
|
|
|
|
|
).onPress(() {
|
|
|
|
Navigator.of(context).push(
|
|
|
|
Navigator.of(context).push(
|
|
|
|
CustomPageRoute(
|
|
|
|
CustomPageRoute(
|
|
|
|
page: InsuranceApprovalsPage(),
|
|
|
|
page: InsuranceApprovalsPage(),
|
|
|
|
@ -840,16 +868,16 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
backgroundColor: AppColors.whiteColor,
|
|
|
|
backgroundColor: AppColors.whiteColor,
|
|
|
|
svgIcon: AppAssets.eye_result_icon,
|
|
|
|
svgIcon: AppAssets.eye_result_icon,
|
|
|
|
isLargeText: true,
|
|
|
|
isLargeText: true,
|
|
|
|
iconSize: 36.h),
|
|
|
|
iconSize: 36.w),
|
|
|
|
MedicalFileCard(
|
|
|
|
MedicalFileCard(
|
|
|
|
label: "Ancillary Orders List".needTranslation,
|
|
|
|
label: "Ancillary Orders List".needTranslation,
|
|
|
|
textColor: AppColors.blackColor,
|
|
|
|
textColor: AppColors.blackColor,
|
|
|
|
backgroundColor: AppColors.whiteColor,
|
|
|
|
backgroundColor: AppColors.whiteColor,
|
|
|
|
svgIcon: AppAssets.eye_result_icon,
|
|
|
|
svgIcon: AppAssets.eye_result_icon,
|
|
|
|
isLargeText: true,
|
|
|
|
isLargeText: true,
|
|
|
|
iconSize: 36.h),
|
|
|
|
iconSize: 36.w),
|
|
|
|
],
|
|
|
|
],
|
|
|
|
).paddingSymmetrical(24.h, 0.0),
|
|
|
|
).paddingSymmetrical(24.w, 0.0),
|
|
|
|
SizedBox(height: 16.h),
|
|
|
|
SizedBox(height: 16.h),
|
|
|
|
],
|
|
|
|
],
|
|
|
|
);
|
|
|
|
);
|
|
|
|
@ -862,34 +890,34 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
? PatientSickLeaveCard(
|
|
|
|
? PatientSickLeaveCard(
|
|
|
|
patientSickLeavesResponseModel: PatientSickLeavesResponseModel(),
|
|
|
|
patientSickLeavesResponseModel: PatientSickLeavesResponseModel(),
|
|
|
|
isLoading: true,
|
|
|
|
isLoading: true,
|
|
|
|
).paddingSymmetrical(24.h, 0.0)
|
|
|
|
).paddingSymmetrical(24.w, 0.0)
|
|
|
|
: medicalFileVM.patientSickLeaveList.isNotEmpty
|
|
|
|
: medicalFileVM.patientSickLeaveList.isNotEmpty
|
|
|
|
? PatientSickLeaveCard(
|
|
|
|
? PatientSickLeaveCard(
|
|
|
|
patientSickLeavesResponseModel: medicalFileVM.patientSickLeaveList.first,
|
|
|
|
patientSickLeavesResponseModel: medicalFileVM.patientSickLeaveList.first,
|
|
|
|
isLoading: false,
|
|
|
|
isLoading: false,
|
|
|
|
).paddingSymmetrical(24.h, 0.0)
|
|
|
|
).paddingSymmetrical(24.w, 0.0)
|
|
|
|
: Container(
|
|
|
|
: Container(
|
|
|
|
decoration: RoundedRectangleBorder().toSmoothCornerDecoration(
|
|
|
|
decoration: RoundedRectangleBorder().toSmoothCornerDecoration(
|
|
|
|
color: AppColors.whiteColor,
|
|
|
|
color: AppColors.whiteColor,
|
|
|
|
borderRadius: 20.h,
|
|
|
|
borderRadius: 12.r,
|
|
|
|
hasShadow: false,
|
|
|
|
hasShadow: false,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
child: Utils.getNoDataWidget(
|
|
|
|
child: Utils.getNoDataWidget(
|
|
|
|
context,
|
|
|
|
context,
|
|
|
|
noDataText: "You don't have any sick leaves yet.".needTranslation,
|
|
|
|
noDataText: "You don't have any sick leaves yet.".needTranslation,
|
|
|
|
isSmallWidget: true,
|
|
|
|
isSmallWidget: true,
|
|
|
|
width: 62,
|
|
|
|
width: 62.w,
|
|
|
|
height: 62,
|
|
|
|
height: 62.h,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
).paddingSymmetrical(24.h, 0.h);
|
|
|
|
).paddingSymmetrical(24.w, 0.h);
|
|
|
|
}),
|
|
|
|
}),
|
|
|
|
SizedBox(height: 16.h),
|
|
|
|
SizedBox(height: 16.h),
|
|
|
|
GridView(
|
|
|
|
GridView(
|
|
|
|
gridDelegate: SliverGridDelegateWithFixedCrossAxisCount(
|
|
|
|
gridDelegate: SliverGridDelegateWithFixedCrossAxisCount(
|
|
|
|
crossAxisCount: 3,
|
|
|
|
crossAxisCount: 3,
|
|
|
|
crossAxisSpacing: 16,
|
|
|
|
crossAxisSpacing: 16.h,
|
|
|
|
mainAxisSpacing: 16,
|
|
|
|
mainAxisSpacing: 16.w,
|
|
|
|
mainAxisExtent: 140,
|
|
|
|
mainAxisExtent: 140.h,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
physics: NeverScrollableScrollPhysics(),
|
|
|
|
physics: NeverScrollableScrollPhysics(),
|
|
|
|
padding: EdgeInsets.zero,
|
|
|
|
padding: EdgeInsets.zero,
|
|
|
|
@ -934,7 +962,7 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
);
|
|
|
|
);
|
|
|
|
}),
|
|
|
|
}),
|
|
|
|
],
|
|
|
|
],
|
|
|
|
).paddingSymmetrical(24.h, 0.0),
|
|
|
|
).paddingSymmetrical(24.w, 0.0),
|
|
|
|
SizedBox(height: 24.h),
|
|
|
|
SizedBox(height: 24.h),
|
|
|
|
],
|
|
|
|
],
|
|
|
|
);
|
|
|
|
);
|
|
|
|
@ -944,9 +972,4 @@ class _MedicalFilePageState extends State<MedicalFilePage> {
|
|
|
|
return Container();
|
|
|
|
return Container();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
getMember() {
|
|
|
|
|
|
|
|
// AuthanticationViewModel authanticationViewModel = getIt.get<AuthanticationViewModel>();
|
|
|
|
|
|
|
|
// RequestUtils.getAddFamilyRequest(nationalIDorFile: nationalIDorFile, mobileNo: mobileNo, countryCode: countryCode, loginType: loginType);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|