diff --git a/assets/images/CloseIcon.png b/assets/images/CloseIcon.png
new file mode 100644
index 00000000..b8e68fea
Binary files /dev/null and b/assets/images/CloseIcon.png differ
diff --git a/assets/images/robort.png b/assets/images/robort.png
new file mode 100644
index 00000000..320afcbc
Binary files /dev/null and b/assets/images/robort.png differ
diff --git a/assets/images/svg/robort_svg.svg b/assets/images/svg/robort_svg.svg
new file mode 100644
index 00000000..07d3d4b4
--- /dev/null
+++ b/assets/images/svg/robort_svg.svg
@@ -0,0 +1,82 @@
+
diff --git a/assets/images/svg/symptom.svg b/assets/images/svg/symptom.svg
new file mode 100644
index 00000000..aa670da1
--- /dev/null
+++ b/assets/images/svg/symptom.svg
@@ -0,0 +1,30 @@
+
\ No newline at end of file
diff --git a/lib/config/config.dart b/lib/config/config.dart
index 55fe744d..a3ce19e9 100644
--- a/lib/config/config.dart
+++ b/lib/config/config.dart
@@ -6,7 +6,7 @@ import 'package:diplomaticquarterapp/widgets/mobile-no/mobile_no.dart';
const MAX_SMALL_SCREEN = 660;
-const BASE_URL = 'https://uat.hmgwebservices.com/';
+const BASE_URL = 'https://hmgwebservices.com/';
const GET_PROJECT = 'Services/Lists.svc/REST/GetProject';
@@ -29,8 +29,10 @@ const GET_PRESCRIPTION_REPORT_ENH =
///Lab Order
const GET_Patient_LAB_ORDERS = 'Services/Patients.svc/REST/GetPatientLabOrders';
-const GET_Patient_LAB_SPECIAL_RESULT = 'Services/Patients.svc/REST/GetPatientLabSpecialResults';
-const GET_Patient_LAB_RESULT = '/Services/Patients.svc/REST/GetPatientLabResults';
+const GET_Patient_LAB_SPECIAL_RESULT =
+ 'Services/Patients.svc/REST/GetPatientLabSpecialResults';
+const GET_Patient_LAB_RESULT =
+ '/Services/Patients.svc/REST/GetPatientLabResults';
///
const GET_PATIENT_ORDERS = 'Services/Patients.svc/REST/GetPatientRadOrders';
@@ -43,8 +45,7 @@ const SEND_RAD_REPORT_EMAIL =
///Feedback
const SEND_FEEDBACK = 'Services/COCWS.svc/REST/InsertCOCItemInSPList';
const GET_STATUS_FOR_COCO = 'Services/COCWS.svc/REST/GetStatusforCOC';
-const GET_PATIENT_AppointmentHistory =
- 'Services'
+const GET_PATIENT_AppointmentHistory = 'Services'
'/Doctors.svc/REST/PateintHasAppoimentHistory';
///VITAL SIGN
@@ -52,59 +53,50 @@ const GET_PATIENT_VITAL_SIGN =
'Services/Doctors.svc/REST/Doctor_GetPatientVitalSign';
///Er Nearest
-const GET_NEAREST_HOSPITAL=
+const GET_NEAREST_HOSPITAL =
'Services/Patients.svc/REST/Patient_GetProjectAvgERWaitingTime';
///Er Nearest
-const GET_AMBULANCE_REQUEST= 'Services/Patients.svc/REST/PatientER_RRT_GetAllTransportationMethod';
+const GET_AMBULANCE_REQUEST = 'Services/Patients.svc/REST/PatientER_RRT_GetAllTransportationMethod';
const GET_PATIENT_ALL_PRES_ORDERS= 'Services/Patients.svc/REST/PatientER_GetPatientAllPresOrders';
const GET_PICK_UP_REQUEST_BY_PRES_ORDER_ID= 'Services/Patients.svc/REST/PatientER_RRT_GetPickUpRequestByPresOrderID';
-
///FindUs
-const GET_FINDUS_REQUEST=
- 'Services/Lists.svc/REST/Get_HMG_Locations';
-
+const GET_FINDUS_REQUEST = 'Services/Lists.svc/REST/Get_HMG_Locations';
///LiveChat
-const GET_LIVECHAT_REQUEST=
- 'Services/Patients.svc/REST/GetPatientICProjects';
+const GET_LIVECHAT_REQUEST = 'Services/Patients.svc/REST/GetPatientICProjects';
+
+///babyInformation
+const GET_BABYINFORMATION_REQUEST =
+ 'Services/Community.svc/REST/GetBabyByUserID';
///Get Baby By User ID
-const GET_BABY_BY_USER_ID= 'Services/Community.svc/REST/GetBabyByUserID';
+const GET_BABY_BY_USER_ID = 'Services/Community.svc/REST/GetBabyByUserID';
///userInformation
-const GET_USERINFORMATION_REQUEST=
+const GET_USERINFORMATION_REQUEST =
'Services/Community.svc/REST/GetUserInformation_New';
-///newUserId
-const GET_NEW_USER_REQUEST=
- 'Services/Community.svc/REST/CreateNewUser_New';
-
///addNewChild
-const GET_NEWCHILD_REQUEST=
- 'Services/Community.svc/REST/CreateNewBaby';
+const GET_NEWCHILD_REQUEST = 'Services/Community.svc/REST/CreateNewBaby';
-///delteChild
-const DELETE_CHILD_REQUEST=
- 'Services/Community.svc/REST/DeleteBaby';
+///newUserId
+const GET_NEW_USER_REQUEST = 'Services/Community.svc/REST/CreateNewUser_New';
+///delteChild
+const DELETE_CHILD_REQUEST = 'Services/Community.svc/REST/DeleteBaby';
///addNewTABLE
-const GET_TABLE_REQUEST=
- 'Services/Community.svc/REST/CreateVaccinationTable';
-
-
+const GET_TABLE_REQUEST = 'Services/Community.svc/REST/CreateVaccinationTable';
///BloodDenote
-const GET_CITIES_REQUEST=
- 'Services/Lists.svc/REST/GetAllCities';
+const GET_CITIES_REQUEST = 'Services/Lists.svc/REST/GetAllCities';
///BloodDetails
-const GET_BLOOD_REQUEST=
+const GET_BLOOD_REQUEST =
'services/PatientVarification.svc/REST/BloodDonation_GetBloodGroupDetails';
-
///Reports
const REPORTS = 'Services/Doctors.svc/REST/GetPatientMedicalReportStatusInfo';
const INSERT_REQUEST_FOR_MEDICAL_REPORT =
@@ -132,7 +124,8 @@ const GET_PROJECTS_LIST = 'Services/Lists.svc/REST/GetProject';
const GET_DOCTORS_LIST_URL = "Services/Doctors.svc/REST/SearchDoctorsByTime";
//URL to dental doctors list
-const GET_DENTAL_DOCTORS_LIST_URL = "Services/Doctors.svc/REST/Dental_DoctorChiefComplaintMapping";
+const GET_DENTAL_DOCTORS_LIST_URL =
+ "Services/Doctors.svc/REST/Dental_DoctorChiefComplaintMapping";
//URL to get doctor free slots
const GET_DOCTOR_FREE_SLOTS = "Services/Doctors.svc/REST/GetDoctorFreeSlots";
@@ -221,16 +214,16 @@ const CANCEL_LIVECARE_REQUEST =
const SEND_LIVECARE_INVOICE_EMAIL =
'Services/Notifications.svc/REST/SendInvoiceForLiveCare';
-
-const GET_USER_TERMS ='/Services/Patients.svc/REST/GetUserTermsAndConditions';
-const UPDATE_HEALTH_TERMS ='/services/Patients.svc/REST/UpdatePateintHealthSummaryReport';
+const GET_USER_TERMS = '/Services/Patients.svc/REST/GetUserTermsAndConditions';
+const UPDATE_HEALTH_TERMS =
+ '/services/Patients.svc/REST/UpdatePateintHealthSummaryReport';
//URL to get medicine and pharmacies list
const CHANNEL = 3;
const GENERAL_ID = 'Cs2020@2016\$2958';
const IP_ADDRESS = '10.20.10.20';
const VERSION_ID = 5.6;
-const SETUP_ID = '91877';
+const SETUP_ID = '91877';
const LANGUAGE = 2;
const PATIENT_OUT_SA = 0;
const SESSION_ID = 'TMRhVmkGhOsvamErw';
@@ -258,11 +251,16 @@ const GET_PATIENT_SICK_LEAVE = 'Services/Patients.svc/REST/GetPatientSickLeave';
const SendSickLeaveEmail = 'Services/Notifications.svc/REST/SendSickLeaveEmail';
-const GET_PATIENT_AdVANCE_BALANCE_AMOUNT = 'Services/Patients.svc/REST/GetPatientAdvanceBalanceAmount';
-const GET_PATIENT_INFO_BY_ID = 'Services/Doctors.svc/REST/GetPatientInfoByPatientID';
-const GET_PATIENT_INFO_BY_ID_AND_MOBILE_NUMBER = 'Services/Patients.svc/REST/AP_GetPatientInfoByPatientIDandMobileNumber';
-const SEND_ACTIVATION_CODE_FOR_ADVANCE_PAYMENT = 'Services/Authentication.svc/REST/SendActivationCodeForAdvancePayment';
-const CHECK_ACTIVATION_CODE_FOR_ADVANCE_PAYMENT = 'Services/Authentication.svc/REST/CheckActivationCodeForAdvancePayment';
+const GET_PATIENT_AdVANCE_BALANCE_AMOUNT =
+ 'Services/Patients.svc/REST/GetPatientAdvanceBalanceAmount';
+const GET_PATIENT_INFO_BY_ID =
+ 'Services/Doctors.svc/REST/GetPatientInfoByPatientID';
+const GET_PATIENT_INFO_BY_ID_AND_MOBILE_NUMBER =
+ 'Services/Patients.svc/REST/AP_GetPatientInfoByPatientIDandMobileNumber';
+const SEND_ACTIVATION_CODE_FOR_ADVANCE_PAYMENT =
+ 'Services/Authentication.svc/REST/SendActivationCodeForAdvancePayment';
+const CHECK_ACTIVATION_CODE_FOR_ADVANCE_PAYMENT =
+ 'Services/Authentication.svc/REST/CheckActivationCodeForAdvancePayment';
const GET_COVID_DRIVETHRU_PROJECT_LIST = 'Services/Doctors.svc/REST/COVID19_ProjectDriveThroughTestingCenter';
@@ -273,47 +271,54 @@ const GET_COVID_DRIVETHRU_FREE_SLOTS = 'Services/Doctors.svc/REST/COVID19_GetFre
///My Trackers
-const GET_DIABETIC_RESULT_AVERAGE='Services/Patients.svc/REST/Patient_GetDiabeticResultAverage';
-const GET_DIABTEC_RESULT='Services/Patients.svc/REST/Patient_GetDiabtecResults';
-const ADD_DIABTEC_RESULT='Services/Patients.svc/REST/Patient_AddDiabtecResult';
-
-
-const GET_BLOOD_PRESSURE_RESULT_AVERAGE='Services/Patients.svc/REST/Patient_GetBloodPressureResultAverage';
-const GET_BLOOD_PRESSURE_RESULT='Services/Patients.svc/REST/Patient_GetBloodPressureResult';
-const ADD_BLOOD_PRESSURE_RESULT='Services/Patients.svc/REST/Patient_AddBloodPressureResult';
-
-const GET_WEIGHT_PRESSURE_RESULT_AVERAGE='Services/Patients.svc/REST/Patient_GetWeightMeasurementResultAverage';
-const GET_WEIGHT_PRESSURE_RESULT='Services/Patients.svc/REST/Patient_GetWeightMeasurementResult';
-const ADD_WEIGHT_PRESSURE_RESULT='Services/Patients.svc/REST/Patient_AddWeightMeasurementResult';
-
-
-const ADD_ACTIVE_PRESCRIPTIONS_REPORT_BY_PATIENT_ID='Services/Patients.svc/Rest/GetActivePrescriptionReportByPatientID';
-
-const GET_CALL_INFO_HOURS_RESULT = 'Services/Doctors.svc/REST/GetCallInfoHoursResult';
-const GET_CALL_REQUEST_TYPE_LOV = 'Services/Doctors.svc/REST/GetCallRequestType_LOV';
+const GET_DIABETIC_RESULT_AVERAGE =
+ 'Services/Patients.svc/REST/Patient_GetDiabeticResultAverage';
+const GET_DIABTEC_RESULT =
+ 'Services/Patients.svc/REST/Patient_GetDiabtecResults';
+const ADD_DIABTEC_RESULT =
+ 'Services/Patients.svc/REST/Patient_AddDiabtecResult';
+
+const GET_BLOOD_PRESSURE_RESULT_AVERAGE =
+ 'Services/Patients.svc/REST/Patient_GetBloodPressureResultAverage';
+const GET_BLOOD_PRESSURE_RESULT =
+ 'Services/Patients.svc/REST/Patient_GetBloodPressureResult';
+const ADD_BLOOD_PRESSURE_RESULT =
+ 'Services/Patients.svc/REST/Patient_AddBloodPressureResult';
+
+const GET_WEIGHT_PRESSURE_RESULT_AVERAGE =
+ 'Services/Patients.svc/REST/Patient_GetWeightMeasurementResultAverage';
+const GET_WEIGHT_PRESSURE_RESULT =
+ 'Services/Patients.svc/REST/Patient_GetWeightMeasurementResult';
+const ADD_WEIGHT_PRESSURE_RESULT =
+ 'Services/Patients.svc/REST/Patient_AddWeightMeasurementResult';
+
+const ADD_ACTIVE_PRESCRIPTIONS_REPORT_BY_PATIENT_ID =
+ 'Services/Patients.svc/Rest/GetActivePrescriptionReportByPatientID';
+
+const GET_CALL_INFO_HOURS_RESULT =
+ 'Services/Doctors.svc/REST/GetCallInfoHoursResult';
+const GET_CALL_REQUEST_TYPE_LOV =
+ 'Services/Doctors.svc/REST/GetCallRequestType_LOV';
const GET_DOCTOR_RESPONSE = 'Services/Patients.svc/REST/GetDoctorResponse';
const UPDATE_READ_STATUS = 'Services/Patients.svc/REST/UpdateReadStatus';
const INSERT_CALL_INFO = 'Services/Doctors.svc/REST/InsertCallInfo';
const GET_PATIENT_ALLERGIES = 'Services/Patients.svc/REST/GetPatientAllergies';
-
-
-
-
// H2O
-const H2O_GET_USER_PROGRESS = "Services/H2ORemainder.svc/REST/H2O_GetUserProgress";
-const H2O_INSERT_USER_ACTIVITY="Services/H2ORemainder.svc/REST/H2O_InsertUserActivity";
-
-
-
-
+const H2O_GET_USER_PROGRESS =
+ "Services/H2ORemainder.svc/REST/H2O_GetUserProgress";
+const H2O_INSERT_USER_ACTIVITY =
+ "Services/H2ORemainder.svc/REST/H2O_InsertUserActivity";
//E_Referral Services
-const GET_ALL_RELATIONSHIP_TYPES = "Services/Patients.svc/REST/GetAllRelationshipTypes";
-const SEND_ACTIVATION_CODE_FOR_E_REFERRAL = 'Services/Authentication.svc/REST/SendActivationCodeForEReferral';
-const CHECK_ACTIVATION_CODE_FOR_E_REFERRAL = 'Services/Authentication.svc/REST/CheckActivationCodeForEReferral';
+const GET_ALL_RELATIONSHIP_TYPES =
+ "Services/Patients.svc/REST/GetAllRelationshipTypes";
+const SEND_ACTIVATION_CODE_FOR_E_REFERRAL =
+ 'Services/Authentication.svc/REST/SendActivationCodeForEReferral';
+const CHECK_ACTIVATION_CODE_FOR_E_REFERRAL =
+ 'Services/Authentication.svc/REST/CheckActivationCodeForEReferral';
const GET_ALL_CITIES = 'services/Lists.svc/rest/GetAllCities';
const CREATE_E_REFERRAL = "Services/Patients.svc/REST/CreateEReferral";
const GET_E_REFERRALS = "Services/Patients.svc/REST/GetEReferrals";
diff --git a/lib/config/localized_values.dart b/lib/config/localized_values.dart
index b13210a7..81f8a3d4 100644
--- a/lib/config/localized_values.dart
+++ b/lib/config/localized_values.dart
@@ -379,6 +379,16 @@ const Map> localizedValues = {
"ar":
"السماح لتطبيق مجموعة الحبيب الطبية بالوصول إلى موقعك سيساعدك في إظهار المستشفيات وفقًا للأقرب إليك."
},
+
+ "user-view-requester": {
+ "en": "User Wants To View Your Medical File",
+ "ar": "أشخاص يرغبون الاطلاع على ملفك الطبي"
+ },
+ "user-view": {
+ "en": "User Can View Your Medical File",
+ "ar": "أشخاص يمكنهم الاطلاع على ملفك الطبي"
+ },
+
"parking": {"en": "Parking", "ar": "مواقف"},
"alhabiServices": {"en": "HMG Service", "ar": "خدمات الحبيب"},
"parkingTitle": {
diff --git a/lib/config/shared_pref_kay.dart b/lib/config/shared_pref_kay.dart
index 8087a7f1..7422052d 100644
--- a/lib/config/shared_pref_kay.dart
+++ b/lib/config/shared_pref_kay.dart
@@ -14,4 +14,5 @@ const FAMILY_FILE = 'family-file';
const USER_LAT = 'user-lat';
const USER_LONG = 'user-long';
const IS_GO_TO_PARKING = 'IS_GO_TO_PARKING';
+const IS_SEARCH_APPO = 'is-search-appo';
const IS_LIVECARE_APPOINTMENT = 'is_livecare_appointment';
diff --git a/lib/core/service/client/base_app_client.dart b/lib/core/service/client/base_app_client.dart
index 4ad8de79..237245f8 100644
--- a/lib/core/service/client/base_app_client.dart
+++ b/lib/core/service/client/base_app_client.dart
@@ -32,7 +32,9 @@ class BaseAppClient {
var user = await sharedPref.getObject(USER_PROFILE);
if (body.containsKey('SetupID')) {
body['SetupID'] = body.containsKey('SetupID')
- ? body['SetupID'] != null ? body['SetupID'] : SETUP_ID
+ ? body['SetupID'] != null
+ ? body['SetupID']
+ : SETUP_ID
: SETUP_ID;
}
body['VersionID'] = VERSION_ID;
@@ -41,7 +43,9 @@ class BaseAppClient {
body['IPAdress'] = IP_ADDRESS;
body['generalid'] = GENERAL_ID;
body['PatientOutSA'] = body.containsKey('PatientOutSA')
- ? body['PatientOutSA'] != null ? body['PatientOutSA'] : PATIENT_OUT_SA
+ ? body['PatientOutSA'] != null
+ ? body['PatientOutSA']
+ : PATIENT_OUT_SA
: PATIENT_OUT_SA;
if (body.containsKey('isDentalAllowedBackend')) {
@@ -55,30 +59,31 @@ class BaseAppClient {
body['DeviceTypeID'] = DeviceTypeID;
- if(!body.containsKey('IsPublicRequest')) {
+ if (!body.containsKey('IsPublicRequest')) {
body['PatientType'] = body.containsKey('PatientType')
- ? body['PatientType'] != null ? body['PatientType'] : PATIENT_TYPE
+ ? body['PatientType'] != null
+ ? body['PatientType']
+ : PATIENT_TYPE
: PATIENT_TYPE;
body['PatientTypeID'] = body.containsKey('PatientTypeID')
? body['PatientTypeID'] != null
- ? body['PatientTypeID']
- : PATIENT_TYPE_ID
+ ? body['PatientTypeID']
+ : PATIENT_TYPE_ID
: PATIENT_TYPE_ID;
if (user != null) {
body['TokenID'] = token;
body['PatientID'] =
- body['PatientID'] != null ? body['PatientID'] : user['PatientID'];
+ body['PatientID'] != null ? body['PatientID'] : user['PatientID'];
body['PatientOutSA'] = user['OutSA'];
- body['SessionID'] = getSessionId(token);
+ body['SessionID'] = SESSION_ID;//getSessionId(token);
}
}
print("URL : $url");
print("Body : ${json.encode(body)}");
-
if (await Utils.checkConnection()) {
final response = await http.post(url.trim(),
body: json.encode(body),
@@ -139,6 +144,7 @@ class BaseAppClient {
}
String getSessionId(String id) {
- return id.replaceAll(RegExp('/[^a-zA-Z ]'), '');
+ ///return id.replaceAll(RegExp('/[^\w\s]/'), '');
+ // return id.replaceAll(RegExp('/[^a-zA-Z ]'), '');
}
}
diff --git a/lib/main.dart b/lib/main.dart
index ec42e7a3..d8e3307d 100644
--- a/lib/main.dart
+++ b/lib/main.dart
@@ -66,7 +66,8 @@ class MyApp extends StatelessWidget {
hintColor: Colors.grey[400],
disabledColor: Colors.grey[300],
errorColor: Color.fromRGBO(235, 80, 60, 1.0),
- scaffoldBackgroundColor:Hexcolor('#E9E9E9'),// Colors.grey[100],
+ scaffoldBackgroundColor:
+ HexColor('#E9E9E9'), // Colors.grey[100],
textSelectionColor: Color.fromRGBO(80, 100, 253, 0.5),
textSelectionHandleColor: Colors.grey,
canvasColor: Colors.white,
@@ -74,9 +75,8 @@ class MyApp extends StatelessWidget {
highlightColor: Colors.grey[100].withOpacity(0.4),
splashColor: Colors.transparent,
primaryColor: Colors.grey,
- bottomSheetTheme:BottomSheetThemeData(
- backgroundColor: Hexcolor('#E0E0E0')
- ) ,
+ bottomSheetTheme: BottomSheetThemeData(
+ backgroundColor: HexColor('#E0E0E0')),
cursorColor: Colors.grey,
iconTheme: IconThemeData(),
appBarTheme: AppBarTheme(
diff --git a/lib/models/Appointments/DoctorListResponse.dart b/lib/models/Appointments/DoctorListResponse.dart
index 65d28910..4c7241c8 100644
--- a/lib/models/Appointments/DoctorListResponse.dart
+++ b/lib/models/Appointments/DoctorListResponse.dart
@@ -174,7 +174,9 @@ class PatientDoctorAppointmentList {
List patientDoctorAppointmentList = List();
PatientDoctorAppointmentList(
- {this.filterName, this.distanceInKMs, DoctorList patientDoctorAppointment}) {
+ {this.filterName,
+ this.distanceInKMs,
+ DoctorList patientDoctorAppointment}) {
patientDoctorAppointmentList.add(patientDoctorAppointment);
}
}
diff --git a/lib/pages/AlHabibMedicalService/E-Referral/e_referral_index_page.dart b/lib/pages/AlHabibMedicalService/E-Referral/e_referral_index_page.dart
index 00148889..ef0be383 100644
--- a/lib/pages/AlHabibMedicalService/E-Referral/e_referral_index_page.dart
+++ b/lib/pages/AlHabibMedicalService/E-Referral/e_referral_index_page.dart
@@ -17,66 +17,63 @@ import 'e_referral_page.dart';
class EReferralIndexPage extends StatelessWidget {
@override
Widget build(BuildContext context) {
- return AppScaffold(
- isShowAppBar: true,
- appBarTitle: "Service Information",
- body: SingleChildScrollView(
+ return AppScaffold(
+ isShowAppBar: true,
+ appBarTitle: "Service Information",
+ body: SingleChildScrollView(
padding: EdgeInsets.all(12),
- child:
- Column(
- crossAxisAlignment: CrossAxisAlignment.start,
- children: [
- Texts(
- "E-Referral: ",
- fontWeight: FontWeight.normal,
- fontSize: 25,
- color: Hexcolor("#60686b"),
- ),
- SizedBox(
- height: 12,
- ),
- Texts(
- "This service allows you to submit a Referral request from any health care providers either inside or outside the kingdom of Saudi Arabia to any of HMG Hospitals, By filling some of the patient's data and attaching the medical reports, moreover you can track the request status (Under process, Accepted or Rejected)",
- fontWeight: FontWeight.normal,
- fontSize: 17,
- ),
- SizedBox(
- height: 22,
- ),
- Center(
- child: SizedBox(
- height: MediaQuery.of(context).size.height * 0.55,
- width: MediaQuery.of(context).size.width * 0.50,
- child: CarouselSlider(
- imagesUrlList: [
- "https://hmgwebservices.com/Images/MobileApp/images-info-home/referal/en/0.png",
- "https://hmgwebservices.com/Images/MobileApp/images-info-home/referal/en/1.png"
- ],
- ),
- ),
- ),
- SizedBox(
- height: 77,
- ),
- ],
- )
-
- ),
- bottomSheet: Container(
- height: MediaQuery.of(context).size.height * 0.10,
- width: double.infinity,
child: Column(
+ crossAxisAlignment: CrossAxisAlignment.start,
children: [
- Container(
- width: MediaQuery.of(context).size.width * 0.9,
- child: SecondaryButton(
- onTap: ()=> Navigator.push(context, FadePage(page: EReferralPage())),
- label: "E-Referral",
- textColor: Theme.of(context).backgroundColor),
+ Texts(
+ "E-Referral: ",
+ fontWeight: FontWeight.normal,
+ fontSize: 25,
+ color: HexColor("#60686b"),
+ ),
+ SizedBox(
+ height: 12,
+ ),
+ Texts(
+ "This service allows you to submit a Referral request from any health care providers either inside or outside the kingdom of Saudi Arabia to any of HMG Hospitals, By filling some of the patient's data and attaching the medical reports, moreover you can track the request status (Under process, Accepted or Rejected)",
+ fontWeight: FontWeight.normal,
+ fontSize: 17,
+ ),
+ SizedBox(
+ height: 22,
+ ),
+ Center(
+ child: SizedBox(
+ height: MediaQuery.of(context).size.height * 0.55,
+ width: MediaQuery.of(context).size.width * 0.50,
+ child: CarouselSlider(
+ imagesUrlList: [
+ "https://hmgwebservices.com/Images/MobileApp/images-info-home/referal/en/0.png",
+ "https://hmgwebservices.com/Images/MobileApp/images-info-home/referal/en/1.png"
+ ],
+ ),
+ ),
+ ),
+ SizedBox(
+ height: 77,
),
],
- ),
-
- ));
+ )),
+ bottomSheet: Container(
+ height: MediaQuery.of(context).size.height * 0.10,
+ width: double.infinity,
+ child: Column(
+ children: [
+ Container(
+ width: MediaQuery.of(context).size.width * 0.9,
+ child: SecondaryButton(
+ onTap: () => Navigator.push(
+ context, FadePage(page: EReferralPage())),
+ label: "E-Referral",
+ textColor: Theme.of(context).backgroundColor),
+ ),
+ ],
+ ),
+ ));
}
}
diff --git a/lib/pages/AlHabibMedicalService/all_habib_medical_service_page.dart b/lib/pages/AlHabibMedicalService/all_habib_medical_service_page.dart
index 51624d63..f717ba8e 100644
--- a/lib/pages/AlHabibMedicalService/all_habib_medical_service_page.dart
+++ b/lib/pages/AlHabibMedicalService/all_habib_medical_service_page.dart
@@ -17,6 +17,7 @@ import 'package:diplomaticquarterapp/pages/insurance/insurance_update_screen.dar
import 'package:diplomaticquarterapp/pages/livecare/livecare_home.dart';
import 'package:diplomaticquarterapp/pages/medical/medical_profile_page.dart';
import 'package:diplomaticquarterapp/pages/paymentService/payment_service.dart';
+import 'package:diplomaticquarterapp/routes.dart';
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
import 'package:diplomaticquarterapp/widgets/data_display/text.dart';
import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart';
@@ -213,9 +214,8 @@ class _AllHabibMedicalServiceState extends State {
title: TranslationBase.of(context).todoList,
),
ServicesContainer(
- onTap: () => Navigator.push(
- context,
- FadePage(),
+ onTap: () => Navigator.of(context).pushNamed(
+ SYMPTOM_CHECKER,
),
imageLocation: 'assets/images/new-design/body_icon.png',
title: 'Symptom Checker'),
diff --git a/lib/pages/AlHabibMedicalService/h2o/h2o_index_page.dart b/lib/pages/AlHabibMedicalService/h2o/h2o_index_page.dart
index 9ce35d27..68ce1936 100644
--- a/lib/pages/AlHabibMedicalService/h2o/h2o_index_page.dart
+++ b/lib/pages/AlHabibMedicalService/h2o/h2o_index_page.dart
@@ -23,7 +23,7 @@ class H2OPageIndexPage extends StatelessWidget {
"Water Tracker:",
fontWeight: FontWeight.normal,
fontSize: 25,
- color: Hexcolor("#60686b"),
+ color: HexColor("#60686b"),
),
SizedBox(
height: 12,
diff --git a/lib/pages/AlHabibMedicalService/h2o/today_page.dart b/lib/pages/AlHabibMedicalService/h2o/today_page.dart
index 55767e5a..b92efc9e 100644
--- a/lib/pages/AlHabibMedicalService/h2o/today_page.dart
+++ b/lib/pages/AlHabibMedicalService/h2o/today_page.dart
@@ -6,10 +6,11 @@ import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
import 'package:hexcolor/hexcolor.dart';
import 'package:percent_indicator/circular_percent_indicator.dart';
+
class TodayPage extends StatelessWidget {
@override
Widget build(BuildContext context) {
- return BaseView(
+ return BaseView(
onModelReady: (model) => model.getUserProgressForTodayData(),
builder: (_, model, widget) => AppScaffold(
isShowAppBar: false,
@@ -27,11 +28,11 @@ class TodayPage extends StatelessWidget {
animation: true,
animationDuration: 1200,
lineWidth: 15.0,
- percent:model.userProgressData ==null ?0.0:
- (model.userProgressData.percentageConsumed /
- 100) >= 1 ? 1 : (model.userProgressData
- .percentageConsumed /
- 100),
+ percent: model.userProgressData == null
+ ? 0.0
+ : (model.userProgressData.percentageConsumed / 100) >= 1
+ ? 1
+ : (model.userProgressData.percentageConsumed / 100),
//,
center: Center(
child: Column(
@@ -46,13 +47,16 @@ class TodayPage extends StatelessWidget {
SizedBox(
height: 4,
),
- Text(model.userProgressData ==null ?"0.0":
- model.userProgressData.quantityConsumed
- .toString() + 'ml',
+ Text(
+ model.userProgressData == null
+ ? "0.0"
+ : model.userProgressData.quantityConsumed
+ .toString() +
+ 'ml',
style: TextStyle(
fontWeight: FontWeight.bold,
fontSize: 20.0,
- color: Hexcolor("#60BCF9")),
+ color: HexColor("#60BCF9")),
),
SizedBox(
height: 4,
@@ -60,9 +64,7 @@ class TodayPage extends StatelessWidget {
SizedBox(
height: 5,
width: 50,
- child: Container(
-
- ),
+ child: Container(),
),
SizedBox(
height: 4,
@@ -74,23 +76,28 @@ class TodayPage extends StatelessWidget {
SizedBox(
height: 4,
),
- Text(model.userProgressData ==null ?"0.0":
- (model.userProgressData.quantityLimit -
- model.userProgressData
- .quantityConsumed) < 0 ? "0 ml" :
- (model.userProgressData.quantityLimit -
- model.userProgressData
- .quantityConsumed).toString() + ' ml',
+ Text(
+ model.userProgressData == null
+ ? "0.0"
+ : (model.userProgressData.quantityLimit -
+ model.userProgressData
+ .quantityConsumed) <
+ 0
+ ? "0 ml"
+ : (model.userProgressData.quantityLimit -
+ model.userProgressData
+ .quantityConsumed)
+ .toString() +
+ ' ml',
style: TextStyle(
- fontWeight: FontWeight.bold,
- fontSize: 18.0),
+ fontWeight: FontWeight.bold, fontSize: 18.0),
),
],
),
),
circularStrokeCap: CircularStrokeCap.butt,
- backgroundColor: Hexcolor("#D1E3F6"),
- progressColor: Hexcolor("#60BCF9"),
+ backgroundColor: HexColor("#D1E3F6"),
+ progressColor: HexColor("#60BCF9"),
),
),
Row(
@@ -105,9 +112,9 @@ class TodayPage extends StatelessWidget {
height: 30,
width: 70,
decoration: BoxDecoration(
- color: Hexcolor("#D1E3F6"),
- borderRadius: BorderRadius.all(
- Radius.circular(30))),
+ color: HexColor("#D1E3F6"),
+ borderRadius:
+ BorderRadius.all(Radius.circular(30))),
),
),
Text(
@@ -125,9 +132,9 @@ class TodayPage extends StatelessWidget {
height: 30,
width: 70,
decoration: BoxDecoration(
- color: Hexcolor("#60BCF9"),
- borderRadius: BorderRadius.all(
- Radius.circular(30))),
+ color: HexColor("#60BCF9"),
+ borderRadius:
+ BorderRadius.all(Radius.circular(30))),
),
),
Text(
@@ -143,10 +150,7 @@ class TodayPage extends StatelessWidget {
),
SizedBox(
height: 0.5,
- width: MediaQuery
- .of(context)
- .size
- .width,
+ width: MediaQuery.of(context).size.width,
child: Container(
color: Colors.grey,
),
@@ -163,4 +167,3 @@ class TodayPage extends StatelessWidget {
);
}
}
-
diff --git a/lib/pages/AlHabibMedicalService/ health_calculators.dart b/lib/pages/AlHabibMedicalService/ health_calculators.dart
index cdadfe98..d3bd4bed 100644
--- a/lib/pages/AlHabibMedicalService/ health_calculators.dart
+++ b/lib/pages/AlHabibMedicalService/ health_calculators.dart
@@ -1,4 +1,6 @@
import 'package:diplomaticquarterapp/pages/AlHabibMedicalService/health_calculator/body_fat/body_fat.dart';
+import 'package:diplomaticquarterapp/pages/AlHabibMedicalService/health_calculator/bmi_calculator/bmi_calculator.dart';
+import 'package:diplomaticquarterapp/pages/AlHabibMedicalService/health_calculator/calorie_calculator/calorie_calculator.dart';
import 'package:diplomaticquarterapp/pages/AlHabibMedicalService/health_calculator/carbs/carbs.dart';
import 'package:diplomaticquarterapp/pages/AlHabibMedicalService/health_calculator/ovulation_period/ovulation_period.dart';
import 'package:diplomaticquarterapp/widgets/data_display/medical/medical_profile_item.dart';
diff --git a/lib/pages/Blood/my_balance_page.dart b/lib/pages/Blood/my_balance_page.dart
index 07d27e2d..26665c2b 100644
--- a/lib/pages/Blood/my_balance_page.dart
+++ b/lib/pages/Blood/my_balance_page.dart
@@ -39,7 +39,7 @@ class MyBalancePage extends StatelessWidget {
width: double.infinity,
height: 65,
decoration: BoxDecoration(
- color: Hexcolor('#B61422'),
+ color: HexColor('#B61422'),
shape: BoxShape.rectangle,
borderRadius: BorderRadius.circular(7),
),
@@ -97,7 +97,8 @@ class MyBalancePage extends StatelessWidget {
textColor: Colors.white,
label: TranslationBase.of(context).createAdvancedPayment,
onTap: () {
- Navigator.push(context,
+ Navigator.push(
+ context,
//FadePage(page: AdvancePaymentPage()));
FadePage(page: BloodDonationPage()));
},
diff --git a/lib/pages/BookAppointment/DoctorProfile.dart b/lib/pages/BookAppointment/DoctorProfile.dart
index 2c7e723a..d6986f6f 100644
--- a/lib/pages/BookAppointment/DoctorProfile.dart
+++ b/lib/pages/BookAppointment/DoctorProfile.dart
@@ -47,16 +47,16 @@ class _DoctorProfileState extends State
vsync: this,
initialIndex: widget.isOpenAppt == true ? 1 : 0);
- event.controller.stream.listen((p) {
- if (p['clinic_id'] != null &&
- p['doctor_id'] != null &&
- p['project_id'] != null) {
- setState(() {
- // need to take the data from here
- // dropdownValue = p['clinic_id'];
- });
- }
- });
+ // event.controller.stream.listen((p) {
+ // if (p['clinic_id'] != null &&
+ // p['doctor_id'] != null &&
+ // p['project_id'] != null) {
+ // setState(() {
+ // // need to take the data from here
+ // // dropdownValue = p['clinic_id'];
+ // });
+ // }
+ // });
_tabController = new TabController(length: 2, vsync: this);
widget.authUser = new AuthenticatedUser();
widget.doctor.speciality = widget.docProfileList.specialty;
diff --git a/lib/pages/BookAppointment/Search.dart b/lib/pages/BookAppointment/Search.dart
index 08b49462..095d72a6 100644
--- a/lib/pages/BookAppointment/Search.dart
+++ b/lib/pages/BookAppointment/Search.dart
@@ -1,17 +1,18 @@
+import 'package:diplomaticquarterapp/config/config.dart';
import 'package:diplomaticquarterapp/pages/BookAppointment/components/SearchByClinic.dart';
import 'package:diplomaticquarterapp/pages/BookAppointment/components/SearchByDoctor.dart';
import 'package:diplomaticquarterapp/uitl/location_util.dart';
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
import 'package:diplomaticquarterapp/widgets/dialogs/confirm_dialog.dart';
+import 'package:diplomaticquarterapp/widgets/others/arrow_back.dart';
import 'package:diplomaticquarterapp/widgets/others/bottom_bar.dart';
import 'package:flutter/material.dart';
import 'package:geolocator/geolocator.dart';
class Search extends StatefulWidget {
final int type;
-
- Search({this.type = 0});
-
+ final List clnicIds;
+ Search({this.type = 0, this.clnicIds});
@override
_SearchState createState() => _SearchState();
}
@@ -29,24 +30,35 @@ class _SearchState extends State with TickerProviderStateMixin {
@override
Widget build(BuildContext context) {
+ AppGlobal.context = context;
return Scaffold(
- appBar: AppBar(
- bottom: TabBar(
- tabs: [
- Tab(text: TranslationBase.of(context).clinicName),
- Tab(
- text: TranslationBase.of(context).doctorName,
- )
- ],
- controller: _tabController,
- ),
- title: Text(TranslationBase.of(context).bookAppo,
- style: TextStyle(color: Colors.white)),
+ appBar: AppBar(
+ bottom: TabBar(
+ tabs: [
+ Tab(text: TranslationBase.of(context).clinicName),
+ Tab(
+ text: TranslationBase.of(context).doctorName,
+ )
+ ],
+ controller: _tabController,
+ ),
+ title: Text(TranslationBase.of(context).bookAppo,
+ style: TextStyle(color: Colors.white)),
+ leading: Builder(
+ builder: (BuildContext context) {
+ return ArrowBack();
+ },
),
- body: TabBarView(
- physics: NeverScrollableScrollPhysics(),
- children: [SearchByClinic(), SearchByDoctor()],
- controller: _tabController),
- bottomNavigationBar: BottomBarSearch());
+ ),
+ body: TabBarView(
+ physics: NeverScrollableScrollPhysics(),
+ children: [
+ SearchByClinic(
+ clnicIds: widget.clnicIds,
+ ),
+ SearchByDoctor()
+ ],
+ controller: _tabController),
+ );
}
}
diff --git a/lib/pages/BookAppointment/SearchResults.dart b/lib/pages/BookAppointment/SearchResults.dart
index 1ed1b6a0..055b0c41 100644
--- a/lib/pages/BookAppointment/SearchResults.dart
+++ b/lib/pages/BookAppointment/SearchResults.dart
@@ -1,6 +1,6 @@
import 'package:diplomaticquarterapp/models/Appointments/DoctorListResponse.dart';
import 'package:diplomaticquarterapp/pages/BookAppointment/widgets/DoctorView.dart';
-import 'package:diplomaticquarterapp/services/robo_search/event_provider.dart';
+// import 'package:diplomaticquarterapp/services/robo_search/event_provider.dart';
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
import 'package:diplomaticquarterapp/widgets/others/app_expandable_notifier.dart';
import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart';
@@ -19,15 +19,9 @@ class SearchResults extends StatefulWidget {
}
class _SearchResultsState extends State {
- var event = RobotProvider();
+ // var event = RobotProvider();
List tempList = [];
- @override
- void initState() {
- event.controller.stream.listen((p) {});
- super.initState();
- }
-
@override
Widget build(BuildContext context) {
return AppScaffold(
@@ -42,9 +36,14 @@ class _SearchResultsState extends State {
...List.generate(
widget.patientDoctorAppointmentListHospital.length,
(index) => AppExpandableNotifier(
- title: widget
- .patientDoctorAppointmentListHospital[index].filterName + " - " +widget
- .patientDoctorAppointmentListHospital[index].distanceInKMs + " " + TranslationBase.of(context).km,
+ isExpand: index == 1 ? true : false,
+ title: widget.patientDoctorAppointmentListHospital[index]
+ .filterName +
+ " - " +
+ widget.patientDoctorAppointmentListHospital[index]
+ .distanceInKMs +
+ " " +
+ TranslationBase.of(context).km,
bodyWidget: Column(
crossAxisAlignment: CrossAxisAlignment.start,
mainAxisAlignment: MainAxisAlignment.spaceBetween,
diff --git a/lib/pages/BookAppointment/components/SearchByClinic.dart b/lib/pages/BookAppointment/components/SearchByClinic.dart
index 9c4d778f..9d833db1 100644
--- a/lib/pages/BookAppointment/components/SearchByClinic.dart
+++ b/lib/pages/BookAppointment/components/SearchByClinic.dart
@@ -11,10 +11,13 @@ import 'package:diplomaticquarterapp/services/clinic_services/get_clinic_service
import 'package:diplomaticquarterapp/services/robo_search/event_provider.dart';
import 'package:diplomaticquarterapp/uitl/app_toast.dart';
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
+import 'package:diplomaticquarterapp/widgets/card/rounded_container.dart';
import 'package:flutter/material.dart';
import 'package:smart_progress_bar/smart_progress_bar.dart';
class SearchByClinic extends StatefulWidget {
+ final List clnicIds;
+ SearchByClinic({this.clnicIds});
@override
_SearchByClinicState createState() => _SearchByClinicState();
}
@@ -23,11 +26,11 @@ class _SearchByClinicState extends State {
bool nearestAppo = false;
String dropdownValue;
String projectDropdownValue;
- var event = RobotProvider();
+ // var event = RobotProvider();
List clinicsList = [];
List projectsList = [];
bool isMobileAppDentalAllow = false;
-
+ bool isLoaded = false;
@override
void initState() {
WidgetsBinding.instance.addPostFrameCallback((_) => getClinicsList());
@@ -56,40 +59,70 @@ class _SearchByClinicState extends State {
style: TextStyle(fontSize: 16.0, letterSpacing: 0.9)),
],
),
- Container(
- height: 60.0,
- decoration: BoxDecoration(
- color: Colors.white,
- border: Border.all(
- color: Colors.grey[400],
- width: 1.0,
- ),
- borderRadius: BorderRadius.circular(10),
- ),
- // margin: EdgeInsets.fromLTRB(10.0, 20.0, 10.0, 20.0),
- padding: EdgeInsets.all(8.0),
- width: MediaQuery.of(context).size.width,
- child: DropdownButtonHideUnderline(
- child: DropdownButton(
- hint: new Text("Select Clinic"),
- value: dropdownValue,
- items: clinicsList.map((item) {
- return new DropdownMenuItem(
- value: item.clinicID.toString(),
- child: new Text(item.clinicDescription),
- );
- }).toList(),
- onChanged: (newValue) {
- setState(() {
- dropdownValue = newValue;
- if (!isDentalSelectedAndSupported() && !nearestAppo) {
- projectDropdownValue = "";
- getDoctorsList(context);
- }
- });
- },
- ),
- )),
+ widget.clnicIds != null &&
+ widget.clnicIds.length > 1 &&
+ isLoaded == true
+ ? Column(
+ crossAxisAlignment: CrossAxisAlignment.start,
+ children: clinicsList.map((result) {
+ return RoundedContainer(
+ child: ListTile(
+ onTap: () {
+ // setState(() {
+ dropdownValue = result.clinicID.toString();
+ setState(() {
+ if (!isDentalSelectedAndSupported()) {
+ projectDropdownValue = "";
+ getDoctorsList(context);
+ }
+ });
+ },
+ // trailing: Icon(TranslationBase.of(AppGlobal.context)
+ // .locale
+ // .languageCode ==
+ // 'en'
+ // ? Icons.keyboard_arrow_right
+ // : Icons.keyboard_arrow_left),
+ title: Text(result.clinicDescription,
+ style: TextStyle(
+ fontSize: 14.0,
+ color: Colors.grey[700],
+ letterSpacing: 1.0))));
+ }).toList())
+ : Container(
+ height: 60.0,
+ decoration: BoxDecoration(
+ color: Colors.white,
+ border: Border.all(
+ color: Colors.grey[400],
+ width: 1.0,
+ ),
+ borderRadius: BorderRadius.circular(10),
+ ),
+ // margin: EdgeInsets.fromLTRB(10.0, 20.0, 10.0, 20.0),
+ padding: EdgeInsets.all(8.0),
+ width: MediaQuery.of(context).size.width,
+ child: DropdownButtonHideUnderline(
+ child: DropdownButton(
+ hint: new Text("Select Clinic"),
+ value: dropdownValue,
+ items: clinicsList.map((item) {
+ return new DropdownMenuItem(
+ value: item.clinicID.toString(),
+ child: new Text(item.clinicDescription),
+ );
+ }).toList(),
+ onChanged: (newValue) {
+ setState(() {
+ dropdownValue = newValue;
+ if (!isDentalSelectedAndSupported() && !nearestAppo) {
+ projectDropdownValue = "";
+ getDoctorsList(context);
+ }
+ });
+ },
+ ),
+ )),
isDentalSelectedAndSupported() == true || nearestAppo
? Container(
height: 60.0,
@@ -168,6 +201,7 @@ class _SearchByClinicState extends State {
});
print(projectsList.length);
});
+ filterClinic();
} else {}
}).catchError((err) {
print(err);
@@ -254,4 +288,17 @@ class _SearchByClinicState extends State {
getProjectsList();
});
}
+
+ filterClinic() {
+ setState(() {
+ if (widget.clnicIds.length > 0) {
+ clinicsList = clinicsList
+ .where((i) => widget.clnicIds.indexOf(i.clinicID) > -1)
+ .toList();
+ isLoaded = true;
+
+ ///print(clinicsList);
+ }
+ });
+ }
}
diff --git a/lib/pages/BookAppointment/widgets/BranchView.dart b/lib/pages/BookAppointment/widgets/BranchView.dart
index 76741874..4ba5a9d3 100644
--- a/lib/pages/BookAppointment/widgets/BranchView.dart
+++ b/lib/pages/BookAppointment/widgets/BranchView.dart
@@ -27,9 +27,11 @@ class _BranchViewState extends State {
return AppScaffold(
appBarTitle: TranslationBase.of(context).bookAppo,
isShowAppBar: true,
+ isBottomBar: false,
body: new ListView.builder(
itemBuilder: (BuildContext context, int index) {
return new ExpandableListView(
+ isExpanded: index == 0 ? true : false,
result2: widget.result,
resultDistance: widget.resultDistance,
val: index,
@@ -46,9 +48,15 @@ class ExpandableListView extends StatefulWidget {
final List resultDistance;
final List doctorsList2;
final val;
-
+ static int doctorListheight = 0;
+ final bool isExpanded;
const ExpandableListView(
- {Key key, this.result2, this.resultDistance, this.val, this.doctorsList2})
+ {Key key,
+ this.result2,
+ this.resultDistance,
+ this.val,
+ this.doctorsList2,
+ this.isExpanded})
: super(key: key);
@override
@@ -57,9 +65,17 @@ class ExpandableListView extends StatefulWidget {
class _ExpandableListViewState extends State {
bool expandFlag = false;
-
+ @override
+ void initState() {
+ setState(() {
+ expandFlag = widget.isExpanded;
+ setDoctorViewHeight(widget.result2[widget.val].toString());
+ });
+ super.initState();
+ }
@override
Widget build(BuildContext context) {
+
return new Container(
width: MediaQuery.of(context).size.width * 0.6,
margin: EdgeInsets.fromLTRB(20.0, 10.0, 20.0, 0.0),
@@ -109,6 +125,10 @@ class _ExpandableListViewState extends State {
onPressed: () {
setState(() {
expandFlag = !expandFlag;
+ if (expandFlag == true) {
+ setDoctorViewHeight(
+ widget.result2[widget.val].toString());
+ }
});
}),
],
@@ -143,6 +163,11 @@ class _ExpandableListViewState extends State {
);
}
+ setDoctorViewHeight(name) {
+ ExpandableListView.doctorListheight =
+ widget.doctorsList2.where((e) => e.projectName == name).toList().length;
+ }
+
String getProjectDistance(String distance) {
if (distance != "0")
return " - " + distance + " " + TranslationBase.of(context).km;
@@ -150,6 +175,9 @@ class _ExpandableListViewState extends State {
return "";
}
}
+
+ sortByProject() {}
+ sortByClinic() {}
}
class ExpandableContainer extends StatelessWidget {
@@ -172,9 +200,12 @@ class ExpandableContainer extends StatelessWidget {
duration: new Duration(milliseconds: 500),
curve: Curves.easeInOut,
width: screenWidth,
- height: expanded ? MediaQuery.of(context).size.height : collapsedHeight,
+ height: expanded
+ ? (ExpandableListView.doctorListheight * 160).toDouble()
+ : collapsedHeight,
child: new Container(
child: child,
+ padding: EdgeInsets.only(bottom: 30),
decoration: new BoxDecoration(
border: new Border.all(width: 1.0, color: Colors.white)),
),
diff --git a/lib/pages/ContactUs/LiveChat/hospitalsLivechat_page.dart b/lib/pages/ContactUs/LiveChat/hospitalsLivechat_page.dart
index 8e9fe806..5bffe17c 100644
--- a/lib/pages/ContactUs/LiveChat/hospitalsLivechat_page.dart
+++ b/lib/pages/ContactUs/LiveChat/hospitalsLivechat_page.dart
@@ -138,8 +138,7 @@ class _HospitalsLiveChatPageState extends State {
))), //model.cOCItemList[index].cOCTitl
IconButton(
icon: Icon(
- Icons
- .arrow_forward_ios,
+ Icons.arrow_forward_ios,
color:
tappedIndex == index
? Colors.white
diff --git a/lib/pages/ErService/AmbulanceRequestIndexPages/SelectTransportationMethod.dart b/lib/pages/ErService/AmbulanceRequestIndexPages/SelectTransportationMethod.dart
index 436aabe8..59c3b85c 100644
--- a/lib/pages/ErService/AmbulanceRequestIndexPages/SelectTransportationMethod.dart
+++ b/lib/pages/ErService/AmbulanceRequestIndexPages/SelectTransportationMethod.dart
@@ -1,4 +1,7 @@
import 'package:diplomaticquarterapp/core/enum/OrderService.dart';
+import 'package:diplomaticquarterapp/core/enum/OrderService.dart';
+import 'package:diplomaticquarterapp/core/enum/OrderService.dart';
+import 'package:diplomaticquarterapp/core/enum/OrderService.dart';
import 'package:diplomaticquarterapp/core/model/er/PatientER.dart';
import 'package:diplomaticquarterapp/core/model/er/get_all_transportation_method_list_model.dart';
import 'package:diplomaticquarterapp/core/viewModels/er/am_request_view_model.dart';
diff --git a/lib/pages/MyAppointments/MyAppointments.dart b/lib/pages/MyAppointments/MyAppointments.dart
index dc6fc65c..379c6e71 100644
--- a/lib/pages/MyAppointments/MyAppointments.dart
+++ b/lib/pages/MyAppointments/MyAppointments.dart
@@ -1,7 +1,9 @@
+import 'package:diplomaticquarterapp/config/shared_pref_kay.dart';
import 'package:diplomaticquarterapp/models/Appointments/AppoimentAllHistoryResultList.dart';
import 'package:diplomaticquarterapp/pages/MyAppointments/models/AppointmentType.dart';
import 'package:diplomaticquarterapp/pages/MyAppointments/widgets/AppointmentCardView.dart';
import 'package:diplomaticquarterapp/services/appointment_services/GetDoctorsList.dart';
+import 'package:diplomaticquarterapp/uitl/app_shared_preferences.dart';
import 'package:diplomaticquarterapp/uitl/app_toast.dart';
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
import 'package:diplomaticquarterapp/widgets/others/app_expandable_notifier.dart';
@@ -30,7 +32,7 @@ class _MyAppointmentsState extends State
TabController _tabController;
bool isDataLoaded = false;
-
+ var sharedPref = new AppSharedPreferences();
@override
void initState() {
_tabController = new TabController(length: 3, vsync: this);
@@ -203,100 +205,114 @@ class _MyAppointmentsState extends State
});
}
- openAppointmentsTab() {
- if (widget._patientBookedAppointmentListHospital.length != 0) {
+ openAppointmentsTab() async {
+ var flag = await this.sharedPref.getInt(IS_SEARCH_APPO);
+
+ if (flag == 1) {
_tabController.index = 0;
- } else if (widget._patientConfirmedAppointmentListHospital.length != 0) {
+ } else if (flag == 2) {
_tabController.index = 1;
- } else if (widget._patientArrivedAppointmentListHospital.length != 0) {
+ } else if (flag == 3) {
_tabController.index = 2;
- return;
+ } else {
+ if (widget._patientBookedAppointmentListHospital.length != 0) {
+ _tabController.index = 0;
+ } else if (widget._patientConfirmedAppointmentListHospital.length != 0) {
+ _tabController.index = 1;
+ } else if (widget._patientArrivedAppointmentListHospital.length != 0) {
+ _tabController.index = 2;
+ return;
+ }
}
}
Widget getBookedAppointments() {
return Container(
- child: widget.bookedAppoList.length != 0
- ? new ListView.builder(
- itemCount: widget.bookedAppoList.length,
- itemBuilder: (context, i) {
- return AppointmentCard(
- appo: widget.bookedAppoList[i],
- onReloadAppointmentHistory: getPatientAppointmentHistory,
- );
- },
- )
- : Container(
- child: Center(
- child: Column(
- mainAxisAlignment: MainAxisAlignment.center,
- crossAxisAlignment: CrossAxisAlignment.center,
- children: [
- Image.asset(
- "assets/images/new-design/noAppointmentIcon.png"),
- Container(
- margin: EdgeInsets.only(top: 10.0),
- child: Text(TranslationBase.of(context).noBookedAppointments,
- style: TextStyle(
- fontSize: 16.0,
- )),
- ),
- Container(
- margin: EdgeInsets.only(top: 10.0),
- child: Container(
- child: widget.bookedAppoList.length != 0
- ? SingleChildScrollView(
- physics: BouncingScrollPhysics(),
- child: Column(
- children: [
- ...List.generate(
- widget._patientBookedAppointmentListHospital.length,
+ child: widget.bookedAppoList.length != 0
+ ? new ListView.builder(
+ itemCount: widget.bookedAppoList.length,
+ itemBuilder: (context, i) {
+ return AppointmentCard(
+ appo: widget.bookedAppoList[i],
+ onReloadAppointmentHistory: getPatientAppointmentHistory,
+ );
+ },
+ )
+ : Container(
+ child: Center(
+ child: Column(
+ mainAxisAlignment: MainAxisAlignment.center,
+ crossAxisAlignment: CrossAxisAlignment.center,
+ children: [
+ // Image.asset(
+ // "assets/images/new-design/noAppointmentIcon.png"),
+ // Container(
+ // margin: EdgeInsets.only(top: 10.0),
+ // child: Text(TranslationBase.of(context).noBookedAppointments,
+ // style: TextStyle(
+ // fontSize: 16.0,
+ // )),
+ // ),
+ Container(
+ margin: EdgeInsets.only(top: 10.0),
+ child: Container(
+ child: widget.bookedAppoList.length != 0
+ ? SingleChildScrollView(
+ physics: BouncingScrollPhysics(),
+ child: Column(
+ children: [
+ ...List.generate(
+ widget._patientBookedAppointmentListHospital
+ .length,
(index) => AppExpandableNotifier(
- title: widget
- ._patientBookedAppointmentListHospital[index]
- .filterName,
- bodyWidget: Column(
- crossAxisAlignment: CrossAxisAlignment.start,
- mainAxisAlignment: MainAxisAlignment.spaceBetween,
- children: widget
- ._patientBookedAppointmentListHospital[index]
- .patientDoctorAppointmentList
- .map((doctor) {
- return AppointmentCard(
- appo: doctor,
- onReloadAppointmentHistory:
- getPatientAppointmentHistory,
- );
- }).toList(),
- )),
- )
- ],
- ),
- )
- : Container(
- child: Center(
- child: Column(
- mainAxisAlignment: MainAxisAlignment.center,
- crossAxisAlignment: CrossAxisAlignment.center,
- children: [
- Image.asset(
- "assets/images/new-design/noAppointmentIcon.png"),
- Container(
- margin: EdgeInsets.only(top: 10.0),
- child: Text("No Booked Appointments",
- style: TextStyle(
- fontSize: 16.0,
- )),
+ title: widget
+ ._patientBookedAppointmentListHospital[
+ index]
+ .filterName,
+ bodyWidget: Column(
+ crossAxisAlignment:
+ CrossAxisAlignment.start,
+ mainAxisAlignment:
+ MainAxisAlignment.spaceBetween,
+ children: widget
+ ._patientBookedAppointmentListHospital[
+ index]
+ .patientDoctorAppointmentList
+ .map((doctor) {
+ return AppointmentCard(
+ appo: doctor,
+ onReloadAppointmentHistory:
+ getPatientAppointmentHistory,
+ );
+ }).toList(),
+ )),
+ )
+ ],
+ ),
+ )
+ : Container(
+ child: Center(
+ child: Column(
+ mainAxisAlignment: MainAxisAlignment.center,
+ crossAxisAlignment: CrossAxisAlignment.center,
+ children: [
+ Image.asset(
+ "assets/images/new-design/noAppointmentIcon.png"),
+ Container(
+ margin: EdgeInsets.only(top: 10.0),
+ child: Text("No Booked Appointments",
+ style: TextStyle(
+ fontSize: 16.0,
+ )),
+ ),
+ ],
),
- ],
+ ),
),
- ),
- ),
- ),
- )
- ],
-
- ))));
+ ),
+ )
+ ],
+ ))));
}
Widget getConfirmedAppointments() {
@@ -341,7 +357,8 @@ class _MyAppointmentsState extends State
Image.asset("assets/images/new-design/noAppointmentIcon.png"),
Container(
margin: EdgeInsets.only(top: 10.0),
- child: Text(TranslationBase.of(context).noConfirmedAppointments ,
+ child: Text(
+ TranslationBase.of(context).noConfirmedAppointments,
style: TextStyle(
fontSize: 16.0,
)),
@@ -363,23 +380,24 @@ class _MyAppointmentsState extends State
...List.generate(
widget._patientArrivedAppointmentListHospital.length,
(index) => AppExpandableNotifier(
- title: widget
+ title: widget
+ ._patientArrivedAppointmentListHospital[index]
+ .filterName,
+ bodyWidget: Column(
+ crossAxisAlignment: CrossAxisAlignment.start,
+ mainAxisAlignment: MainAxisAlignment.spaceBetween,
+ children: widget
._patientArrivedAppointmentListHospital[index]
- .filterName,
- bodyWidget: Column(
- crossAxisAlignment: CrossAxisAlignment.start,
- mainAxisAlignment: MainAxisAlignment.spaceBetween,
- children: widget
- ._patientArrivedAppointmentListHospital[index]
- .patientDoctorAppointmentList
- .map((doctor) {
- return AppointmentCard(
- appo: doctor,
- onReloadAppointmentHistory:
- getPatientAppointmentHistory,
- );
- }).toList(),
- )),
+ .patientDoctorAppointmentList
+ .map((doctor) {
+ return AppointmentCard(
+ appo: doctor,
+ onReloadAppointmentHistory:
+ getPatientAppointmentHistory,
+ );
+ }).toList(),
+ ),
+ ),
)
],
),
@@ -394,10 +412,11 @@ class _MyAppointmentsState extends State
Image.asset("assets/images/new-design/noAppointmentIcon.png"),
Container(
margin: EdgeInsets.only(top: 10.0),
- child: Text(TranslationBase.of(context).noArrivedAppointments,
- style: TextStyle(
- fontSize: 16.0,
- )),
+ child:
+ Text(TranslationBase.of(context).noArrivedAppointments,
+ style: TextStyle(
+ fontSize: 16.0,
+ )),
),
],
),
diff --git a/lib/pages/MyAppointments/widgets/AppointmentCardView.dart b/lib/pages/MyAppointments/widgets/AppointmentCardView.dart
index 2e5c88b0..71bde484 100644
--- a/lib/pages/MyAppointments/widgets/AppointmentCardView.dart
+++ b/lib/pages/MyAppointments/widgets/AppointmentCardView.dart
@@ -24,7 +24,7 @@ class _ApointmentCardState extends State {
navigateToAppointmentDetails(context, widget.appo);
},
child: Card(
- margin: EdgeInsets.fromLTRB(10.0, 16.0, 10.0, 8.0),
+ // margin: EdgeInsets.fromLTRB(10.0, 16.0, 10.0, 8.0),
color: Colors.white,
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(10),
@@ -95,7 +95,8 @@ class _ApointmentCardState extends State {
emptyIcon: Icons.star,
),
Container(
- transform: Matrix4.translationValues(15.0, -40.0, 0.0),
+ transform:
+ Matrix4.translationValues(15.0, -40.0, 0.0),
child: Image.asset(
"assets/images/new-design/arrow.png",
width: 25.0,
diff --git a/lib/pages/family/my-family.dart b/lib/pages/family/my-family.dart
index b2757514..b4024b0a 100644
--- a/lib/pages/family/my-family.dart
+++ b/lib/pages/family/my-family.dart
@@ -1,114 +1,358 @@
import 'package:diplomaticquarterapp/config/size_config.dart';
import 'package:diplomaticquarterapp/models/Authentication/check_activation_code_response.dart';
import 'package:diplomaticquarterapp/models/FamilyFiles/GetAllSharedRecordByStatusResponse.dart';
+import 'package:diplomaticquarterapp/pages/BookAppointment/widgets/BranchView.dart';
import 'package:diplomaticquarterapp/services/family_files/family_files_provider.dart';
import 'package:diplomaticquarterapp/uitl/app_shared_preferences.dart';
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
import 'package:diplomaticquarterapp/uitl/utils.dart';
+import 'package:diplomaticquarterapp/widgets/card/rounded_container.dart';
import 'package:diplomaticquarterapp/widgets/dialogs/confirm_dialog.dart';
import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart';
+import 'package:diplomaticquarterapp/widgets/others/bottom_bar.dart';
import 'package:diplomaticquarterapp/widgets/progress_indicator/app_circular_progress_Indeicator.dart';
+import 'package:diplomaticquarterapp/widgets/text/app_texts_widget.dart';
import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
import 'package:diplomaticquarterapp/widgets/buttons/defaultButton.dart';
import 'package:diplomaticquarterapp/config/shared_pref_kay.dart';
import 'package:diplomaticquarterapp/routes.dart';
-class MyFamily extends StatelessWidget {
- //bool isLoading = true;
+class MyFamily extends StatefulWidget {
+ @override
+ _MyFamily createState() => _MyFamily();
+}
+
+class _MyFamily extends State with TickerProviderStateMixin {
final familyFileProvider = FamilyFilesProvider();
AppSharedPreferences sharedPref = new AppSharedPreferences();
var userID;
+ TabController _tabController;
+
+ @override
+ void initState() {
+ _tabController = new TabController(length: 2, vsync: this, initialIndex: 0);
+
+ super.initState();
+ }
+ bool expandFlag = false;
Widget build(BuildContext context) {
- return AppScaffold(
- appBarTitle: TranslationBase.of(context).myFamilyFiles,
- isShowAppBar: true,
- body: DefaultTabController(
- length: 2,
- child: SingleChildScrollView(
- padding: EdgeInsets.all(20),
- child: Container(
- height: SizeConfig.realScreenHeight,
- width: SizeConfig.realScreenWidth,
- child: Stack(
- children: [
- TabBar(
- indicatorColor: Colors.red,
- tabs: [
- Padding(
- padding: EdgeInsets.all(6),
- child:
- Text(TranslationBase.of(context).family)),
- Padding(
- padding: EdgeInsets.all(6),
- child:
- Text(TranslationBase.of(context).request)),
- ],
- ),
- TabBarView(
- children: [
- myFamilyDetails(context),
- myFamilyRequest(context)
- ],
- )
- ],
- )))));
+ return Scaffold(
+ appBar: AppBar(
+ bottom: TabBar(
+ indicatorColor: Colors.red,
+ tabs: [
+ Padding(
+ padding: EdgeInsets.all(6),
+ child: AppText(
+ TranslationBase.of(context).family,
+ color: Colors.white,
+ )),
+ Padding(
+ padding: EdgeInsets.all(6),
+ child: AppText(
+ TranslationBase.of(context).request,
+ color: Colors.white,
+ )),
+ ],
+ controller: _tabController,
+ ),
+ title: AppText(TranslationBase.of(context).myFamilyFiles,
+ color: Colors.white)),
+ body: TabBarView(
+ // physics: NeverScrollableScrollPhysics(),
+ children: [myFamilyDetails(context), myFamilyRequest(context)],
+ controller: _tabController),
+ bottomNavigationBar: BottomBarSearch());
+
+ // AppScaffold(
+ // appBarTitle: TranslationBase.of(context).myFamilyFiles,
+ // isShowAppBar: true,
+ // body: SingleChildScrollView(
+ // child: Container(
+ // height: SizeConfig.screenHeight,
+ // width: SizeConfig.realScreenWidth,
+ // padding: EdgeInsets.all(20),
+ // child: Stack(
+ // children: [
+ // TabBar(
+ // controller: _tabController,
+ // indicatorColor: Colors.red,
+ // tabs: [
+ // Padding(
+ // padding: EdgeInsets.all(6),
+ // child: Text(TranslationBase.of(context).family)),
+ // Padding(
+ // padding: EdgeInsets.all(6),
+ // child: Text(TranslationBase.of(context).request)),
+ // ],
+ // ),
+ // TabBarView(
+ // controller: _tabController,
+ // children: [
+ // myFamilyDetails(context),
+ // myFamilyRequest(context)
+ // ],
+ // )
+ // ],
+ // ))));
}
Widget myFamilyDetails(context) {
- return // Padding(
- //padding: EdgeInsets.only(top: 50),
- //child:
- Column(
- // mainAxisAlignment: MainAxisAlignment.start,
- children: [
- Expanded(
- flex: 3,
- child: FutureBuilder(
- future: getFamilyFiles(), // async work
- builder: (BuildContext context,
- AsyncSnapshot snapshot) {
- switch (snapshot.connectionState) {
- case ConnectionState.waiting:
- return Padding(
- padding: EdgeInsets.only(top: 50),
- child: Text('Loading....'));
- default:
- if (snapshot.hasError)
- return Padding(
- padding: EdgeInsets.all(10),
- child: Text(snapshot.error));
- else
+ return Container(
+ height: MediaQuery.of(context).size.height,
+ margin: EdgeInsets.fromLTRB(20.0, 0, 20.0, 0.0),
+ child: Column(
+ children: [
+ Expanded(
+ flex: 4,
+ child: FutureBuilder(
+ future: getFamilyFiles(), // async work
+ builder: (BuildContext context,
+ AsyncSnapshot
+ snapshot) {
+ switch (snapshot.connectionState) {
+ case ConnectionState.waiting:
return Padding(
padding: EdgeInsets.only(top: 50),
- child: Column(children: [
- Row(
- mainAxisAlignment: MainAxisAlignment.spaceBetween,
- children: [
- Expanded(
- flex: 3,
- child: Text(
- TranslationBase.of(context).request)),
- Expanded(
- flex: 2,
- child: Text(
- TranslationBase.of(context).switchUser,
- )),
- Expanded(
- flex: 1,
- child: Text(
- TranslationBase.of(context).deleteView,
- )),
+ child: Text('Loading....'));
+ default:
+ if (snapshot.hasError)
+ return Padding(
+ padding: EdgeInsets.all(10),
+ child: Text("No data found"));
+ else
+ return Padding(
+ padding: EdgeInsets.only(top: 50),
+ child: Column(children: [
+ Row(
+ mainAxisAlignment:
+ MainAxisAlignment.spaceBetween,
+ children: [
+ Expanded(
+ flex: 3,
+ child: Text(
+ TranslationBase.of(context).request)),
+ Expanded(
+ flex: 2,
+ child: Text(
+ TranslationBase.of(context).switchUser,
+ )),
+ Expanded(
+ flex: 1,
+ child: Text(
+ TranslationBase.of(context).deleteView,
+ )),
+ ],
+ ),
+ Column(
+ mainAxisAlignment: MainAxisAlignment.start,
+ children: snapshot
+ .data.getAllSharedRecordsByStatusList
+ .map((result) {
+ return result.status == 3
+ ? Padding(
+ padding: EdgeInsets.all(10),
+ child: Row(
+ children: [
+ Expanded(
+ flex: 3,
+ child: Text(
+ result.patientName)),
+ Expanded(
+ flex: 2,
+ child: IconButton(
+ icon: Icon(Icons.group),
+ color: Colors.black,
+ onPressed: () {
+ switchUser(
+ result, context);
+ },
+ )),
+ Expanded(
+ flex: 1,
+ child: IconButton(
+ icon: Icon(
+ Icons.delete,
+ color: Colors.black,
+ ),
+ onPressed: () {
+ deleteFamily(
+ result, context);
+ },
+ )),
+ ],
+ ))
+ : SizedBox();
+ }).toList())
+ ]));
+ }
+ },
+ ),
+ ),
+ Expanded(
+ flex: 1,
+ child: Column(
+ mainAxisAlignment: MainAxisAlignment.end,
+ children: [
+ Row(
+ children: [
+ Expanded(
+ child: DefaultButton(
+ TranslationBase.of(context).addFamilyMember,
+ () => {
+ Navigator.of(context)
+ .pushNamed(ADD_FAMILY_MEMBER_TYPE)
+ },
+ color: Colors.grey[900],
+ textColor: Colors.white,
+ ))
+ ],
+ ),
+ ],
+ ),
+ )
+ ],
+ ));
+ }
+
+ Widget myFamilyRequest(context) {
+ return Padding(
+ padding: const EdgeInsets.symmetric(horizontal: 10.0),
+ child: Column(
+ children: [
+ // SizedBox(height: 20.0),
+ RoundedContainer(
+ child: ExpansionTile(
+ title: Text(
+ TranslationBase.of(context).userViewRequest,
+ style: TextStyle(fontSize: 18.0, fontWeight: FontWeight.bold),
+ ),
+ children: [
+ FutureBuilder(
+ future: getUserViewRequest(), // async work
+ builder: (BuildContext context,
+ AsyncSnapshot snapshot) {
+ switch (snapshot.connectionState) {
+ case ConnectionState.waiting:
+ return Padding(
+ padding: EdgeInsets.only(top: 50),
+ child: Text('Loading....'));
+ default:
+ if (snapshot.hasError)
+ return Padding(
+ padding: EdgeInsets.all(10),
+ child: Text('No data found'));
+ else
+ return Column(
+ children: [
+ Row(
+ mainAxisAlignment:
+ MainAxisAlignment.spaceBetween,
+ children: [
+ Expanded(
+ flex: 3,
+ child: Text(TranslationBase.of(context)
+ .request)),
+ Expanded(
+ flex: 2,
+ child: Text(
+ TranslationBase.of(context)
+ .switchUser,
+ )),
+ Expanded(
+ flex: 1,
+ child: Text(
+ TranslationBase.of(context)
+ .deleteView,
+ )),
+ ],
+ ),
+ Column(children: [
+ Row(children: [
+ Expanded(flex: 3, child: AppText('Name')),
+ Expanded(flex: 1, child: AppText('Allow')),
+ Expanded(flex: 1, child: AppText('Reject')),
+ ]),
+ Column(
+ children: snapshot
+ .data['GetAllPendingRecordsList']
+ .map((result) {
+ return Padding(
+ padding: EdgeInsets.all(10),
+ child: Row(
+ children: [
+ Expanded(
+ flex: 3,
+ child:
+ Text(result.patientName)),
+ Expanded(
+ flex: 1,
+ child: IconButton(
+ icon: Icon(
+ Icons.check_circle,
+ color: Colors.black,
+ ),
+ onPressed: () {
+ acceptRequest(
+ result, context);
+ },
+ )),
+ Expanded(
+ flex: 1,
+ child: IconButton(
+ icon: Icon(
+ Icons.delete,
+ color: Colors.black,
+ ),
+ onPressed: () {
+ deleteRequest(
+ result, context);
+ },
+ ))
+ ],
+ ));
+ }).toList())
+ ])
],
- ),
- Column(
- mainAxisAlignment: MainAxisAlignment.start,
- children: snapshot
- .data.getAllSharedRecordsByStatusList
- .map((result) {
- return result.status == 3
- ? Padding(
+ );
+ }
+ })
+ ],
+ ),
+ ),
+ RoundedContainer(
+ child: ExpansionTile(
+ title: Text(
+ TranslationBase.of(context).sentRequest,
+ style: TextStyle(fontSize: 18.0, fontWeight: FontWeight.bold),
+ ),
+ children: [
+ FutureBuilder(
+ future: getSentRequest(), // async work
+ builder: (BuildContext context,
+ AsyncSnapshot
+ snapshot) {
+ switch (snapshot.connectionState) {
+ case ConnectionState.waiting:
+ return Padding(
+ padding: EdgeInsets.only(top: 50),
+ child: Text('Loading....'));
+ default:
+ if (snapshot.hasError)
+ return Padding(
+ padding: EdgeInsets.all(10),
+ child: Text('No data found'));
+ else
+ return SingleChildScrollView(
+ child: Container(
+ height: SizeConfig.screenHeight * .3,
+ child: ListView(
+ children: snapshot
+ .data.getAllSharedRecordsByStatusList
+ .map((result) {
+ return Padding(
padding: EdgeInsets.all(10),
child: Row(
children: [
@@ -118,61 +362,102 @@ class MyFamily extends StatelessWidget {
Text(result.patientName)),
Expanded(
flex: 2,
- child: IconButton(
- icon: Icon(Icons.group),
- color: Colors.black,
- onPressed: () {
- switchUser(
- result, context);
- },
- )),
- Expanded(
- flex: 1,
- child: IconButton(
- icon: Icon(
- Icons.delete,
- color: Colors.black,
- ),
- onPressed: () {
- deleteFamily(
- result, context);
- },
+ child: AppText(
+ result.statusDescription,
+ color: Colors.red,
)),
],
- ))
- : SizedBox();
+ ));
+ }).toList(),
+ )));
+ }
+ })
+ ],
+ )),
+ RoundedContainer(
+ child: ExpansionTile(
+ title: Text(
+ TranslationBase.of(context).userView,
+ style: TextStyle(fontSize: 18.0, fontWeight: FontWeight.bold),
+ ),
+ children: [
+ FutureBuilder(
+ future: getUserViewRequest(), // async work
+ builder:
+ (BuildContext context, AsyncSnapshot snapshot) {
+ switch (snapshot.connectionState) {
+ case ConnectionState.waiting:
+ return Padding(
+ padding: EdgeInsets.only(top: 50),
+ child: Text('Loading....'));
+ default:
+ if (snapshot.hasError)
+ return Padding(
+ padding: EdgeInsets.all(10),
+ child: Text('No data found'));
+ else
+ return Column(
+ children: [
+ Row(
+ mainAxisAlignment:
+ MainAxisAlignment.spaceBetween,
+ children: [
+ Expanded(
+ flex: 3,
+ child: Text(
+ TranslationBase.of(context).request)),
+ Expanded(
+ flex: 2,
+ child: Text(
+ TranslationBase.of(context).switchUser,
+ )),
+ Expanded(
+ flex: 1,
+ child: Text(
+ TranslationBase.of(context).deleteView,
+ )),
+ ],
+ ),
+ Column(children: [
+ Row(children: [
+ Expanded(flex: 3, child: AppText('Name')),
+ Expanded(flex: 1, child: AppText('Delete')),
+ ]),
+ Column(
+ children: snapshot
+ .data['GetAllPendingRecordsList']
+ .map((result) {
+ return Padding(
+ padding: EdgeInsets.all(10),
+ child: Row(
+ children: [
+ Expanded(
+ flex: 3,
+ child: Text(result.patientName)),
+ Expanded(
+ flex: 1,
+ child: IconButton(
+ icon: Icon(
+ Icons.delete,
+ color: Colors.black,
+ ),
+ onPressed: () {
+ deleteRequest(
+ result, context);
+ },
+ )),
+ ],
+ ));
}).toList())
- ]));
- }
- },
- )),
- Expanded(
- flex: 1,
- child: Column(
- children: [
- Row(
- children: [
- Expanded(
- child: DefaultButton(
- TranslationBase.of(context).addFamilyMember,
- () => {
- Navigator.of(context).pushNamed(ADD_FAMILY_MEMBER_TYPE)
- },
- color: Colors.grey[900],
- textColor: Colors.white,
- ))
- ],
- ),
- ],
- ))
- ],
- );
- }
-
- addMember() {}
- Widget myFamilyRequest(context) {
- return Column(
- children: [],
+ ])
+ ],
+ );
+ }
+ })
+ ],
+ ))
+ ],
+ ),
);
}
@@ -186,6 +471,16 @@ class MyFamily extends StatelessWidget {
}
}
+ Future getUserViewRequest() async {
+ var user = await sharedPref.getObject(USER_PROFILE);
+ return familyFileProvider.getUserViewRequest(user['PatientID']);
+ }
+
+ Future getSentRequest() async {
+ // var user = await sharedPref.getObject(USER_PROFILE);
+ return familyFileProvider.getUserSentRequest();
+ }
+
deleteFamily(family, context) {
ConfirmDialog dialog = new ConfirmDialog(
context: context,
@@ -236,4 +531,7 @@ class MyFamily extends StatelessWidget {
HOME,
);
}
+
+ deleteRequest(result, context) {}
+ acceptRequest(result, context) {}
}
diff --git a/lib/pages/feedback/feedback_home_page.dart b/lib/pages/feedback/feedback_home_page.dart
index 68f0bfab..d7c7361f 100644
--- a/lib/pages/feedback/feedback_home_page.dart
+++ b/lib/pages/feedback/feedback_home_page.dart
@@ -33,6 +33,7 @@ class _FeedbackHomePageState extends State
Widget build(BuildContext context) {
return AppScaffold(
isShowAppBar: true,
+ isBottomBar: false,
appBarTitle: 'Feedback',
body: Scaffold(
extendBodyBehindAppBar: true,
@@ -62,8 +63,7 @@ class _FeedbackHomePageState extends State
decoration: BoxDecoration(
border: Border(
bottom: BorderSide(
- color: Theme.of(context).dividerColor,
- width: 0.7),
+ color: Theme.of(context).dividerColor, width: 0.7),
),
color: Colors.white),
child: Center(
@@ -75,7 +75,7 @@ class _FeedbackHomePageState extends State
indicatorColor: Colors.red[800],
labelColor: Theme.of(context).primaryColor,
labelPadding:
- EdgeInsets.only(top: 4.0, left: 18.0, right: 18.0),
+ EdgeInsets.only(top: 4.0, left: 18.0, right: 18.0),
unselectedLabelColor: Colors.grey[800],
tabs: [
Container(
@@ -104,10 +104,7 @@ class _FeedbackHomePageState extends State
child: TabBarView(
physics: BouncingScrollPhysics(),
controller: _tabController,
- children: [
- SendFeedbackPage(),
- StatusFeedbackPage()
- ],
+ children: [SendFeedbackPage(), StatusFeedbackPage()],
),
)
],
diff --git a/lib/pages/landing/home_page.dart b/lib/pages/landing/home_page.dart
index 6ce96bc9..ebb0305a 100644
--- a/lib/pages/landing/home_page.dart
+++ b/lib/pages/landing/home_page.dart
@@ -208,7 +208,7 @@ class _HomePageState extends State {
width: double.infinity,
height: 125,
decoration: BoxDecoration(
- color: Hexcolor('#A59E9E'),
+ color: HexColor('#A59E9E'),
shape: BoxShape.rectangle,
border: Border.all(
color: Colors.transparent, width: 0.5),
@@ -254,7 +254,7 @@ class _HomePageState extends State {
width: 90,
height: 30,
decoration: BoxDecoration(
- color: Hexcolor('#D81A2E'),
+ color: HexColor('#D81A2E'),
shape: BoxShape.rectangle,
border: Border.all(
color: Colors.transparent,
@@ -281,7 +281,7 @@ class _HomePageState extends State {
width: double.infinity,
height: 130,
decoration: BoxDecoration(
- color: Hexcolor('#A59E9E'),
+ color: HexColor('#A59E9E'),
shape: BoxShape.rectangle,
border: Border.all(
color: Colors.transparent, width: 0.5),
@@ -341,7 +341,7 @@ class _HomePageState extends State {
width: 90,
height: 30,
decoration: BoxDecoration(
- color: Hexcolor('#D81A2E'),
+ color: HexColor('#D81A2E'),
shape: BoxShape.rectangle,
border: Border.all(
color: Colors.transparent,
@@ -449,7 +449,7 @@ class _HomePageState extends State {
height: 50,
),
SizedBox(
- height: 13.5,
+ height: 3,
),
Texts(
TranslationBase.of(context)
@@ -486,7 +486,7 @@ class _HomePageState extends State {
textAlign: TextAlign.center,
color: Colors.white,
bold: true,
- fontSize: SizeConfig.textMultiplier * 2.0,
+ fontSize: SizeConfig.textMultiplier * 1.7,
)
],
),
@@ -507,21 +507,21 @@ class _HomePageState extends State {
height: 50,
),
SizedBox(
- height: 15,
+ height: 3,
),
Texts(
TranslationBase.of(context).emergencyService,
textAlign: TextAlign.center,
color: Colors.white,
bold: true,
- fontSize: SizeConfig.textMultiplier * 2.0,
+ fontSize: SizeConfig.textMultiplier * 1.7,
)
],
),
),
),
height: MediaQuery.of(context).size.width * 0.4,
- color: Hexcolor("#747C80"),
+ color: HexColor("#747C80"),
imageName: 'emergency_service_image.png',
),
],
@@ -550,7 +550,7 @@ class _HomePageState extends State {
height: 55,
),
SizedBox(
- height: 15,
+ height: 5,
),
Texts(
TranslationBase.of(context)
@@ -558,7 +558,7 @@ class _HomePageState extends State {
textAlign: TextAlign.center,
color: Colors.black87,
bold: false,
- fontSize: SizeConfig.textMultiplier * 2,
+ fontSize: SizeConfig.textMultiplier * 1.7,
)
],
),
@@ -582,7 +582,7 @@ class _HomePageState extends State {
height: 55,
),
SizedBox(
- height: 15,
+ height: 10,
),
Texts(
TranslationBase.of(context)
@@ -590,7 +590,7 @@ class _HomePageState extends State {
textAlign: TextAlign.center,
color: Colors.black87,
bold: false,
- fontSize: SizeConfig.textMultiplier * 2,
+ fontSize: SizeConfig.textMultiplier * 1.7,
)
],
),
@@ -622,7 +622,7 @@ class _HomePageState extends State {
height: 50,
),
SizedBox(
- height: 15,
+ height: 10,
),
Texts(
TranslationBase.of(context)
@@ -630,7 +630,7 @@ class _HomePageState extends State {
textAlign: TextAlign.center,
color: Colors.black87,
bold: false,
- fontSize: SizeConfig.textMultiplier * 2.0,
+ fontSize: SizeConfig.textMultiplier * 1.7,
)
],
),
@@ -648,7 +648,7 @@ class _HomePageState extends State {
),
),
SizedBox(
- height: 8,
+ height: 5,
),
Container(
margin: EdgeInsets.only(left: 15, right: 15),
@@ -686,7 +686,7 @@ class _HomePageState extends State {
),
),
height: 100,
- imageName: 'hmg_services_bg .png',
+ imageName: 'hmg_services_bg.png',
opacity: 0.5,
color: Colors.grey[700],
width: MediaQuery.of(context).size.width * 0.45,
@@ -788,7 +788,9 @@ class DashboardItem extends StatelessWidget {
: MediaQuery.of(context).size.height * 0.35,
decoration: BoxDecoration(
color: !hasBorder
- ? color != null ? color : Hexcolor('#050705').withOpacity(opacity)
+ ? color != null
+ ? color
+ : HexColor('#050705').withOpacity(opacity)
: Colors.white,
borderRadius: BorderRadius.circular(6.0),
border: hasBorder
@@ -796,7 +798,7 @@ class DashboardItem extends StatelessWidget {
: Border.all(width: 0.0, color: Colors.transparent),
image: imageName != null
? DecorationImage(
- image: AssetImage('assets/images/$imageName'),
+ image: ExactAssetImage('assets/images/$imageName'),
fit: BoxFit.cover,
colorFilter: new ColorFilter.mode(
Colors.black.withOpacity(0.2), BlendMode.dstIn),
diff --git a/lib/pages/landing/landing_page.dart b/lib/pages/landing/landing_page.dart
index 0c6a2144..dcfa3ba8 100644
--- a/lib/pages/landing/landing_page.dart
+++ b/lib/pages/landing/landing_page.dart
@@ -13,6 +13,7 @@ import 'package:diplomaticquarterapp/pages/livecare/incoming_call.dart';
import 'package:diplomaticquarterapp/pages/medical/medical_profile_page.dart';
import 'package:diplomaticquarterapp/pages/medical/my_admissions_page.dart';
import 'package:diplomaticquarterapp/services/authentication/auth_provider.dart';
+import 'package:diplomaticquarterapp/services/robo_search/event_provider.dart';
import 'package:diplomaticquarterapp/uitl/CalendarUtils.dart';
import 'package:diplomaticquarterapp/uitl/LocalNotification.dart';
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
@@ -23,6 +24,7 @@ import 'package:firebase_messaging/firebase_messaging.dart';
import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
import 'package:flutter_local_notifications/flutter_local_notifications.dart';
+import 'package:flutter_svg/svg.dart';
import 'package:permission_handler/permission_handler.dart';
import 'package:provider/provider.dart';
import 'package:rxdart/rxdart.dart';
@@ -44,17 +46,19 @@ class _LandingPageState extends State with WidgetsBindingObserver {
ProjectViewModel projectProvider;
final FirebaseMessaging _firebaseMessaging = FirebaseMessaging();
final authService = new AuthProvider();
+ var event = RobotProvider();
void _requestIOSPermissions() {
flutterLocalNotificationsPlugin
.resolvePlatformSpecificImplementation<
- IOSFlutterLocalNotificationsPlugin>()
+ IOSFlutterLocalNotificationsPlugin>()
?.requestPermissions(
- alert: true,
- badge: true,
- sound: true,
- );
+ alert: true,
+ badge: true,
+ sound: true,
+ );
}
+
bool isPageNavigated = false;
_changeCurrentTab(int tab) {
@@ -138,123 +142,121 @@ class _LandingPageState extends State with WidgetsBindingObserver {
//_firebase Background message handler
_firebaseMessaging.configure(
- // onMessage: (Map message) async {
- // showDialog("onMessage: $message");
- // print("onMessage: $message");
- // print(message);
- // print(message['name']);
- // print(message['appointmentdate']);
- //
- // if (Platform.isIOS) {
- // if (message['is_call'] == "true") {
- // var route = ModalRoute.of(context);
- //
- // if (route != null) {
- // print(route.settings.name);
- // }
- //
- // Map myMap = new Map.from(message);
- // print(myMap);
- // LandingPage.isOpenCallPage = true;
- // LandingPage.incomingCallData = IncomingCallData.fromJson(myMap);
- // if (!isPageNavigated) {
- // isPageNavigated = true;
- // Navigator.push(
- // context,
- // MaterialPageRoute(
- // builder: (context) => IncomingCall(
- // incomingCallData: LandingPage.incomingCallData)))
- // .then((value) {
- // isPageNavigated = false;
- // });
- // }
- // } else {
- // print("Is Call Not Found iOS");
- // }
- // } else {
- // print("Is Call Not Found iOS");
- // }
- //
- // if (Platform.isAndroid) {
- // if (message['data'].containsKey("is_call")) {
- // var route = ModalRoute.of(context);
- //
- // if (route != null) {
- // print(route.settings.name);
- // }
- //
- // Map myMap =
- // new Map.from(message['data']);
- // print(myMap);
- // LandingPage.isOpenCallPage = true;
- // LandingPage.incomingCallData = IncomingCallData.fromJson(myMap);
- // if (!isPageNavigated) {
- // isPageNavigated = true;
- // Navigator.push(
- // context,
- // MaterialPageRoute(
- // builder: (context) => IncomingCall(
- // incomingCallData: LandingPage.incomingCallData)))
- // .then((value) {
- // isPageNavigated = false;
- // });
- // }
- // } else {
- // print("Is Call Not Found Android");
- // }
- // } else {
- // print("Is Call Not Found Android");
- // }
- // },
- // onBackgroundMessage: Platform.isIOS ? null : myBackgroundMessageHandler,
- // onLaunch: (Map message) async {
- // print("onLaunch: $message");
- // showDialog("onLaunch: $message");
- // },
- // onResume: (Map message) async {
- // print("onResume: $message");
- // print(message);
- // print(message['name']);
- // print(message['appointmentdate']);
- //
- // showDialog("onResume: $message");
- //
- // if (Platform.isIOS) {
- // if (message['is_call'] == "true") {
- // var route = ModalRoute.of(context);
- //
- // if (route != null) {
- // print(route.settings.name);
- // }
- //
- // Map myMap =
- // new Map.from(message);
- // print(myMap);
- // LandingPage.isOpenCallPage = true;
- // LandingPage.incomingCallData = IncomingCallData.fromJson(myMap);
- // if (!isPageNavigated) {
- // isPageNavigated = true;
- // Navigator.push(
- // context,
- // MaterialPageRoute(
- // builder: (context) => IncomingCall(
- // incomingCallData: LandingPage.incomingCallData)))
- // .then((value) {
- // isPageNavigated = false;
- // });
- // }
- // } else {
- // print("Is Call Not Found iOS");
- // }
- // } else {
- // print("Is Call Not Found iOS");
- // }
- // },
- );
+ // onMessage: (Map message) async {
+ // showDialog("onMessage: $message");
+ // print("onMessage: $message");
+ // print(message);
+ // print(message['name']);
+ // print(message['appointmentdate']);
+ //
+ // if (Platform.isIOS) {
+ // if (message['is_call'] == "true") {
+ // var route = ModalRoute.of(context);
+ //
+ // if (route != null) {
+ // print(route.settings.name);
+ // }
+ //
+ // Map myMap = new Map.from(message);
+ // print(myMap);
+ // LandingPage.isOpenCallPage = true;
+ // LandingPage.incomingCallData = IncomingCallData.fromJson(myMap);
+ // if (!isPageNavigated) {
+ // isPageNavigated = true;
+ // Navigator.push(
+ // context,
+ // MaterialPageRoute(
+ // builder: (context) => IncomingCall(
+ // incomingCallData: LandingPage.incomingCallData)))
+ // .then((value) {
+ // isPageNavigated = false;
+ // });
+ // }
+ // } else {
+ // print("Is Call Not Found iOS");
+ // }
+ // } else {
+ // print("Is Call Not Found iOS");
+ // }
+ //
+ // if (Platform.isAndroid) {
+ // if (message['data'].containsKey("is_call")) {
+ // var route = ModalRoute.of(context);
+ //
+ // if (route != null) {
+ // print(route.settings.name);
+ // }
+ //
+ // Map myMap =
+ // new Map.from(message['data']);
+ // print(myMap);
+ // LandingPage.isOpenCallPage = true;
+ // LandingPage.incomingCallData = IncomingCallData.fromJson(myMap);
+ // if (!isPageNavigated) {
+ // isPageNavigated = true;
+ // Navigator.push(
+ // context,
+ // MaterialPageRoute(
+ // builder: (context) => IncomingCall(
+ // incomingCallData: LandingPage.incomingCallData)))
+ // .then((value) {
+ // isPageNavigated = false;
+ // });
+ // }
+ // } else {
+ // print("Is Call Not Found Android");
+ // }
+ // } else {
+ // print("Is Call Not Found Android");
+ // }
+ // },
+ // onBackgroundMessage: Platform.isIOS ? null : myBackgroundMessageHandler,
+ // onLaunch: (Map message) async {
+ // print("onLaunch: $message");
+ // showDialog("onLaunch: $message");
+ // },
+ // onResume: (Map message) async {
+ // print("onResume: $message");
+ // print(message);
+ // print(message['name']);
+ // print(message['appointmentdate']);
+ //
+ // showDialog("onResume: $message");
+ //
+ // if (Platform.isIOS) {
+ // if (message['is_call'] == "true") {
+ // var route = ModalRoute.of(context);
+ //
+ // if (route != null) {
+ // print(route.settings.name);
+ // }
+ //
+ // Map myMap =
+ // new Map.from(message);
+ // print(myMap);
+ // LandingPage.isOpenCallPage = true;
+ // LandingPage.incomingCallData = IncomingCallData.fromJson(myMap);
+ // if (!isPageNavigated) {
+ // isPageNavigated = true;
+ // Navigator.push(
+ // context,
+ // MaterialPageRoute(
+ // builder: (context) => IncomingCall(
+ // incomingCallData: LandingPage.incomingCallData)))
+ // .then((value) {
+ // isPageNavigated = false;
+ // });
+ // }
+ // } else {
+ // print("Is Call Not Found iOS");
+ // }
+ // } else {
+ // print("Is Call Not Found iOS");
+ // }
+ // },
+ );
}
-
-
showDialogs(String message) {
ConfirmDialog dialog = new ConfirmDialog(
context: context,
@@ -284,12 +286,11 @@ class _LandingPageState extends State with WidgetsBindingObserver {
return;
}
}
-
}
Future _scheduleNotification() async {
var scheduledNotificationDateTime =
- DateTime.now().add(Duration(seconds: 5));
+ DateTime.now().add(Duration(seconds: 5));
var vibrationPattern = Int64List(4);
vibrationPattern[0] = 0;
vibrationPattern[1] = 1000;
@@ -300,7 +301,7 @@ class _LandingPageState extends State with WidgetsBindingObserver {
'your other channel id',
'your other channel name',
'your other channel description',
- // icon: 'secondary_icon',
+ // icon: 'secondary_icon',
sound: RawResourceAndroidNotificationSound('slow_spring_board'),
largeIcon: DrawableResourceAndroidBitmap('sample_large_icon'),
vibrationPattern: vibrationPattern,
@@ -310,18 +311,17 @@ class _LandingPageState extends State with WidgetsBindingObserver {
ledOnMs: 1000,
ledOffMs: 500);
var iOSPlatformChannelSpecifics =
- IOSNotificationDetails(sound: 'slow_spring_board.aiff');
- var platformChannelSpecifics = NotificationDetails(
- androidPlatformChannelSpecifics, iOSPlatformChannelSpecifics);
- await flutterLocalNotificationsPlugin.schedule(
- 0,
- 'scheduled title',
- 'scheduled body',
- scheduledNotificationDateTime,
- platformChannelSpecifics);
+ IOSNotificationDetails(sound: 'slow_spring_board.aiff');
+ // var platformChannelSpecifics = NotificationDetails(
+ // androidPlatformChannelSpecifics, iOSPlatformChannelSpecifics);
+ // await flutterLocalNotificationsPlugin.schedule(
+ // 0,
+ // 'scheduled title',
+ // 'scheduled body',
+ // scheduledNotificationDateTime,
+ // platformChannelSpecifics);
}
-
@override
Widget build(BuildContext context) {
//final searchValue = Provider.of(context);
@@ -345,6 +345,16 @@ class _LandingPageState extends State with WidgetsBindingObserver {
);
},
),
+ actions: [
+ IconButton(
+ iconSize: 70,
+ icon: SvgPicture.asset('assets/images/svg/robort_svg.svg',
+ height: 100, width: 100, fit: BoxFit.cover),
+ onPressed: () {
+ triggerRobot();
+ } //do something,
+ )
+ ],
centerTitle: true,
),
drawer: SafeArea(child: AppDrawer()),
@@ -371,6 +381,10 @@ class _LandingPageState extends State with WidgetsBindingObserver {
);
}
+ triggerRobot() {
+ event.setValue({"isRobot": 'true'});
+ }
+
getText(currentTab) {
switch (currentTab) {
case 0:
diff --git a/lib/pages/login/confirm-login.dart b/lib/pages/login/confirm-login.dart
index 52afe85f..85c1b232 100644
--- a/lib/pages/login/confirm-login.dart
+++ b/lib/pages/login/confirm-login.dart
@@ -21,6 +21,7 @@ import 'package:diplomaticquarterapp/routes.dart';
import 'package:flutter/services.dart';
import 'package:intl/intl.dart';
import 'package:local_auth/local_auth.dart';
+import 'package:smart_progress_bar/smart_progress_bar.dart';
class ConfirmLogin extends StatefulWidget {
@override
@@ -75,183 +76,170 @@ class _ConfirmLogin extends State {
appBarTitle: TranslationBase.of(context).confirm,
isShowAppBar: true,
isShowDecPage: false,
- body: isLoading == false
- ? SingleChildScrollView(
- child: Container(
- padding: EdgeInsets.all(20),
- height: SizeConfig.realScreenHeight * .9,
- width: SizeConfig.realScreenWidth,
- child: Column(
- children: [
- Expanded(
- flex: 3,
- child: user != null && isMoreOption == false
- ? Column(
- mainAxisAlignment:
- MainAxisAlignment.spaceEvenly,
- crossAxisAlignment:
- CrossAxisAlignment.start,
- children: [
- Image.asset(
- 'assets/images/habib-logo.png',
- height: 80,
- width: 80,
- ),
- AppText(
- TranslationBase.of(context)
- .welcomeBack +
- ' ' +
- user.name,
- fontSize: SizeConfig.textMultiplier * 4,
- ),
- AppText(
- TranslationBase.of(context).accountInfo,
- fontSize: SizeConfig.textMultiplier * 3,
- ),
- Card(
- color: Colors.grey[300],
- child: Row(
- children: [
- Expanded(
- child: ListTile(
- title: Text(
- TranslationBase.of(context)
- .lastLoginAt,
- textAlign: TextAlign.center,
- ),
- subtitle: Text(
- user.editedOn != null
- ? formatDate(DateUtil
- .convertStringToDate(
- user.editedOn))
- : '--',
- textAlign:
- TextAlign.center),
- )),
- Expanded(
- child: ListTile(
- title: Text(
- TranslationBase.of(context)
- .lastLoginWith,
- textAlign:
- TextAlign.center),
- subtitle: Text(
- getType(user.logInType,
- context),
- textAlign:
- TextAlign.center),
- ))
- ],
- ))
- ],
- )
- : Column(
- mainAxisAlignment:
- MainAxisAlignment.spaceEvenly,
- crossAxisAlignment:
- CrossAxisAlignment.start,
- children: [
- Image.asset(
- 'assets/images/habib-logo.png',
- height: 80,
- width: 80,
- ),
- this.onlySMSBox == false
- ? AppText(
- TranslationBase.of(context)
- .verifyLoginWith,
- fontSize:
- SizeConfig.textMultiplier *
- 3.5,
- textAlign: TextAlign.left,
- )
- : AppText(
+ body: SingleChildScrollView(
+ child: Container(
+ padding: EdgeInsets.all(20),
+ height: SizeConfig.realScreenHeight * .9,
+ width: SizeConfig.realScreenWidth,
+ child: Column(
+ children: [
+ Expanded(
+ flex: 3,
+ child: user != null && isMoreOption == false
+ ? Column(
+ mainAxisAlignment:
+ MainAxisAlignment.spaceEvenly,
+ crossAxisAlignment: CrossAxisAlignment.start,
+ children: [
+ Image.asset(
+ 'assets/images/habib-logo.png',
+ height: 80,
+ width: 80,
+ ),
+ AppText(
+ TranslationBase.of(context).welcomeBack +
+ ' ' +
+ user.name,
+ fontSize: SizeConfig.textMultiplier * 3.5,
+ ),
+ AppText(
+ TranslationBase.of(context).accountInfo,
+ fontSize: SizeConfig.textMultiplier * 2.5,
+ ),
+ Card(
+ color: Colors.grey[300],
+ child: Row(
+ children: [
+ Expanded(
+ child: ListTile(
+ title: Text(
+ TranslationBase.of(context)
+ .lastLoginAt,
+ textAlign: TextAlign.center,
+ ),
+ subtitle: Text(
+ user.editedOn != null
+ ? formatDate(DateUtil
+ .convertStringToDate(
+ user.editedOn))
+ : '--',
+ textAlign: TextAlign.center),
+ )),
+ Expanded(
+ child: ListTile(
+ title: Text(
TranslationBase.of(context)
- .verifyFingerprint2,
- fontSize:
- SizeConfig.textMultiplier *
- 2.5,
- textAlign: TextAlign.left,
- ),
- ])),
- user != null && isMoreOption == false
- ? Expanded(
- flex: 2,
- child: Column(
- mainAxisAlignment: MainAxisAlignment.start,
- crossAxisAlignment:
- CrossAxisAlignment.start,
- children: [
- Row(
+ .lastLoginWith,
+ textAlign: TextAlign.center),
+ subtitle: Text(
+ getType(
+ user.logInType, context),
+ textAlign: TextAlign.center),
+ ))
+ ],
+ ))
+ ],
+ )
+ : Column(
+ mainAxisAlignment:
+ MainAxisAlignment.spaceEvenly,
+ crossAxisAlignment: CrossAxisAlignment.start,
+ children: [
+ Image.asset(
+ 'assets/images/habib-logo.png',
+ height: 80,
+ width: 80,
+ ),
+ this.onlySMSBox == false
+ ? AppText(
+ TranslationBase.of(context)
+ .verifyLoginWith,
+ fontSize:
+ SizeConfig.textMultiplier * 3.5,
+ textAlign: TextAlign.left,
+ )
+ : AppText(
+ TranslationBase.of(context)
+ .verifyFingerprint2,
+ fontSize:
+ SizeConfig.textMultiplier * 2.5,
+ textAlign: TextAlign.left,
+ ),
+ ])),
+ user != null && isMoreOption == false
+ ? Expanded(
+ flex: 2,
+ child: Column(
+ mainAxisAlignment: MainAxisAlignment.start,
+ crossAxisAlignment: CrossAxisAlignment.start,
+ children: [
+ Row(
+ mainAxisAlignment:
+ MainAxisAlignment.center,
+ children: [
+ Expanded(
+ child: InkWell(
+ onTap: () => {
+ authenticateUser(
+ 3,
+ BiometricType
+ .face.index)
+ },
+ child:
+ getButton(user.logInType))),
+ Expanded(child: getButton(5))
+ ])
+ ]))
+ : Expanded(
+ flex: 4,
+ child: Column(
+ mainAxisAlignment: MainAxisAlignment.start,
+ crossAxisAlignment: CrossAxisAlignment.start,
+ children: [
+ onlySMSBox == false
+ ? Row(
mainAxisAlignment:
MainAxisAlignment.center,
children: [
- Expanded(
- child: InkWell(
- onTap: () => {
- authenticateUser(
- 3,
- BiometricType
- .face.index)
- },
- child: getButton(
- user.logInType))),
- Expanded(child: getButton(5))
- ])
- ]))
- : Expanded(
- flex: 4,
- child: Column(
- mainAxisAlignment: MainAxisAlignment.start,
- crossAxisAlignment:
- CrossAxisAlignment.start,
+ Expanded(child: getButton(3)),
+ Expanded(child: getButton(2))
+ ],
+ )
+ : SizedBox(),
+ Row(
+ mainAxisAlignment: MainAxisAlignment.center,
children: [
- onlySMSBox == false
- ? Row(
- mainAxisAlignment:
- MainAxisAlignment.center,
- children: [
- Expanded(child: getButton(3)),
- Expanded(child: getButton(2))
- ],
- )
- : SizedBox(),
- Row(
- mainAxisAlignment:
- MainAxisAlignment.center,
- children: [
- Expanded(child: getButton(1)),
- Expanded(child: getButton(4))
- ],
- ),
- ]),
- ),
- Expanded(
- flex: 1,
- child: Column(
- mainAxisAlignment: MainAxisAlignment.end,
- children: [
- user != null
- ? Row(
- children: [
- Expanded(
- child: DefaultButton(
- TranslationBase.of(context)
- .useAnotherAccount,
- () => {
- Navigator.of(context).pushNamed(
- LOGIN_TYPE,
- )
- },
- )),
- ],
- )
- : SizedBox(),
- ],
- ))
- ],
- )))
- : AppCircularProgressIndicator());
+ Expanded(child: getButton(1)),
+ Expanded(child: getButton(4))
+ ],
+ ),
+ ]),
+ ),
+ Expanded(
+ flex: 1,
+ child: Column(
+ mainAxisAlignment: MainAxisAlignment.end,
+ children: [
+ user != null
+ ? Row(
+ children: [
+ Expanded(
+ child: DefaultButton(
+ TranslationBase.of(context)
+ .useAnotherAccount,
+ () => {
+ Navigator.of(context).pushNamed(
+ LOGIN_TYPE,
+ )
+ },
+ )),
+ ],
+ )
+ : SizedBox(),
+ ],
+ ))
+ ],
+ ))));
}
Future _getAvailableBiometrics() async {
@@ -315,32 +303,40 @@ class _ConfirmLogin extends State {
var request = CheckPatientAuthenticationReq.fromJson(req.toJson());
sharedPref.setObject(REGISTER_DATA_FOR_REGISTER, request);
- authService.checkPatientAuthentication(request).then((value) => {
- if (value['isSMSSent'])
- {
- sharedPref.setString(LOGIN_TOKEN_ID, value['LogInTokenID']),
- this.loginTokenID = value['LogInTokenID'],
- sharedPref.setObject(REGISTER_DATA_FOR_LOGIIN, request),
- // Future.delayed(Duration(seconds: 1), () {
- this.sendActivationCode(type)
- // })
- }
- else
- {
- if (value['IsAuthenticated']) {this.checkActivationCode()}
- }
- });
+ authService
+ .checkPatientAuthentication(request)
+ .then((value) => {
+ if (value['isSMSSent'])
+ {
+ sharedPref.setString(LOGIN_TOKEN_ID, value['LogInTokenID']),
+ this.loginTokenID = value['LogInTokenID'],
+ sharedPref.setObject(REGISTER_DATA_FOR_LOGIIN, request),
+ // Future.delayed(Duration(seconds: 1), () {
+ this.sendActivationCode(type)
+ // })
+ }
+ else
+ {
+ if (value['IsAuthenticated']) {this.checkActivationCode()}
+ }
+ })
+ .catchError((err) {
+ print(err);
+ }).showProgressBar(
+ text: "Loading", backgroundColor: Colors.blue.withOpacity(0.6));
}
- sendActivationCode(type) {
+ sendActivationCode(type) async {
var request = this.getCommonRequest();
- loading(true);
- this.authService.sendActivationCode(request).then((result) => {
- if (result != null && result['isSMSSent'] == true)
- {loading(false), this.startSMSService(type)}
- else
- {loading(false)}
- });
+ // loading(true);
+
+ await this.authService.sendActivationCode(request).then((result) => {
+ if (result != null && result['isSMSSent'] == true)
+ {this.startSMSService(type)}
+ });
+
+
+ // SMSOTP.showLoadingDialog(context, false),
}
startSMSService(type) {
@@ -371,42 +367,50 @@ class _ConfirmLogin extends State {
}
getMobileInfo(request) {
- this.authService.getLoginInfo(request).then((result) => {
- if (result['SMSLoginRequired'] == false)
- {
- this.loginTokenID = result.logInTokenID,
- this.patientOutSA = result.patientOutSA,
- // sms for register the biometric
- if (result.isSMSSent)
+ this
+ .authService
+ .getLoginInfo(request)
+ .then((result) => {
+ if (result['SMSLoginRequired'] == false)
{
- this.onlySMSBox = false,
- //this.button();
+ this.loginTokenID = result.logInTokenID,
+ this.patientOutSA = result.patientOutSA,
+ // sms for register the biometric
+ if (result.isSMSSent)
+ {
+ this.onlySMSBox = false,
+ //this.button();
+ }
+ else
+ {checkActivationCode()}
}
else
- {checkActivationCode()}
- }
- else
- {
- if (result['IsAuthenticated'] == true)
{
- setState(() {
- isMoreOption = true;
- this.onlySMSBox = true;
- // this.fingrePrintBefore = true;
- }),
-
- //sharedPref.setBool(ONLY_SMS, true),
- // this.cs.sharedService.setSharedData(true, AuthenticationService.ONLY_SMS);
- //this.cs.sharedService.setSharedData(this.selectedOption, AuthenticationService.FINGUREPRINT_BEFORE);
- // this.cs.confirmLogin();
- //this.button();
+ if (result['IsAuthenticated'] == true)
+ {
+ setState(() {
+ isMoreOption = true;
+ this.onlySMSBox = true;
+ // this.fingrePrintBefore = true;
+ }),
+
+ //sharedPref.setBool(ONLY_SMS, true),
+ // this.cs.sharedService.setSharedData(true, AuthenticationService.ONLY_SMS);
+ //this.cs.sharedService.setSharedData(this.selectedOption, AuthenticationService.FINGUREPRINT_BEFORE);
+ // this.cs.confirmLogin();
+ //this.button();
+ }
+ // else
+ // {
+ // // this.cs.presentAlert(result.ErrorEndUserMessage);
+ // }
}
- // else
- // {
- // // this.cs.presentAlert(result.ErrorEndUserMessage);
- // }
- }
- });
+ })
+ .catchError((err) {
+ print(err);
+ }).showProgressBar(
+ text: "Loading", backgroundColor: Colors.blue.withOpacity(0.6));
+ ;
}
setUser() async {}
@@ -427,9 +431,13 @@ class _ConfirmLogin extends State {
: int.parse(this.user.mobile);
this.zipCode = this.registerd_data != null
? this.registerd_data.zipCode
- : this.user.outSA == true ? "971" : "966";
+ : this.user.outSA == true
+ ? "971"
+ : "966";
this.patientOutSA = this.registerd_data != null
- ? this.registerd_data.zipCode == "966" ? 0 : 1
+ ? this.registerd_data.zipCode == "966"
+ ? 0
+ : 1
: this.user.outSA;
if (this.registerd_data != null) {
this.loginTokenID = await sharedPref.getString(LOGIN_TOKEN_ID);
@@ -477,43 +485,51 @@ class _ConfirmLogin extends State {
SMSOTP.showLoadingDialog(context, true);
var request = this.getCommonRequest().toJson();
- this.authService.checkActivationCode(request, value).then((result) => {
- if (result is Map)
- {
- result = CheckActivationCode.fromJson(result),
- if (this.registerd_data != null &&
- this.registerd_data.isRegister == true)
+ this
+ .authService
+ .checkActivationCode(request, value)
+ .then((result) => {
+ if (result is Map)
{
- Navigator.of(context).pushNamed(
- REGISTER_INFO,
- )
+ result = CheckActivationCode.fromJson(result),
+ if (this.registerd_data != null &&
+ this.registerd_data.isRegister == true)
+ {
+ Navigator.of(context).pushNamed(
+ REGISTER_INFO,
+ )
+ }
+ else
+ {
+ this.userData = result
+ .list, //AuthenticatedUser.fromJson(result['List'][0]),
+ this.sharedPref.setObject(USER_PROFILE, result.list),
+ this.loginTokenID = result.logInTokenID,
+ this
+ .sharedPref
+ .setObject(LOGIN_TOKEN_ID, result.logInTokenID),
+ this
+ .sharedPref
+ .setString(TOKEN, result.authenticationTokenID),
+ this.checkIfUserAgreedBefore(result),
+ // Navigator.of(context).pop(),
+ SMSOTP.showLoadingDialog(context, false),
+ }
}
else
{
- this.userData = result
- .list, //AuthenticatedUser.fromJson(result['List'][0]),
- this.sharedPref.setObject(USER_PROFILE, result.list),
- this.loginTokenID = result.logInTokenID,
- this
- .sharedPref
- .setObject(LOGIN_TOKEN_ID, result.logInTokenID),
- this
- .sharedPref
- .setString(TOKEN, result.authenticationTokenID),
- this.checkIfUserAgreedBefore(result),
// Navigator.of(context).pop(),
SMSOTP.showLoadingDialog(context, false),
+ Future.delayed(Duration(seconds: 1), () {
+ AppToast.showErrorToast(message: result);
+ }),
}
- }
- else
- {
- // Navigator.of(context).pop(),
- SMSOTP.showLoadingDialog(context, false),
- Future.delayed(Duration(seconds: 1), () {
- AppToast.showErrorToast(message: result);
- }),
- }
- });
+ })
+ .catchError((err) {
+ print(err);
+ }).showProgressBar(
+ text: "Loading", backgroundColor: Colors.blue.withOpacity(0.6));
+ ;
}
checkIfUserAgreedBefore(CheckActivationCode result) {
@@ -526,42 +542,17 @@ class _ConfirmLogin extends State {
}
insertIMEI() {
- authService.insertDeviceImei(selectedOption).then((value) => {goToHome()});
+ authService
+ .insertDeviceImei(selectedOption)
+ .then((value) => {goToHome()})
+ .catchError((err) {
+ print(err);
+ });
}
goToHome() {
// authService.insertDeviceImei().then((value) => print(value));
Navigator.of(context).pushNamed(HOME);
- // const request = new LoginRequest();
- // if (this.loginType === AuthenticationService.IDENTIFCIATION_LOGIN_TYPE) {
- // request.PatientID = 0;
- // } else {
- // request.PatientID = Number(this.id);
- // }
- // this.newRating(request);
- // }
- // public newRating(request: any) {
- // this.authService
- // .checkIfRated(
- // request,
- // () => {
- // this.gotoHome();
- // },
- // this.ts.trPK("general", "retry")
- // )
- // .subscribe((result: CheckUserRatingResponse) => {
- // if (this.cs.validResponse(result)) {
- // this.cs.sharedService.setSharedData(result, AuthenticationService.SURVEY_DATA);
- // if (result.IsLastAppoitmentRatedList.length === 0) {
- // this.cs.openHome();
- // } else {
- // this.ProjectID = result.IsLastAppoitmentRatedList[0].ProjectID;
- // this.AppointmentNo = result.IsLastAppoitmentRatedList[0].AppointmentNo;
- // this.cs.sharedService.setSharedData(true, "ratePage");
- // this.showRateModal();
- // }
- // }
- // });
}
loading(flag) {
diff --git a/lib/pages/login/login-type.dart b/lib/pages/login/login-type.dart
index d1ac54bb..8a5087a5 100644
--- a/lib/pages/login/login-type.dart
+++ b/lib/pages/login/login-type.dart
@@ -24,7 +24,7 @@ class LoginType extends StatelessWidget {
Expanded(
flex: 4,
child: Column(
- mainAxisAlignment: MainAxisAlignment.spaceEvenly,
+ // mainAxisAlignment: MainAxisAlignment.spaceEvenly,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Image.asset(
@@ -136,7 +136,7 @@ class LoginType extends StatelessWidget {
]),
),
Expanded(
- flex: 2,
+ flex: 1,
child: Column(
mainAxisAlignment: MainAxisAlignment.end,
children: [
diff --git a/lib/pages/login/login.dart b/lib/pages/login/login.dart
index a575f8c4..f2ece252 100644
--- a/lib/pages/login/login.dart
+++ b/lib/pages/login/login.dart
@@ -22,7 +22,7 @@ import 'package:diplomaticquarterapp/widgets/text/app_texts_widget.dart';
import 'package:diplomaticquarterapp/widgets/transitions/fade_page.dart';
import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
-
+import 'package:smart_progress_bar/smart_progress_bar.dart';
class Login extends StatefulWidget {
@override
_Login createState() => _Login();
@@ -62,9 +62,7 @@ class _Login extends State {
appBarTitle: TranslationBase.of(context).login,
isShowAppBar: true,
isShowDecPage: false,
- body: isLoading == true
- ? AppCircularProgressIndicator()
- : SingleChildScrollView(
+ body: SingleChildScrollView(
child: Container(
padding:
EdgeInsets.only(top: 10, left: 20, right: 20, bottom: 30),
@@ -89,6 +87,7 @@ class _Login extends State {
onCountryChange: (value) => countryCode = value),
Container(
child: TextFields(
+ fontWeight: FontWeight.normal,
controller: nationalIDorFile,
onChanged: (value) => {validateForm()},
prefixIcon: Icon(
@@ -151,7 +150,7 @@ class _Login extends State {
}
checkUserAuthentication() {
- showLoader(true);
+ // showLoader(true);
var request = CheckPatientAuthenticationReq();
request.isRegister = false;
request.patientMobileNumber = int.parse(mobileNo);
@@ -167,7 +166,7 @@ class _Login extends State {
}
sharedPref.setObject(REGISTER_DATA_FOR_REGISTER, request);
authService.checkPatientAuthentication(request).then((value) => {
- showLoader(false),
+ //showLoader(false),
if (value['isSMSSent'])
{
sharedPref.setString(LOGIN_TOKEN_ID, value['LogInTokenID']),
@@ -178,7 +177,11 @@ class _Login extends State {
{
if (value['IsAuthenticated']) {this.checkActivationCode()}
}
- });
+ }).catchError((err) {
+ print(err);
+ }).showProgressBar(
+ text: "Loading", backgroundColor: Colors.blue.withOpacity(0.6));
+ // SMSOTP.showLoadingDialog(context, false),
}
checkActivationCode({code}) async {
@@ -186,6 +189,8 @@ class _Login extends State {
// request.logInTokenID = await sharedPref.getString(LOGIN_TOKEN_ID);
// request.activationCode = code ?? "0000";
// request.isSilentLogin = code != null ? false : true;
+ if (code == null)
+ //showLoader(true);
request['PatientMobileNumber'] = int.parse(mobileNo);
request['ZipCode'] = countryCode;
request['SearchType'] = loginType;
@@ -208,6 +213,7 @@ class _Login extends State {
Navigator.of(context).pushNamed(
HOME,
),
+ //showLoader(false),
appointmentRateViewModel
.getIsLastAppointmentRatedList()
.then((value) => {
@@ -229,14 +235,17 @@ class _Login extends State {
),
)
}
- })
+ }).catchError((err) {
+ print(err);
+ }).showProgressBar(
+ text: "Loading", backgroundColor: Colors.blue.withOpacity(0.6))
// SMSOTP.showLoadingDialog(context, false),
});
}
- showLoader(bool isTrue) {
- setState(() {
- isLoading = isTrue;
- });
- }
+ // showLoader(bool isTrue) {
+ // setState(() {
+ // isLoading = isTrue;
+ // });
+ // }
}
diff --git a/lib/pages/login/welcome.dart b/lib/pages/login/welcome.dart
index 90bc2a2c..be406a55 100644
--- a/lib/pages/login/welcome.dart
+++ b/lib/pages/login/welcome.dart
@@ -61,7 +61,7 @@ class _WelcomeLogin extends State {
textAlign: TextAlign.left,
),
SizedBox(
- height: SizeConfig.realScreenHeight * .2,
+ height: SizeConfig.realScreenHeight * .15,
)
]),
),
diff --git a/lib/pages/medical/ask_doctor/doctor_response.dart b/lib/pages/medical/ask_doctor/doctor_response.dart
index b6071a4c..846c9a05 100644
--- a/lib/pages/medical/ask_doctor/doctor_response.dart
+++ b/lib/pages/medical/ask_doctor/doctor_response.dart
@@ -30,7 +30,7 @@ class DoctorResponse extends StatelessWidget {
height: 65,
),
AppExpandableNotifier(
- header: Padding(
+ headerWidget: Padding(
padding: const EdgeInsets.all(8.0),
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
@@ -110,7 +110,7 @@ class DoctorResponse extends StatelessWidget {
),
),
AppExpandableNotifier(
- header: Padding(
+ headerWidget: Padding(
padding: const EdgeInsets.all(8.0),
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
diff --git a/lib/pages/medical/balance/my_balance_page.dart b/lib/pages/medical/balance/my_balance_page.dart
index 446333cc..421e2bed 100644
--- a/lib/pages/medical/balance/my_balance_page.dart
+++ b/lib/pages/medical/balance/my_balance_page.dart
@@ -38,7 +38,7 @@ class MyBalancePage extends StatelessWidget {
width: double.infinity,
height: 65,
decoration: BoxDecoration(
- color: Hexcolor('#B61422'),
+ color: HexColor('#B61422'),
shape: BoxShape.rectangle,
borderRadius: BorderRadius.circular(7),
),
@@ -96,8 +96,7 @@ class MyBalancePage extends StatelessWidget {
textColor: Colors.white,
label: TranslationBase.of(context).createAdvancedPayment,
onTap: () {
- Navigator.push(context,
- FadePage(page: AdvancePaymentPage()));
+ Navigator.push(context, FadePage(page: AdvancePaymentPage()));
},
),
),
diff --git a/lib/pages/medical/my_trackers/Weight/WeightHomePage.dart b/lib/pages/medical/my_trackers/Weight/WeightHomePage.dart
index 7d7c5dd5..8e6f808c 100644
--- a/lib/pages/medical/my_trackers/Weight/WeightHomePage.dart
+++ b/lib/pages/medical/my_trackers/Weight/WeightHomePage.dart
@@ -135,7 +135,7 @@ class _WeightHomePageState extends State
width: 55,
height: 55,
decoration: BoxDecoration(
- shape: BoxShape.circle, color: Hexcolor('515B5D')),
+ shape: BoxShape.circle, color: HexColor('515B5D')),
child: Center(
child: Icon(
Icons.add,
diff --git a/lib/pages/medical/my_trackers/Weight/WeightMonthlyPage.dart b/lib/pages/medical/my_trackers/Weight/WeightMonthlyPage.dart
index 5bdbfeab..9f7063f1 100644
--- a/lib/pages/medical/my_trackers/Weight/WeightMonthlyPage.dart
+++ b/lib/pages/medical/my_trackers/Weight/WeightMonthlyPage.dart
@@ -15,8 +15,7 @@ class WeightMonthlyPage extends StatelessWidget {
final List> data;
final List diabtecPatientResult;
- const WeightMonthlyPage(
- {Key key, this.data, this.diabtecPatientResult})
+ const WeightMonthlyPage({Key key, this.data, this.diabtecPatientResult})
: super(key: key);
@override
@@ -67,7 +66,7 @@ class WeightMonthlyPage extends StatelessWidget {
children: [
Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
borderRadius: BorderRadius.only(
topLeft: Radius.circular(10.0),
),
@@ -83,18 +82,26 @@ class WeightMonthlyPage extends StatelessWidget {
),
Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
),
child: Center(
- child: Texts('Time', color: Colors.white,fontSize: 15,),
+ child: Texts(
+ 'Time',
+ color: Colors.white,
+ fontSize: 15,
+ ),
),
height: 40),
Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
),
child: Center(
- child: Texts('Value', color: Colors.white,fontSize: 15,),
+ child: Texts(
+ 'Value',
+ color: Colors.white,
+ fontSize: 15,
+ ),
),
height: 40),
],
diff --git a/lib/pages/medical/my_trackers/Weight/WeightWeeklyPage.dart b/lib/pages/medical/my_trackers/Weight/WeightWeeklyPage.dart
index ac1a3214..9c3363dd 100644
--- a/lib/pages/medical/my_trackers/Weight/WeightWeeklyPage.dart
+++ b/lib/pages/medical/my_trackers/Weight/WeightWeeklyPage.dart
@@ -29,8 +29,9 @@ class WeightWeeklyPage extends StatelessWidget {
dateTimeFactory: const charts.LocalDateTimeFactory(),
),
),
- SizedBox(height: 12,),
-
+ SizedBox(
+ height: 12,
+ ),
Padding(
padding: const EdgeInsets.all(8.0),
child: Texts('Details'),
@@ -62,7 +63,7 @@ class WeightWeeklyPage extends StatelessWidget {
children: [
Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
borderRadius: BorderRadius.only(
topLeft: Radius.circular(10.0),
),
@@ -78,37 +79,50 @@ class WeightWeeklyPage extends StatelessWidget {
),
Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
),
child: Center(
- child: Texts('Time', color: Colors.white,fontSize: 15,),
+ child: Texts(
+ 'Time',
+ color: Colors.white,
+ fontSize: 15,
+ ),
),
height: 40),
Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
),
child: Center(
- child: Texts('Value', color: Colors.white,fontSize: 15,),
+ child: Texts(
+ 'Value',
+ color: Colors.white,
+ fontSize: 15,
+ ),
),
height: 40),
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
borderRadius: BorderRadius.only(
topRight: Radius.circular(10.0),
),
),
child: Center(
- child: Texts('Edit', color: Colors.white,fontSize: 15,),
+ child: Texts(
+ 'Edit',
+ color: Colors.white,
+ fontSize: 15,
+ ),
),
height: 40),
),
],
),
);
- diabtecPatientResult.forEach((diabtec) {
+ diabtecPatientResult.forEach(
+ (diabtec) {
tableRow.add(
TableRow(
children: [
diff --git a/lib/pages/medical/my_trackers/Weight/WeightYeaPage.dart b/lib/pages/medical/my_trackers/Weight/WeightYeaPage.dart
index 3ddeaa82..587cc3f6 100644
--- a/lib/pages/medical/my_trackers/Weight/WeightYeaPage.dart
+++ b/lib/pages/medical/my_trackers/Weight/WeightYeaPage.dart
@@ -65,7 +65,7 @@ class WeightYearPage extends StatelessWidget {
children: [
Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
borderRadius: BorderRadius.only(
topLeft: Radius.circular(10.0),
),
@@ -81,25 +81,33 @@ class WeightYearPage extends StatelessWidget {
),
Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
),
child: Center(
- child: Texts('Time', color: Colors.white,fontSize: 15,),
+ child: Texts(
+ 'Time',
+ color: Colors.white,
+ fontSize: 15,
+ ),
),
height: 40),
Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
),
child: Center(
- child: Texts('Value', color: Colors.white,fontSize: 15,),
+ child: Texts(
+ 'Value',
+ color: Colors.white,
+ fontSize: 15,
+ ),
),
height: 40),
],
),
);
diabtecPatientResult.forEach(
- (diabtec) {
+ (diabtec) {
tableRow.add(
TableRow(
children: [
diff --git a/lib/pages/medical/my_trackers/blood_pressure/BloodPressureHomePage.dart b/lib/pages/medical/my_trackers/blood_pressure/BloodPressureHomePage.dart
index c118f2ca..d2bcde47 100644
--- a/lib/pages/medical/my_trackers/blood_pressure/BloodPressureHomePage.dart
+++ b/lib/pages/medical/my_trackers/blood_pressure/BloodPressureHomePage.dart
@@ -138,7 +138,7 @@ class _BloodPressureHomePageState extends State
width: 55,
height: 55,
decoration: BoxDecoration(
- shape: BoxShape.circle, color: Hexcolor('515B5D')),
+ shape: BoxShape.circle, color: HexColor('515B5D')),
child: Center(
child: Icon(
Icons.add,
diff --git a/lib/pages/medical/my_trackers/blood_pressure/BloodPressureMonthly.dart b/lib/pages/medical/my_trackers/blood_pressure/BloodPressureMonthly.dart
index f38cc3b6..8b9e504f 100644
--- a/lib/pages/medical/my_trackers/blood_pressure/BloodPressureMonthly.dart
+++ b/lib/pages/medical/my_trackers/blood_pressure/BloodPressureMonthly.dart
@@ -67,7 +67,7 @@ class BloodPressureMonthlyPage extends StatelessWidget {
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
borderRadius: BorderRadius.only(
topLeft: Radius.circular(10.0),
),
@@ -85,7 +85,7 @@ class BloodPressureMonthlyPage extends StatelessWidget {
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
),
child: Center(
child: Texts(
@@ -99,7 +99,7 @@ class BloodPressureMonthlyPage extends StatelessWidget {
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
),
child: Center(
child: Texts(
@@ -113,7 +113,7 @@ class BloodPressureMonthlyPage extends StatelessWidget {
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
borderRadius: BorderRadius.only(
topRight: Radius.circular(10.0),
),
@@ -149,7 +149,8 @@ class BloodPressureMonthlyPage extends StatelessWidget {
),
),
),
- Container(child: Container(
+ Container(
+ child: Container(
height: 70,
padding: EdgeInsets.all(10),
color: Colors.white,
@@ -160,7 +161,8 @@ class BloodPressureMonthlyPage extends StatelessWidget {
fontSize: 12,
),
),
- ),),
+ ),
+ ),
Container(
child: Container(
height: 70,
diff --git a/lib/pages/medical/my_trackers/blood_pressure/BloodPressureYeaPage.dart b/lib/pages/medical/my_trackers/blood_pressure/BloodPressureYeaPage.dart
index dfcf42ae..0c67be7c 100644
--- a/lib/pages/medical/my_trackers/blood_pressure/BloodPressureYeaPage.dart
+++ b/lib/pages/medical/my_trackers/blood_pressure/BloodPressureYeaPage.dart
@@ -65,7 +65,7 @@ class BloodPressureYearPage extends StatelessWidget {
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
borderRadius: BorderRadius.only(
topLeft: Radius.circular(10.0),
),
@@ -83,7 +83,7 @@ class BloodPressureYearPage extends StatelessWidget {
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
),
child: Center(
child: Texts(
@@ -97,7 +97,7 @@ class BloodPressureYearPage extends StatelessWidget {
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
),
child: Center(
child: Texts(
@@ -108,11 +108,10 @@ class BloodPressureYearPage extends StatelessWidget {
),
height: 40),
),
-
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
borderRadius: BorderRadius.only(
topRight: Radius.circular(10.0),
),
diff --git a/lib/pages/medical/my_trackers/blood_pressure/bloodPressureWeeklyPage.dart b/lib/pages/medical/my_trackers/blood_pressure/bloodPressureWeeklyPage.dart
index fbcbf417..52313483 100644
--- a/lib/pages/medical/my_trackers/blood_pressure/bloodPressureWeeklyPage.dart
+++ b/lib/pages/medical/my_trackers/blood_pressure/bloodPressureWeeklyPage.dart
@@ -30,8 +30,9 @@ class BloodPressureWeeklyPage extends StatelessWidget {
dateTimeFactory: const charts.LocalDateTimeFactory(),
),
),
- SizedBox(height: 12,),
-
+ SizedBox(
+ height: 12,
+ ),
Padding(
padding: const EdgeInsets.all(8.0),
child: Texts('Details'),
@@ -64,7 +65,7 @@ class BloodPressureWeeklyPage extends StatelessWidget {
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
borderRadius: BorderRadius.only(
topLeft: Radius.circular(10.0),
),
@@ -82,50 +83,67 @@ class BloodPressureWeeklyPage extends StatelessWidget {
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
),
child: Center(
- child: Texts('Time', color: Colors.white,fontSize: 15,),
+ child: Texts(
+ 'Time',
+ color: Colors.white,
+ fontSize: 15,
+ ),
),
height: 40),
),
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
),
child: Center(
- child: Texts('Measured', color: Colors.white,fontSize: 15,),
+ child: Texts(
+ 'Measured',
+ color: Colors.white,
+ fontSize: 15,
+ ),
),
height: 40),
),
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
),
child: Center(
- child: Texts('Value', color: Colors.white,fontSize: 15,),
+ child: Texts(
+ 'Value',
+ color: Colors.white,
+ fontSize: 15,
+ ),
),
height: 40),
),
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
borderRadius: BorderRadius.only(
topRight: Radius.circular(10.0),
),
),
child: Center(
- child: Texts('Edit', color: Colors.white,fontSize: 15,),
+ child: Texts(
+ 'Edit',
+ color: Colors.white,
+ fontSize: 15,
+ ),
),
height: 40),
),
],
),
);
- diabtecPatientResult.forEach((diabtec) {
+ diabtecPatientResult.forEach(
+ (diabtec) {
tableRow.add(
TableRow(
children: [
diff --git a/lib/pages/medical/my_trackers/blood_suger/BloodMonthly.dart b/lib/pages/medical/my_trackers/blood_suger/BloodMonthly.dart
index da31c4ed..fdd7b348 100644
--- a/lib/pages/medical/my_trackers/blood_suger/BloodMonthly.dart
+++ b/lib/pages/medical/my_trackers/blood_suger/BloodMonthly.dart
@@ -1,4 +1,3 @@
-
import 'package:diplomaticquarterapp/core/model/my_trakers/blood_sugar/DiabtecPatientResult.dart';
import 'package:diplomaticquarterapp/core/model/my_trakers/chartData/WeekChartDate.dart';
import 'package:diplomaticquarterapp/core/model/my_trakers/chartData/YearMonthlyChartDate.dart';
@@ -14,7 +13,8 @@ class BloodMonthlyPage extends StatelessWidget {
final List> data;
final List diabtecPatientResult;
- const BloodMonthlyPage({Key key, this.data,this.diabtecPatientResult}) : super(key: key);
+ const BloodMonthlyPage({Key key, this.data, this.diabtecPatientResult})
+ : super(key: key);
@override
Widget build(BuildContext context) {
return AppScaffold(
@@ -24,14 +24,14 @@ class BloodMonthlyPage extends StatelessWidget {
width: double.maxFinite,
height: 180,
color: Colors.white,
- child: charts.LineChart(
- data,
+ child: charts.LineChart(data,
//animate: animate,
- defaultRenderer: new charts.LineRendererConfig(includePoints: true)
- ),
+ defaultRenderer:
+ new charts.LineRendererConfig(includePoints: true)),
+ ),
+ SizedBox(
+ height: 12,
),
- SizedBox(height: 12,),
-
Padding(
padding: const EdgeInsets.all(8.0),
child: Texts('Details'),
@@ -51,7 +51,6 @@ class BloodMonthlyPage extends StatelessWidget {
],
),
)
-
],
),
);
@@ -65,7 +64,7 @@ class BloodMonthlyPage extends StatelessWidget {
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
borderRadius: BorderRadius.only(
topLeft: Radius.circular(10.0),
),
@@ -83,105 +82,116 @@ class BloodMonthlyPage extends StatelessWidget {
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
),
child: Center(
- child: Texts('Time', color: Colors.white,fontSize: 15,),
+ child: Texts(
+ 'Time',
+ color: Colors.white,
+ fontSize: 15,
+ ),
),
height: 40),
),
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
),
child: Center(
- child: Texts('Measured', color: Colors.white,fontSize: 15,),
+ child: Texts(
+ 'Measured',
+ color: Colors.white,
+ fontSize: 15,
+ ),
),
height: 40),
),
-
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
borderRadius: BorderRadius.only(
topRight: Radius.circular(10.0),
),
),
child: Center(
- child: Texts('Value', color: Colors.white,fontSize: 15,),
+ child: Texts(
+ 'Value',
+ color: Colors.white,
+ fontSize: 15,
+ ),
),
height: 40),
),
],
),
);
- diabtecPatientResult.forEach((diabtec) {
- tableRow.add(
- TableRow(
- children: [
- Container(
- child: Container(
- height: 70,
- padding: EdgeInsets.all(10),
- color: Colors.white,
- child: Center(
- child: Texts(
- '${DateUtil.getMonthDayYearDateFormatted(diabtec.dateChart)} ',
- textAlign: TextAlign.center,
- fontSize: 12,
+ diabtecPatientResult.forEach(
+ (diabtec) {
+ tableRow.add(
+ TableRow(
+ children: [
+ Container(
+ child: Container(
+ height: 70,
+ padding: EdgeInsets.all(10),
+ color: Colors.white,
+ child: Center(
+ child: Texts(
+ '${DateUtil.getMonthDayYearDateFormatted(diabtec.dateChart)} ',
+ textAlign: TextAlign.center,
+ fontSize: 12,
+ ),
),
),
),
- ),
- Container(
- child: Container(
- height: 70,
- padding: EdgeInsets.all(10),
- color: Colors.white,
- child: Center(
- child: Texts(
- '${diabtec.dateChart.hour}:${diabtec.dateChart.minute}',
- textAlign: TextAlign.center,
- fontSize: 12,
+ Container(
+ child: Container(
+ height: 70,
+ padding: EdgeInsets.all(10),
+ color: Colors.white,
+ child: Center(
+ child: Texts(
+ '${diabtec.dateChart.hour}:${diabtec.dateChart.minute}',
+ textAlign: TextAlign.center,
+ fontSize: 12,
+ ),
),
),
),
- ),
- Container(
- child: Container(
- height: 70,
- padding: EdgeInsets.all(10),
- color: Colors.white,
- child: Center(
- child: Texts(
- '${diabtec.measuredDesc}',
- textAlign: TextAlign.center,
- fontSize: 12,
+ Container(
+ child: Container(
+ height: 70,
+ padding: EdgeInsets.all(10),
+ color: Colors.white,
+ child: Center(
+ child: Texts(
+ '${diabtec.measuredDesc}',
+ textAlign: TextAlign.center,
+ fontSize: 12,
+ ),
),
),
),
- ),
- Container(
- child: Container(
- height: 70,
- padding: EdgeInsets.all(10),
- color: Colors.white,
- child: Center(
- child: Texts(
- '${diabtec.resultValue}',
- textAlign: TextAlign.center,
- fontSize: 12,
+ Container(
+ child: Container(
+ height: 70,
+ padding: EdgeInsets.all(10),
+ color: Colors.white,
+ child: Center(
+ child: Texts(
+ '${diabtec.resultValue}',
+ textAlign: TextAlign.center,
+ fontSize: 12,
+ ),
),
),
),
- ),
-
- ],
- ),
- );
- },
+ ],
+ ),
+ );
+ },
);
return tableRow;
}
diff --git a/lib/pages/medical/my_trackers/blood_suger/BloodYeaPage.dart b/lib/pages/medical/my_trackers/blood_suger/BloodYeaPage.dart
index 3bddab88..47f87847 100644
--- a/lib/pages/medical/my_trackers/blood_suger/BloodYeaPage.dart
+++ b/lib/pages/medical/my_trackers/blood_suger/BloodYeaPage.dart
@@ -64,7 +64,7 @@ class BloodYearPage extends StatelessWidget {
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
borderRadius: BorderRadius.only(
topLeft: Radius.circular(10.0),
),
@@ -82,7 +82,7 @@ class BloodYearPage extends StatelessWidget {
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
),
child: Center(
child: Texts(
@@ -96,7 +96,7 @@ class BloodYearPage extends StatelessWidget {
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
),
child: Center(
child: Texts(
@@ -107,11 +107,10 @@ class BloodYearPage extends StatelessWidget {
),
height: 40),
),
-
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
borderRadius: BorderRadius.only(
topRight: Radius.circular(10.0),
),
diff --git a/lib/pages/medical/my_trackers/blood_suger/blood_sugar_home_page.dart b/lib/pages/medical/my_trackers/blood_suger/blood_sugar_home_page.dart
index 1190b6b6..c8c7fa4a 100644
--- a/lib/pages/medical/my_trackers/blood_suger/blood_sugar_home_page.dart
+++ b/lib/pages/medical/my_trackers/blood_suger/blood_sugar_home_page.dart
@@ -37,7 +37,6 @@ class _BloodSugarHomePageState extends State
_tabController.dispose();
}
-
@override
Widget build(BuildContext context) {
return BaseView(
@@ -78,7 +77,8 @@ class _BloodSugarHomePageState extends State
indicatorSize: TabBarIndicatorSize.label,
indicatorColor: Colors.red[800],
labelColor: Theme.of(context).primaryColor,
- labelPadding: EdgeInsets.only(top: 4.0, left: 5.0, right: 5.0),
+ labelPadding:
+ EdgeInsets.only(top: 4.0, left: 5.0, right: 5.0),
unselectedLabelColor: Colors.grey[800],
tabs: [
Container(
@@ -114,27 +114,37 @@ class _BloodSugarHomePageState extends State
physics: BouncingScrollPhysics(),
controller: _tabController,
children: [
- BloodSugarWeeklyPage(data: model.getBloodWeeklySeries(),diabtecPatientResult: model.weekDiabtecPatientResult,),
- BloodMonthlyPage(data: model.getBloodMonthlyTimeSeriesSales(),diabtecPatientResult: model.monthDiabtecPatientResult,),
- BloodYearPage(data: model.getBloodYearTimeSeriesSales(),diabtecPatientResult: model.yearDiabtecPatientResult,)
+ BloodSugarWeeklyPage(
+ data: model.getBloodWeeklySeries(),
+ diabtecPatientResult: model.weekDiabtecPatientResult,
+ ),
+ BloodMonthlyPage(
+ data: model.getBloodMonthlyTimeSeriesSales(),
+ diabtecPatientResult: model.monthDiabtecPatientResult,
+ ),
+ BloodYearPage(
+ data: model.getBloodYearTimeSeriesSales(),
+ diabtecPatientResult: model.yearDiabtecPatientResult,
+ )
],
),
)
],
),
floatingActionButton: InkWell(
- onTap: (){
+ onTap: () {
Navigator.push(context, FadePage(page: AddBloodSugarPage()));
},
child: Container(
width: 55,
height: 55,
decoration: BoxDecoration(
- shape: BoxShape.circle,
- color: Hexcolor('515B5D')
- ),
+ shape: BoxShape.circle, color: HexColor('515B5D')),
child: Center(
- child: Icon(Icons.add,color: Colors.white,),
+ child: Icon(
+ Icons.add,
+ color: Colors.white,
+ ),
),
),
),
diff --git a/lib/pages/medical/my_trackers/blood_suger/blood_sugar_weekly_page.dart b/lib/pages/medical/my_trackers/blood_suger/blood_sugar_weekly_page.dart
index 6b892162..4b007929 100644
--- a/lib/pages/medical/my_trackers/blood_suger/blood_sugar_weekly_page.dart
+++ b/lib/pages/medical/my_trackers/blood_suger/blood_sugar_weekly_page.dart
@@ -29,8 +29,9 @@ class BloodSugarWeeklyPage extends StatelessWidget {
dateTimeFactory: const charts.LocalDateTimeFactory(),
),
),
- SizedBox(height: 12,),
-
+ SizedBox(
+ height: 12,
+ ),
Padding(
padding: const EdgeInsets.all(8.0),
child: Texts('Details'),
@@ -63,7 +64,7 @@ class BloodSugarWeeklyPage extends StatelessWidget {
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
borderRadius: BorderRadius.only(
topLeft: Radius.circular(10.0),
),
@@ -81,50 +82,67 @@ class BloodSugarWeeklyPage extends StatelessWidget {
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
),
child: Center(
- child: Texts('Time', color: Colors.white,fontSize: 15,),
+ child: Texts(
+ 'Time',
+ color: Colors.white,
+ fontSize: 15,
+ ),
),
height: 40),
),
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
),
child: Center(
- child: Texts('Measured', color: Colors.white,fontSize: 15,),
+ child: Texts(
+ 'Measured',
+ color: Colors.white,
+ fontSize: 15,
+ ),
),
height: 40),
),
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
),
child: Center(
- child: Texts('Value', color: Colors.white,fontSize: 15,),
+ child: Texts(
+ 'Value',
+ color: Colors.white,
+ fontSize: 15,
+ ),
),
height: 40),
),
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
borderRadius: BorderRadius.only(
topRight: Radius.circular(10.0),
),
),
child: Center(
- child: Texts('Edit', color: Colors.white,fontSize: 15,),
+ child: Texts(
+ 'Edit',
+ color: Colors.white,
+ fontSize: 15,
+ ),
),
height: 40),
),
],
),
);
- diabtecPatientResult.forEach((diabtec) {
+ diabtecPatientResult.forEach(
+ (diabtec) {
tableRow.add(
TableRow(
children: [
diff --git a/lib/pages/medical/vital_sign/vital_sign_details_wideget.dart b/lib/pages/medical/vital_sign/vital_sign_details_wideget.dart
index ad5c6ffb..589284a1 100644
--- a/lib/pages/medical/vital_sign/vital_sign_details_wideget.dart
+++ b/lib/pages/medical/vital_sign/vital_sign_details_wideget.dart
@@ -52,7 +52,7 @@ class _VitalSignDetailsWidgetState extends State {
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
borderRadius: BorderRadius.only(
topLeft: Radius.circular(10.0),
),
@@ -69,7 +69,7 @@ class _VitalSignDetailsWidgetState extends State {
Container(
child: Container(
decoration: BoxDecoration(
- color: Hexcolor('#515B5D'),
+ color: HexColor('#515B5D'),
borderRadius: BorderRadius.only(
topRight: Radius.circular(10.0),
),
diff --git a/lib/pages/medical/vital_sign/vital_sign_item.dart b/lib/pages/medical/vital_sign/vital_sign_item.dart
index 9586fb25..fb44772d 100644
--- a/lib/pages/medical/vital_sign/vital_sign_item.dart
+++ b/lib/pages/medical/vital_sign/vital_sign_item.dart
@@ -45,16 +45,22 @@ class VitalSignItem extends StatelessWidget {
child: Text(
des,
style: TextStyle(
- fontSize: 1.7 * SizeConfig.textMultiplier,
- color: Hexcolor('#B8382C'),
- fontWeight: FontWeight.bold,),
+ fontSize: 1.7 * SizeConfig.textMultiplier,
+ color: HexColor('#B8382C'),
+ fontWeight: FontWeight.bold,
+ ),
),
),
),
),
Expanded(
flex: 1,
- child: Container(child: Icon(icon,size: 40,),),
+ child: Container(
+ child: Icon(
+ icon,
+ size: 40,
+ ),
+ ),
)
],
),
@@ -65,7 +71,7 @@ class VitalSignItem extends StatelessWidget {
child: Align(
alignment: Alignment.topRight,
child: Container(
- margin: EdgeInsets.only(left: 5,right: 5),
+ margin: EdgeInsets.only(left: 5, right: 5),
child: RichText(
text: TextSpan(
style: TextStyle(color: Colors.black),
@@ -74,7 +80,7 @@ class VitalSignItem extends StatelessWidget {
TextSpan(
text: unit,
style: TextStyle(
- color: Hexcolor('#B8382C'),
+ color: HexColor('#B8382C'),
),
),
]),
diff --git a/lib/pages/paymentService/payment_service.dart b/lib/pages/paymentService/payment_service.dart
index 15a1f699..0d19045b 100644
--- a/lib/pages/paymentService/payment_service.dart
+++ b/lib/pages/paymentService/payment_service.dart
@@ -41,7 +41,7 @@ class PaymentService extends StatelessWidget {
children: [
Texts(
TranslationBase.of(context).payment,
- color: Hexcolor('#B61422'),
+ color: HexColor('#B61422'),
bold: true,
),
Texts(
@@ -73,11 +73,11 @@ class PaymentService extends StatelessWidget {
children: [
Texts(
TranslationBase.of(context).onlineCheckIn,
- color: Hexcolor('#B61422'),
+ color: HexColor('#B61422'),
bold: true,
),
Texts(
- TranslationBase.of(context).appointment,
+ TranslationBase.of(context).appointment,
fontSize: 14,
fontWeight: FontWeight.normal,
),
@@ -115,7 +115,7 @@ class PaymentService extends StatelessWidget {
children: [
Texts(
'My Balances',
- color: Hexcolor('#B61422'),
+ color: HexColor('#B61422'),
bold: true,
),
Texts(
diff --git a/lib/pages/rateAppointment/rate_appointment_clinic.dart b/lib/pages/rateAppointment/rate_appointment_clinic.dart
index 74f134ae..38fdd008 100644
--- a/lib/pages/rateAppointment/rate_appointment_clinic.dart
+++ b/lib/pages/rateAppointment/rate_appointment_clinic.dart
@@ -226,7 +226,7 @@ class _RateAppointmentClinicState extends State {
child: Texts(
'Later',
decoration: TextDecoration.underline,
- color: Hexcolor('#151DFE'),
+ color: HexColor('#151DFE'),
fontSize: 18,
),
)
diff --git a/lib/pages/rateAppointment/rate_appointment_doctor.dart b/lib/pages/rateAppointment/rate_appointment_doctor.dart
index 1583f033..83674906 100644
--- a/lib/pages/rateAppointment/rate_appointment_doctor.dart
+++ b/lib/pages/rateAppointment/rate_appointment_doctor.dart
@@ -177,7 +177,9 @@ class _RateAppointmentDoctorState extends State {
},
),
),
- SizedBox(height: 12,),
+ SizedBox(
+ height: 12,
+ ),
Container(
width: double.infinity,
child: Column(
@@ -222,7 +224,7 @@ class _RateAppointmentDoctorState extends State {
child: Texts(
'Later',
decoration: TextDecoration.underline,
- color: Hexcolor('#151DFE'),
+ color: HexColor('#151DFE'),
fontSize: 18,
),
)
diff --git a/lib/pages/symptom-checker/symtom-checker.dart b/lib/pages/symptom-checker/symtom-checker.dart
new file mode 100644
index 00000000..f7475abf
--- /dev/null
+++ b/lib/pages/symptom-checker/symtom-checker.dart
@@ -0,0 +1,43 @@
+import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart';
+import 'package:flutter/cupertino.dart';
+import 'package:flutter/material.dart';
+import 'package:flutter_svg/flutter_svg.dart';
+
+class SymptomChecker extends StatelessWidget {
+ @override
+ Widget build(BuildContext context) {
+ return AppScaffold(
+ isShowAppBar: true,
+ appBarTitle: 'Symptom Checker',
+ body: Center(
+ child: SvgPicture.string(
+ '''''')));
+ }
+}
diff --git a/lib/routes.dart b/lib/routes.dart
index 27161669..8d109983 100644
--- a/lib/routes.dart
+++ b/lib/routes.dart
@@ -10,6 +10,7 @@ import 'package:diplomaticquarterapp/pages/login/login.dart';
import 'package:diplomaticquarterapp/pages/login/register.dart';
import 'package:diplomaticquarterapp/pages/family/add-family_type.dart';
import 'package:diplomaticquarterapp/pages/family/add-family-member.dart';
+import 'package:diplomaticquarterapp/pages/symptom-checker/symtom-checker.dart';
const String INIT_ROUTE = '/';
const String HOME = '/';
@@ -25,6 +26,7 @@ const String MY_FAMILIY = 'my-family';
const String ADD_FAMILY_MEMBER_TYPE = 'add-family-member-type';
const String ADD_FAMILY_MEMBER = 'add-family-member';
const String LIVE_CARE = 'live-care';
+const String SYMPTOM_CHECKER = 'symptom-checker';
var routes = {
HOME: (_) => LandingPage(),
WELCOME_LOGIN: (_) => WelcomeLogin(),
@@ -37,5 +39,6 @@ var routes = {
MY_FAMILIY: (_) => MyFamily(),
ADD_FAMILY_MEMBER_TYPE: (_) => AddFamilyMemberType(),
ADD_FAMILY_MEMBER: (_) => AddMember(),
- LIVE_CARE: (_) => LiveCareHome()
+ LIVE_CARE: (_) => LiveCareHome(),
+ SYMPTOM_CHECKER: (_) => SymptomChecker()
};
diff --git a/lib/services/appointment_services/GetDoctorsList.dart b/lib/services/appointment_services/GetDoctorsList.dart
index 24d81bdf..4b5dc264 100644
--- a/lib/services/appointment_services/GetDoctorsList.dart
+++ b/lib/services/appointment_services/GetDoctorsList.dart
@@ -27,7 +27,7 @@ class DoctorsListService extends BaseService {
Future