|
|
|
|
@ -1,19 +1,13 @@
|
|
|
|
|
import 'package:diplomaticquarterapp/config/size_config.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/core/model/AlHabibMedicalService/EReferral/search_criteria_model.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/core/viewModels/dashboard_view_model.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/core/viewModels/project_view_model.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/d_q_icons_icons.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/pages/AlHabibMedicalService/ComprehensiveMedicalCheckup/cmc_index_page.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/pages/AlHabibMedicalService/HomeHealthCare/home_health_care_index_page.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/models/Appointments/toDoCountProviderModel.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/pages/AlHabibMedicalService/all_habib_medical_service_page.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/pages/ContactUs/contact_us_page.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/pages/Covid-DriveThru/covid-drivethru-location.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/pages/ErService/ErOptions.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/pages/MyAppointments/MyAppointments.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/pages/base/base_view.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/pages/insurance/insurance_card_screen.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/pages/livecare/livecare_home.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/pages/medical/active_medications/ActiveMedicationsPage.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/pages/medical/doctor/doctor_home_page.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/pages/medical/labs/labs_home_page.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/pages/medical/prescriptions/prescriptions_home_page.dart';
|
|
|
|
|
@ -21,6 +15,8 @@ import 'package:diplomaticquarterapp/pages/medical/radiology/radiology_home_page
|
|
|
|
|
import 'package:diplomaticquarterapp/pages/medical/vital_sign/vital_sign_details_screen.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/pages/paymentService/payment_service.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/pages/pharmacies/medicine_search_screen.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/services/clinic_services/get_clinic_service.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/uitl/app_toast.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/uitl/date_uitl.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/widgets/data_display/medical/medical_profile_item.dart';
|
|
|
|
|
@ -29,8 +25,6 @@ import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/widgets/transitions/fade_page.dart';
|
|
|
|
|
import 'package:flutter/cupertino.dart';
|
|
|
|
|
import 'package:flutter/material.dart';
|
|
|
|
|
import 'package:flutter_svg/flutter_svg.dart';
|
|
|
|
|
import 'package:hexcolor/hexcolor.dart';
|
|
|
|
|
import 'package:provider/provider.dart';
|
|
|
|
|
|
|
|
|
|
class HomePage extends StatefulWidget {
|
|
|
|
|
@ -43,9 +37,20 @@ class HomePage extends StatefulWidget {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
class _HomePageState extends State<HomePage> {
|
|
|
|
|
var toDoProvider;
|
|
|
|
|
|
|
|
|
|
@override
|
|
|
|
|
void initState() {
|
|
|
|
|
WidgetsBinding.instance.addPostFrameCallback((timeStamp) {
|
|
|
|
|
getToDoCount();
|
|
|
|
|
});
|
|
|
|
|
super.initState();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@override
|
|
|
|
|
Widget build(BuildContext context) {
|
|
|
|
|
ProjectViewModel projectViewModel = Provider.of(context);
|
|
|
|
|
toDoProvider = Provider.of<ToDoCountProviderModel>(context);
|
|
|
|
|
return BaseView<DashboardViewModel>(
|
|
|
|
|
onModelReady: (model) => model.getPatientRadOrders(),
|
|
|
|
|
builder: (_, model, wi) => AppScaffold(
|
|
|
|
|
@ -76,7 +81,8 @@ class _HomePageState extends State<HomePage> {
|
|
|
|
|
left: 5,
|
|
|
|
|
right: 5,
|
|
|
|
|
child: Container(
|
|
|
|
|
width: MediaQuery.of(context).size.width * 0.8,
|
|
|
|
|
width:
|
|
|
|
|
MediaQuery.of(context).size.width * 0.8,
|
|
|
|
|
child: Container(),
|
|
|
|
|
),
|
|
|
|
|
)
|
|
|
|
|
@ -88,8 +94,16 @@ class _HomePageState extends State<HomePage> {
|
|
|
|
|
),
|
|
|
|
|
Positioned(
|
|
|
|
|
top: 40,
|
|
|
|
|
left: MediaQuery.of(context).size.width * (MediaQuery.of(context).orientation == Orientation.landscape ? 0.02 : 0.03),
|
|
|
|
|
right: MediaQuery.of(context).size.width * (MediaQuery.of(context).orientation == Orientation.landscape ? 0.02 : 0.03),
|
|
|
|
|
left: MediaQuery.of(context).size.width *
|
|
|
|
|
(MediaQuery.of(context).orientation ==
|
|
|
|
|
Orientation.landscape
|
|
|
|
|
? 0.02
|
|
|
|
|
: 0.03),
|
|
|
|
|
right: MediaQuery.of(context).size.width *
|
|
|
|
|
(MediaQuery.of(context).orientation ==
|
|
|
|
|
Orientation.landscape
|
|
|
|
|
? 0.02
|
|
|
|
|
: 0.03),
|
|
|
|
|
child: (!model.isLogin && projectViewModel.user == null)
|
|
|
|
|
? Container(
|
|
|
|
|
width: double.infinity,
|
|
|
|
|
@ -138,7 +152,10 @@ class _HomePageState extends State<HomePage> {
|
|
|
|
|
},
|
|
|
|
|
child: Container(
|
|
|
|
|
margin: EdgeInsets.all(2),
|
|
|
|
|
width: MediaQuery.of(context).size.width * 0.30,
|
|
|
|
|
width: MediaQuery.of(context)
|
|
|
|
|
.size
|
|
|
|
|
.width *
|
|
|
|
|
0.30,
|
|
|
|
|
height: 30,
|
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
|
color: Colors.white,
|
|
|
|
|
@ -153,7 +170,8 @@ class _HomePageState extends State<HomePage> {
|
|
|
|
|
child: Texts(
|
|
|
|
|
TranslationBase.of(context)
|
|
|
|
|
.viewMore,
|
|
|
|
|
color: Theme.of(context).primaryColor,
|
|
|
|
|
color: Theme.of(context)
|
|
|
|
|
.primaryColor,
|
|
|
|
|
fontSize: 12,
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
@ -166,7 +184,7 @@ class _HomePageState extends State<HomePage> {
|
|
|
|
|
)
|
|
|
|
|
: Container(
|
|
|
|
|
width: double.infinity,
|
|
|
|
|
height: projectViewModel.isArabic?180: 150,
|
|
|
|
|
height: projectViewModel.isArabic ? 180 : 150,
|
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
|
color: Theme.of(context).primaryColor,
|
|
|
|
|
shape: BoxShape.rectangle,
|
|
|
|
|
@ -184,7 +202,7 @@ class _HomePageState extends State<HomePage> {
|
|
|
|
|
child: Container(
|
|
|
|
|
margin: EdgeInsets.all(5),
|
|
|
|
|
child: Column(
|
|
|
|
|
// mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
|
|
// mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
Row(
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
@ -216,7 +234,8 @@ class _HomePageState extends State<HomePage> {
|
|
|
|
|
Texts(
|
|
|
|
|
'${DateUtil.getMonthDayYearDateFormatted(model.user.dateofBirthDataTime)} ,${model.user.genderDescription} ${model.user.ageDesc}',
|
|
|
|
|
color: Colors.grey[100],
|
|
|
|
|
fontWeight: FontWeight.normal,
|
|
|
|
|
fontWeight:
|
|
|
|
|
FontWeight.normal,
|
|
|
|
|
fontSize: 14,
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
@ -228,7 +247,10 @@ class _HomePageState extends State<HomePage> {
|
|
|
|
|
},
|
|
|
|
|
child: Container(
|
|
|
|
|
margin: EdgeInsets.all(2),
|
|
|
|
|
width: MediaQuery.of(context).size.width * 0.30,
|
|
|
|
|
width: MediaQuery.of(context)
|
|
|
|
|
.size
|
|
|
|
|
.width *
|
|
|
|
|
0.30,
|
|
|
|
|
height: 30,
|
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
|
color: Colors.white,
|
|
|
|
|
@ -242,8 +264,10 @@ class _HomePageState extends State<HomePage> {
|
|
|
|
|
),
|
|
|
|
|
child: Center(
|
|
|
|
|
child: Texts(
|
|
|
|
|
TranslationBase.of(context).viewMore,
|
|
|
|
|
color: Theme.of(context).primaryColor,
|
|
|
|
|
TranslationBase.of(context)
|
|
|
|
|
.viewMore,
|
|
|
|
|
color: Theme.of(context)
|
|
|
|
|
.primaryColor,
|
|
|
|
|
fontSize: 12,
|
|
|
|
|
bold: true,
|
|
|
|
|
),
|
|
|
|
|
@ -256,17 +280,19 @@ class _HomePageState extends State<HomePage> {
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
Expanded(
|
|
|
|
|
child: Row(
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.start,
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.center,
|
|
|
|
|
mainAxisAlignment:
|
|
|
|
|
MainAxisAlignment.start,
|
|
|
|
|
crossAxisAlignment:
|
|
|
|
|
CrossAxisAlignment.center,
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
Image.asset(
|
|
|
|
|
'assets/images/height_icon.png',
|
|
|
|
|
width: 30,
|
|
|
|
|
height: 55,
|
|
|
|
|
),
|
|
|
|
|
|
|
|
|
|
Column(
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
|
crossAxisAlignment:
|
|
|
|
|
CrossAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
Texts(
|
|
|
|
|
"${model.heightCm}",
|
|
|
|
|
@ -288,8 +314,10 @@ class _HomePageState extends State<HomePage> {
|
|
|
|
|
),
|
|
|
|
|
Expanded(
|
|
|
|
|
child: Row(
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.start,
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.center,
|
|
|
|
|
mainAxisAlignment:
|
|
|
|
|
MainAxisAlignment.start,
|
|
|
|
|
crossAxisAlignment:
|
|
|
|
|
CrossAxisAlignment.center,
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
Image.asset(
|
|
|
|
|
'assets/images/test-weight.png',
|
|
|
|
|
@ -302,7 +330,6 @@ class _HomePageState extends State<HomePage> {
|
|
|
|
|
'${model.weightKg}',
|
|
|
|
|
color: Colors.white,
|
|
|
|
|
bold: true,
|
|
|
|
|
|
|
|
|
|
),
|
|
|
|
|
Texts(
|
|
|
|
|
"Weight",
|
|
|
|
|
@ -319,8 +346,10 @@ class _HomePageState extends State<HomePage> {
|
|
|
|
|
),
|
|
|
|
|
Expanded(
|
|
|
|
|
child: Row(
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.start,
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.center,
|
|
|
|
|
mainAxisAlignment:
|
|
|
|
|
MainAxisAlignment.start,
|
|
|
|
|
crossAxisAlignment:
|
|
|
|
|
CrossAxisAlignment.center,
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
Image.asset(
|
|
|
|
|
'assets/images/blood-drop.png',
|
|
|
|
|
@ -373,28 +402,35 @@ class _HomePageState extends State<HomePage> {
|
|
|
|
|
padding: const EdgeInsets.all(15.0),
|
|
|
|
|
child: Column(
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
SizedBox(height: 15,),
|
|
|
|
|
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 15,
|
|
|
|
|
),
|
|
|
|
|
Container(
|
|
|
|
|
width: 60,
|
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
|
color: Colors.white,
|
|
|
|
|
shape: BoxShape.rectangle,
|
|
|
|
|
borderRadius: BorderRadius.circular(12)
|
|
|
|
|
),
|
|
|
|
|
child: Center(child: Image.asset('assets/images/vital_sign_icon.png',
|
|
|
|
|
borderRadius:
|
|
|
|
|
BorderRadius.circular(12)),
|
|
|
|
|
child: Center(
|
|
|
|
|
child: Image.asset(
|
|
|
|
|
'assets/images/vital_sign_icon.png',
|
|
|
|
|
width: 80,
|
|
|
|
|
height: 50,
|
|
|
|
|
fit: BoxFit.contain,)),
|
|
|
|
|
fit: BoxFit.contain,
|
|
|
|
|
)),
|
|
|
|
|
),
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 20,
|
|
|
|
|
),
|
|
|
|
|
SizedBox(height: 20,),
|
|
|
|
|
Texts(
|
|
|
|
|
TranslationBase.of(context)
|
|
|
|
|
.vitalSigns,
|
|
|
|
|
TranslationBase.of(context).vitalSigns,
|
|
|
|
|
textAlign: TextAlign.center,
|
|
|
|
|
color: Colors.white,
|
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
|
fontSize: projectViewModel.isArabic? SizeConfig.textMultiplier * 1.5 :SizeConfig.textMultiplier * 1.7,
|
|
|
|
|
fontSize: projectViewModel.isArabic
|
|
|
|
|
? SizeConfig.textMultiplier * 1.5
|
|
|
|
|
: SizeConfig.textMultiplier * 1.7,
|
|
|
|
|
)
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
@ -422,26 +458,35 @@ class _HomePageState extends State<HomePage> {
|
|
|
|
|
padding: const EdgeInsets.all(15.0),
|
|
|
|
|
child: Column(
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
SizedBox(height: 15,),
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 15,
|
|
|
|
|
),
|
|
|
|
|
Container(
|
|
|
|
|
width: 50,
|
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
|
color: Colors.white,
|
|
|
|
|
shape: BoxShape.rectangle,
|
|
|
|
|
borderRadius: BorderRadius.circular(12)
|
|
|
|
|
),
|
|
|
|
|
child: Center(child: Image.asset('assets/images/search_medicine_icon.png',
|
|
|
|
|
borderRadius:
|
|
|
|
|
BorderRadius.circular(12)),
|
|
|
|
|
child: Center(
|
|
|
|
|
child: Image.asset(
|
|
|
|
|
'assets/images/search_medicine_icon.png',
|
|
|
|
|
width: 50,
|
|
|
|
|
height: 50,
|
|
|
|
|
fit: BoxFit.contain,)),
|
|
|
|
|
fit: BoxFit.contain,
|
|
|
|
|
)),
|
|
|
|
|
),
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 20,
|
|
|
|
|
),
|
|
|
|
|
SizedBox(height: 20,),
|
|
|
|
|
Texts(
|
|
|
|
|
TranslationBase.of(context).searchMedicine,
|
|
|
|
|
textAlign: TextAlign.center,
|
|
|
|
|
color: Colors.white,
|
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
|
fontSize: projectViewModel.isArabic? SizeConfig.textMultiplier * 1.5 :SizeConfig.textMultiplier * 1.7,
|
|
|
|
|
fontSize: projectViewModel.isArabic
|
|
|
|
|
? SizeConfig.textMultiplier * 1.5
|
|
|
|
|
: SizeConfig.textMultiplier * 1.7,
|
|
|
|
|
)
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
@ -453,8 +498,9 @@ class _HomePageState extends State<HomePage> {
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
Expanded(
|
|
|
|
|
child: DashboardItem(opacity: 1.0,
|
|
|
|
|
onTap: (){
|
|
|
|
|
child: DashboardItem(
|
|
|
|
|
opacity: 1.0,
|
|
|
|
|
onTap: () {
|
|
|
|
|
Navigator.push(
|
|
|
|
|
context,
|
|
|
|
|
FadePage(
|
|
|
|
|
@ -467,26 +513,35 @@ class _HomePageState extends State<HomePage> {
|
|
|
|
|
padding: const EdgeInsets.all(15.0),
|
|
|
|
|
child: Column(
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
SizedBox(height: 15,),
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 15,
|
|
|
|
|
),
|
|
|
|
|
Container(
|
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
|
color: Colors.white,
|
|
|
|
|
shape: BoxShape.rectangle,
|
|
|
|
|
borderRadius: BorderRadius.circular(12)
|
|
|
|
|
),
|
|
|
|
|
child: Center(child: Image.asset('assets/images/online_payment_icon.png',
|
|
|
|
|
borderRadius:
|
|
|
|
|
BorderRadius.circular(12)),
|
|
|
|
|
child: Center(
|
|
|
|
|
child: Image.asset(
|
|
|
|
|
'assets/images/online_payment_icon.png',
|
|
|
|
|
width: 80,
|
|
|
|
|
height: 50,
|
|
|
|
|
fit: BoxFit.contain,)),
|
|
|
|
|
fit: BoxFit.contain,
|
|
|
|
|
)),
|
|
|
|
|
),
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 15,
|
|
|
|
|
),
|
|
|
|
|
SizedBox(height: 15,),
|
|
|
|
|
|
|
|
|
|
Texts(
|
|
|
|
|
TranslationBase.of(context).onlinePaymentService,
|
|
|
|
|
TranslationBase.of(context)
|
|
|
|
|
.onlinePaymentService,
|
|
|
|
|
textAlign: TextAlign.center,
|
|
|
|
|
color: Colors.white,
|
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
|
fontSize: projectViewModel.isArabic? SizeConfig.textMultiplier * 1.5 :SizeConfig.textMultiplier * 1.7,
|
|
|
|
|
fontSize: projectViewModel.isArabic
|
|
|
|
|
? SizeConfig.textMultiplier * 1.5
|
|
|
|
|
: SizeConfig.textMultiplier * 1.7,
|
|
|
|
|
)
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
@ -522,34 +577,33 @@ class _HomePageState extends State<HomePage> {
|
|
|
|
|
);
|
|
|
|
|
},
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context)
|
|
|
|
|
.myAppointments,
|
|
|
|
|
title:
|
|
|
|
|
TranslationBase.of(context).myAppointments,
|
|
|
|
|
imagePath: 'my_appointment_icon.png',
|
|
|
|
|
subTitle: TranslationBase.of(context).myAppointmentsList,
|
|
|
|
|
subTitle: TranslationBase.of(context)
|
|
|
|
|
.myAppointmentsList,
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
Expanded(
|
|
|
|
|
flex: 1,
|
|
|
|
|
child: InkWell(
|
|
|
|
|
onTap: () => Navigator.push(context,
|
|
|
|
|
FadePage(page: LabsHomePage())),
|
|
|
|
|
onTap: () => Navigator.push(
|
|
|
|
|
context, FadePage(page: LabsHomePage())),
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context).lab,
|
|
|
|
|
imagePath: 'lab_result_icon.png',
|
|
|
|
|
subTitle:
|
|
|
|
|
TranslationBase.of(context).lab,
|
|
|
|
|
subTitle: TranslationBase.of(context).lab,
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
Expanded(
|
|
|
|
|
flex: 1,
|
|
|
|
|
child: InkWell(
|
|
|
|
|
onTap: () => Navigator.push(context,
|
|
|
|
|
FadePage(page: RadiologyHomePage())),
|
|
|
|
|
onTap: () => Navigator.push(
|
|
|
|
|
context, FadePage(page: RadiologyHomePage())),
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context)
|
|
|
|
|
.radiology,
|
|
|
|
|
title: TranslationBase.of(context).radiology,
|
|
|
|
|
imagePath: 'radiology_icon.png',
|
|
|
|
|
subTitle: TranslationBase.of(context)
|
|
|
|
|
.radiologySubtitle,
|
|
|
|
|
@ -572,8 +626,7 @@ class _HomePageState extends State<HomePage> {
|
|
|
|
|
);
|
|
|
|
|
},
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context)
|
|
|
|
|
.medicines,
|
|
|
|
|
title: TranslationBase.of(context).medicines,
|
|
|
|
|
imagePath: 'prescription_icon.png',
|
|
|
|
|
subTitle: TranslationBase.of(context)
|
|
|
|
|
.medicinesSubtitle,
|
|
|
|
|
@ -592,8 +645,7 @@ class _HomePageState extends State<HomePage> {
|
|
|
|
|
);
|
|
|
|
|
},
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context)
|
|
|
|
|
.myDoctor,
|
|
|
|
|
title: TranslationBase.of(context).myDoctor,
|
|
|
|
|
imagePath: 'doctor_icon.png',
|
|
|
|
|
subTitle: TranslationBase.of(context)
|
|
|
|
|
.myDoctorSubtitle,
|
|
|
|
|
@ -604,12 +656,11 @@ class _HomePageState extends State<HomePage> {
|
|
|
|
|
flex: 1,
|
|
|
|
|
child: InkWell(
|
|
|
|
|
onTap: () {
|
|
|
|
|
Navigator.push(context,
|
|
|
|
|
FadePage(page: InsuranceCard()));
|
|
|
|
|
Navigator.push(
|
|
|
|
|
context, FadePage(page: InsuranceCard()));
|
|
|
|
|
},
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context)
|
|
|
|
|
.insurance,
|
|
|
|
|
title: TranslationBase.of(context).insurance,
|
|
|
|
|
imagePath: 'insurance_card_icon.png',
|
|
|
|
|
subTitle: TranslationBase.of(context)
|
|
|
|
|
.insuranceSubtitle,
|
|
|
|
|
@ -618,7 +669,6 @@ class _HomePageState extends State<HomePage> {
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
@ -631,7 +681,7 @@ class _HomePageState extends State<HomePage> {
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
DashboardItem(
|
|
|
|
|
opacity:1.0,
|
|
|
|
|
opacity: 1.0,
|
|
|
|
|
child: Container(
|
|
|
|
|
width: double.infinity,
|
|
|
|
|
padding: EdgeInsets.all(10),
|
|
|
|
|
@ -663,13 +713,13 @@ class _HomePageState extends State<HomePage> {
|
|
|
|
|
),
|
|
|
|
|
height: 100,
|
|
|
|
|
imageName: 'ask_doctor_bg.png',
|
|
|
|
|
//color: Colors.grey[700],
|
|
|
|
|
//color: Colors.grey[700],
|
|
|
|
|
width: MediaQuery.of(context).size.width * 0.45,
|
|
|
|
|
onTap: () => Navigator.push(
|
|
|
|
|
context, FadePage(page: AllHabibMedicalService())),
|
|
|
|
|
),
|
|
|
|
|
DashboardItem(
|
|
|
|
|
opacity:1.0,
|
|
|
|
|
opacity: 1.0,
|
|
|
|
|
onTap: () {
|
|
|
|
|
// Navigator.push(
|
|
|
|
|
// context, FadePage(page: FeedbackHomePage()));
|
|
|
|
|
@ -727,6 +777,23 @@ class _HomePageState extends State<HomePage> {
|
|
|
|
|
Navigator.push(context,
|
|
|
|
|
MaterialPageRoute(builder: (context) => CovidDrivethruLocation()));
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
getToDoCount() {
|
|
|
|
|
toDoProvider.setState(0);
|
|
|
|
|
ClinicListService service = new ClinicListService();
|
|
|
|
|
service.getActiveAppointmentNo(context).then((res) {
|
|
|
|
|
print(res['AppointmentActiveNumber']);
|
|
|
|
|
if (res['MessageStatus'] == 1) {
|
|
|
|
|
setState(() {
|
|
|
|
|
toDoProvider.setState(res['AppointmentActiveNumber']);
|
|
|
|
|
});
|
|
|
|
|
} else {
|
|
|
|
|
AppToast.showErrorToast(message: res['ErrorEndUserMessage']);
|
|
|
|
|
}
|
|
|
|
|
}).catchError((err) {
|
|
|
|
|
print(err);
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
class DashboardItem extends StatelessWidget {
|
|
|
|
|
@ -739,7 +806,9 @@ class DashboardItem extends StatelessWidget {
|
|
|
|
|
this.width,
|
|
|
|
|
this.height,
|
|
|
|
|
this.color,
|
|
|
|
|
this.opacity = 1.0,this.icon,this.margin=0})
|
|
|
|
|
this.opacity = 1.0,
|
|
|
|
|
this.icon,
|
|
|
|
|
this.margin = 0})
|
|
|
|
|
: super(key: key);
|
|
|
|
|
final bool hasBorder;
|
|
|
|
|
final String imageName;
|
|
|
|
|
|