|  |  |  | @ -40,47 +40,52 @@ class _InsuranceHomePageState extends State<InsuranceHomePage> { | 
		
	
		
			
				|  |  |  |  | 
 | 
		
	
		
			
				|  |  |  |  |   @override | 
		
	
		
			
				|  |  |  |  |   Widget build(BuildContext context) { | 
		
	
		
			
				|  |  |  |  |     insuranceViewModel = Provider.of<InsuranceViewModel>(context); | 
		
	
		
			
				|  |  |  |  |     insuranceViewModel = Provider.of<InsuranceViewModel>(context, listen: false); | 
		
	
		
			
				|  |  |  |  |     return Scaffold( | 
		
	
		
			
				|  |  |  |  |       backgroundColor: AppColors.bgScaffoldColor, | 
		
	
		
			
				|  |  |  |  |       body: CollapsingListView( | 
		
	
		
			
				|  |  |  |  |         title: "${LocaleKeys.insurance.tr(context: context)} ${LocaleKeys.updateInsurance.tr(context: context)}", | 
		
	
		
			
				|  |  |  |  |         history: () { | 
		
	
		
			
				|  |  |  |  |           insuranceViewModel.setIsInsuranceHistoryLoading(true); | 
		
	
		
			
				|  |  |  |  |           insuranceViewModel.getPatientInsuranceCardHistory(); | 
		
	
		
			
				|  |  |  |  |           showCommonBottomSheet(context, | 
		
	
		
			
				|  |  |  |  |               child: InsuranceHistory(), callBackFunc: (str) {}, title: "", height: ResponsiveExtension.screenHeight * 0.65, isCloseButtonVisible: false, isFullScreen: false); | 
		
	
		
			
				|  |  |  |  |         }, | 
		
	
		
			
				|  |  |  |  |         child: SingleChildScrollView( | 
		
	
		
			
				|  |  |  |  |           child: Consumer<InsuranceViewModel>(builder: (context, insuranceVM, child) { | 
		
	
		
			
				|  |  |  |  |             return Column( | 
		
	
		
			
				|  |  |  |  |               crossAxisAlignment: CrossAxisAlignment.start, | 
		
	
		
			
				|  |  |  |  |               children: [ | 
		
	
		
			
				|  |  |  |  |                 Row( | 
		
	
		
			
				|  |  |  |  |                   mainAxisAlignment: MainAxisAlignment.spaceBetween, | 
		
	
		
			
				|  |  |  |  |                   children: [ | 
		
	
		
			
				|  |  |  |  |                     "${LocaleKeys.insurance.tr(context: context)} ${LocaleKeys.updateInsurance.tr(context: context)}".toText24(isBold: true), | 
		
	
		
			
				|  |  |  |  |                     CustomButton( | 
		
	
		
			
				|  |  |  |  |                       icon: AppAssets.insurance_history_icon, | 
		
	
		
			
				|  |  |  |  |                       iconColor: AppColors.primaryRedColor, | 
		
	
		
			
				|  |  |  |  |                       iconSize: 21.h, | 
		
	
		
			
				|  |  |  |  |                       text: LocaleKeys.history.tr(context: context), | 
		
	
		
			
				|  |  |  |  |                       onPressed: () { | 
		
	
		
			
				|  |  |  |  |                         insuranceVM.setIsInsuranceHistoryLoading(true); | 
		
	
		
			
				|  |  |  |  |                         insuranceVM.getPatientInsuranceCardHistory(); | 
		
	
		
			
				|  |  |  |  |                         showCommonBottomSheet(context, | 
		
	
		
			
				|  |  |  |  |                             child: InsuranceHistory(), callBackFunc: (str) {}, title: "", height: ResponsiveExtension.screenHeight * 0.65, isCloseButtonVisible: false, isFullScreen: false); | 
		
	
		
			
				|  |  |  |  |                       }, | 
		
	
		
			
				|  |  |  |  |                       backgroundColor: AppColors.primaryRedColor.withOpacity(0.1), | 
		
	
		
			
				|  |  |  |  |                       borderColor: AppColors.primaryRedColor.withOpacity(0.0), | 
		
	
		
			
				|  |  |  |  |                       textColor: AppColors.primaryRedColor, | 
		
	
		
			
				|  |  |  |  |                       fontSize: 14, | 
		
	
		
			
				|  |  |  |  |                       fontWeight: FontWeight.w600, | 
		
	
		
			
				|  |  |  |  |                       borderRadius: 12, | 
		
	
		
			
				|  |  |  |  |                       padding: EdgeInsets.fromLTRB(10, 0, 10, 0), | 
		
	
		
			
				|  |  |  |  |                       height: 40.h, | 
		
	
		
			
				|  |  |  |  |                     ), | 
		
	
		
			
				|  |  |  |  |                   ], | 
		
	
		
			
				|  |  |  |  |                 ).paddingSymmetrical(24.h, 24.h), | 
		
	
		
			
				|  |  |  |  |                 // Row( | 
		
	
		
			
				|  |  |  |  |                 //   mainAxisAlignment: MainAxisAlignment.spaceBetween, | 
		
	
		
			
				|  |  |  |  |                 //   children: [ | 
		
	
		
			
				|  |  |  |  |                 //     "${LocaleKeys.insurance.tr(context: context)} ${LocaleKeys.updateInsurance.tr(context: context)}".toText24(isBold: true), | 
		
	
		
			
				|  |  |  |  |                 //     CustomButton( | 
		
	
		
			
				|  |  |  |  |                 //       icon: AppAssets.insurance_history_icon, | 
		
	
		
			
				|  |  |  |  |                 //       iconColor: AppColors.primaryRedColor, | 
		
	
		
			
				|  |  |  |  |                 //       iconSize: 21.h, | 
		
	
		
			
				|  |  |  |  |                 //       text: LocaleKeys.history.tr(context: context), | 
		
	
		
			
				|  |  |  |  |                 //       onPressed: () { | 
		
	
		
			
				|  |  |  |  |                 //       }, | 
		
	
		
			
				|  |  |  |  |                 //       backgroundColor: AppColors.primaryRedColor.withOpacity(0.1), | 
		
	
		
			
				|  |  |  |  |                 //       borderColor: AppColors.primaryRedColor.withOpacity(0.0), | 
		
	
		
			
				|  |  |  |  |                 //       textColor: AppColors.primaryRedColor, | 
		
	
		
			
				|  |  |  |  |                 //       fontSize: 14, | 
		
	
		
			
				|  |  |  |  |                 //       fontWeight: FontWeight.w600, | 
		
	
		
			
				|  |  |  |  |                 //       borderRadius: 12, | 
		
	
		
			
				|  |  |  |  |                 //       padding: EdgeInsets.fromLTRB(10, 0, 10, 0), | 
		
	
		
			
				|  |  |  |  |                 //       height: 40.h, | 
		
	
		
			
				|  |  |  |  |                 //     ), | 
		
	
		
			
				|  |  |  |  |                 //   ], | 
		
	
		
			
				|  |  |  |  |                 // ).paddingSymmetrical(24.h, 24.h), | 
		
	
		
			
				|  |  |  |  |                 insuranceVM.isInsuranceLoading | 
		
	
		
			
				|  |  |  |  |                     ? const MoviesShimmerWidget().paddingSymmetrical(24.h, 0) | 
		
	
		
			
				|  |  |  |  |                     : PatientInsuranceCard( | 
		
	
		
			
				|  |  |  |  |                         insuranceCardDetailsModel: insuranceVM.patientInsuranceList.first, | 
		
	
		
			
				|  |  |  |  |                         isInsuranceExpired: DateTime.now().isAfter(DateUtil.convertStringToDate(insuranceVM.patientInsuranceList.first.cardValidTo))), | 
		
	
		
			
				|  |  |  |  |                     : Padding( | 
		
	
		
			
				|  |  |  |  |                       padding: EdgeInsets.only(top: 24.h), | 
		
	
		
			
				|  |  |  |  |                       child: PatientInsuranceCard( | 
		
	
		
			
				|  |  |  |  |                           insuranceCardDetailsModel: insuranceVM.patientInsuranceList.first, | 
		
	
		
			
				|  |  |  |  |                           isInsuranceExpired: DateTime.now().isAfter(DateUtil.convertStringToDate(insuranceVM.patientInsuranceList.first.cardValidTo))), | 
		
	
		
			
				|  |  |  |  |                     ), | 
		
	
		
			
				|  |  |  |  |               ], | 
		
	
		
			
				|  |  |  |  |             ); | 
		
	
		
			
				|  |  |  |  |           }), | 
		
	
	
		
			
				
					|  |  |  | 
 |