Pharmacy LiveCare revamped

merge-update-with-lab-changes
haroon amjad 3 years ago
parent 74b0acefd3
commit 4f50c3ff8e

@ -67,7 +67,7 @@ const Map localizedValues = {
'pressAgain': {'en': 'Press again to exit the app', 'ar': 'اضغط مرة أخرى للخروج من التطبيق'},
'laserMaxLimitReach': {'en': "Maximum limit is 90 minutes", 'ar': "الحد الأقصى هو 90 دقيقة"},
'confirmAppoHeading': {'en': 'Kindly review your Appointment', 'ar': 'يرجى تأكيد موعدك'},
'patientInfo': {'en': 'Patient Information', 'ar': 'معلومات المريض'},
'patientInfo': {'en': 'Patient Information', 'ar': 'معلومات المراجع'},
'doctorFilter': {'en': 'Doctors will be filtered based on your gender and age', 'ar': 'سيتم تصفية الأطباء بناءً على جنسك وعمرك'},
'bookSuccess': {'en': 'Book Success', 'ar': 'تم حجز الموعد بنجاح'},
'patientShare': {'en': 'Patient Share', 'ar': 'نسبة العميل'},
@ -120,7 +120,7 @@ const Map localizedValues = {
'poweredBy': {'en': 'Powered by', 'ar': 'مشغل بواسطة'},
"welcome": {"en": "Welcome", "ar": "مرحبا بكم"},
"welcome-to": {"en": "Welcome to", "ar": "مرحبا بك في"},
"patient-app": {"en": "Patient App", "ar": "تطبيق المرضى"},
"patient-app": {"en": "Patient App", "ar": "تطبيق المراجعين"},
"welcome_text": {"en": "Dr. Sulaiman Al Habib Mobile Application", "ar": "الدكتور سليمان الحبيب لتطبيقات الهاتف"},
"dr-sulaiman-text": {"en": "Dr. Sulaiman Al Habib", "ar": "د. سليمان الحبيب"},
'welcome_text2': {'en': 'Have you previously visited the hospitals or medical centers of Dr. Sulaiman Al Habib?', 'ar': 'هل قمت مسبقا بزيارة مستشفيات او مراكز الدكتور سليمان الحبيب الطبية ؟'},
@ -419,7 +419,7 @@ const Map localizedValues = {
"Amount": {"en": "Amount *", "ar": "المبلغ *"},
"DepositorEmail": {"en": "Depositor Email *", "ar": "البريد الإلكتروني للمودع *"},
"Notes": {"en": "Notes", "ar": "ملاحظات"},
"SelectPatientName": {"en": "Select Patient Name", "ar": "اختر اسم المريض"},
"SelectPatientName": {"en": "Select Patient Name", "ar": "اختر اسم المراجع"},
"SelectFamilyPatientName": {"en": "Family Members", "ar": "أفراد الأسرة"},
"SelectHospital": {"en": "Select Hospital", "ar": "اختر المستشفى"},
"selectCity": {"en": "Select City", "ar": "اختر المدينة"},
@ -1119,7 +1119,7 @@ const Map localizedValues = {
"visit": {"en": "Visit", "ar": "زيارة"},
"referralStatus": {"en": "Referral Status", "ar": "حالة الإحالة"},
"referralDate": {"en": "Referral Date", "ar": "تاريخ الإحالة"},
"patientName": {"en": "Patient Name", "ar": "اسم المريض"},
"patientName": {"en": "Patient Name", "ar": "اسم المراجع"},
"referralNumber": {"en": "Referral Number", "ar": "رقم الإحالة"},
"requestID": {"en": "Req ID", "ar": " رقم الطلب"},
"OrderStatus": {"en": "Status", "ar": "الحاله"},
@ -1412,7 +1412,7 @@ const Map localizedValues = {
"online-consultation": {"en": "Online Consultation", "ar": "استشارة مباشرة"},
"expected-weiting": {"en": "Waiting time to start LiveCare consultation ", "ar": "وقت الانتظار المتوقع لبدء استشارة لايف كير"},
"er-consult-fee": {"en": "Consultation Fee", "ar": "رسوم الاستشارة"},
"insured-patient": {"en": "If you're Insurance patient, you have only have to pay the co-payment", "ar": "إذا كنت مريضًا في مجال التأمين ، فليس عليك سوى دفع المبلغ المشترك"},
"insured-patient": {"en": "If you're Insurance patient, you have only have to pay the co-payment", "ar": "إذا كنت مراجع في مجال التأمين ، فليس عليك سوى دفع المبلغ المشترك"},
"i-accept-terms": {"en": "I Accept the Terms and Conditions", "ar": "موافق على الشروط والأحكام"},
"upcoming-pay-options": {"en": "You can pay by the following Options:", "ar": "يمكنك الدفع عن طريق الخيارات التالية:"},
"please-accept-terms": {"en": "Please accept terms & conditions to continue", "ar": "يرجى قبول الشروط والأحكام للمتابعة"},
@ -1421,7 +1421,7 @@ const Map localizedValues = {
"en":
"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)",
"ar":
"تتيح لك هذه الخدمة إرسال طلب إحالة من أي من مقدمي الرعاية الصحية سواء داخل المملكة العربية السعودية أو خارجها إلى أي من مستشفيات HMG ، عن طريق ملء بعض بيانات المريض وإرفاق التقارير الطبية ، علاوة على ذلك يمكنك تتبع حالة الطلب (قيد المعالجة ، مقبول أو مرفوض)"
"تتيح لك هذه الخدمة إرسال طلب إحالة من أي من مقدمي الرعاية الصحية سواء داخل المملكة العربية السعودية أو خارجها إلى أي من مستشفيات HMG ، عن طريق ملء بعض بيانات المراجع وإرفاق التقارير الطبية ، علاوة على ذلك يمكنك تتبع حالة الطلب (قيد المعالجة ، مقبول أو مرفوض)"
},
"er-consultation": {
"en": "This service allows you to make an online virtual consultation via video call directly with the doctor from anywhere at any time.",
@ -1558,10 +1558,10 @@ const Map localizedValues = {
"insuranceCompany": {"en": "Insurance Company", "ar": "شركة تأمين"},
"preferredBranch": {"en": "Preferred Branch", "ar": "الفرع المفضل"},
"selectPreferredBranch": {"en": "Select Preferred Branch", "ar": "اختر الفرع المفضل"},
"patientLocated": {"en": "Where the patient located", "ar": "اين موقع المريض"},
"patientLocated": {"en": "Where the patient located", "ar": "اين موقع المراجع"},
"otherInfo": {"en": "Other details", "ar": "تفاصيل أخرى"},
"medicalReport": {"en": "Medical Report", "ar": "تقرير طبي"},
"insuredPatient": {"en": "Insured Patient", "ar": "هل لدى المريض تامين؟"},
"insuredPatient": {"en": "Insured Patient", "ar": "هل لدى المراجع تامين؟"},
"rateDoctor": {"en": "Rate Doctor", "ar": "تقييم الطبيب"},
"rateAppointment": {"en": "Rate Appointment", "ar": "تقييم الموعد"},
"noInsuranceCardAttached": {"en": "Please attach your insurance card image to continue", "ar": "يرجى إرفاق صورة بطاقة التأمين الخاصة بك للمتابعة"},
@ -1589,7 +1589,7 @@ const Map localizedValues = {
"patientAge": {"en": "y", "ar": "سنة"},
"searchCriteria": {"en": "Select Search Criteria", "ar": "حدد معايير البحث"},
"RequesterInfo": {"en": "Requester Info", "ar": "معلومات مقدم الطلب"},
"PatientInfo": {"en": "Patient Info", "ar": "معلومات المريض"},
"PatientInfo": {"en": "Patient Info", "ar": "معلومات المراجع"},
"OtherInfo": {"en": "Other Info", "ar": "معلومات اخرى"},
"inPrgress": {"en": "In Progress", "ar": "في تقدم"},
"locked": {"en": "Locked", "ar": "مقفل"},
@ -1810,7 +1810,7 @@ const Map localizedValues = {
},
"cameraPermissionDialog": {
"en": "Dr. Al Habib app needs to access Camera to enable virtual consultation between patient & doctor, attach images and scan QR for parking service.",
"ar": "يحتاج تطبيق دكتور الحبيب الى صلاحية الوصول إلى الكاميرا لخدمة الاستشارة الافتراضية بين المريض والطبيب وإرفاق الصور ومسح رمز الاستجابة السريع لخدمة مواقف السيارات."
"ar": "يحتاج تطبيق دكتور الحبيب الى صلاحية الوصول إلى الكاميرا لخدمة الاستشارة الافتراضية بين المراجع والطبيب وإرفاق الصور ومسح رمز الاستجابة السريع لخدمة مواقف السيارات."
},
"galleryPermission": {
"en": "Dr. Al Habib app needs to access Read & write external storage to upload images & documents in the E-Referral module and renew and update the insurance cards.",

@ -284,8 +284,8 @@ class _BookSuccessState extends State<BookSuccess> {
),
height: 45.0,
child: CustomTextButton(
backgroundColor: CustomColors.green,
elevation: 0,
backgroundColor: CustomColors.green,
elevation: 0,
onPressed: () {
AppoitmentAllHistoryResultList appo = new AppoitmentAllHistoryResultList();
appo.clinicID = widget.docObject.clinicID;
@ -300,7 +300,8 @@ class _BookSuccessState extends State<BookSuccess> {
confirmAppointment(appo);
}
},
child: Text(widget.patientShareResponse.isLiveCareAppointment ? TranslationBase.of(context).confirmLiveCare : TranslationBase.of(context).confirm, style: TextStyle(fontSize: 16.0, color: Colors.white)),
child: Text(widget.patientShareResponse.isLiveCareAppointment ? TranslationBase.of(context).confirmLiveCare : TranslationBase.of(context).confirm,
style: TextStyle(fontSize: 16.0, color: Colors.white)),
),
),
),
@ -955,12 +956,29 @@ class _BookSuccessState extends State<BookSuccess> {
}
Future navigateToQR(context, String appoQR) async {
AppoitmentAllHistoryResultList appointment = new AppoitmentAllHistoryResultList();
appointment.doctorTitle = "Dr. ";
appointment.doctorNameObj = widget.patientShareResponse.doctorNameObj;
appointment.doctorImageURL = widget.patientShareResponse.doctorImageURL;
appointment.doctorSpeciality = widget.patientShareResponse.doctorSpeciality;
appointment.projectName = widget.patientShareResponse.projectName;
appointment.projectID = widget.patientShareResponse.projectID;
appointment.appointmentDate = widget.patientShareResponse.appointmentDate;
appointment.isLiveCareAppointment = widget.patientShareResponse.isLiveCareAppointment;
appointment.startTime = widget.patientShareResponse.startTime;
appointment.doctorRate = 5;
appointment.actualDoctorRate = 5;
appointment.noOfPatientsRate = 0;
appointment.clinicName = widget.patientShareResponse.clinicName;
Navigator.push(
context,
FadePage(
page: QRCode(
patientShareResponse: widget.patientShareResponse,
appoQR: appoQR,
appointment: appointment,
)));
}

@ -1,5 +1,6 @@
import 'package:diplomaticquarterapp/analytics/google-analytics.dart';
import 'package:diplomaticquarterapp/config/shared_pref_kay.dart';
import 'package:diplomaticquarterapp/core/viewModels/project_view_model.dart';
import 'package:diplomaticquarterapp/locator.dart';
import 'package:diplomaticquarterapp/models/Appointments/DentalChiefComplaintsModel.dart';
import 'package:diplomaticquarterapp/models/Appointments/DentalProceduresModel.dart';
@ -19,6 +20,7 @@ import 'package:diplomaticquarterapp/widgets/dialogs/confirm_dialog.dart';
import 'package:diplomaticquarterapp/widgets/others/app_expandable_notifier.dart';
import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart';
import 'package:flutter/material.dart';
import 'package:provider/provider.dart';
class DentalComplaints extends StatefulWidget {
SearchInfo searchInfo;
@ -44,6 +46,8 @@ class _DentalComplaintsState extends State<DentalComplaints> {
DentalProceduresModel dentalProceduresModel;
List<PatientDoctorAppointmentList> patientDoctorAppointmentListHospital = List();
ProjectViewModel projectViewModel;
@override
void initState() {
WidgetsBinding.instance.addPostFrameCallback((_) => checkIfHasDentalPlan());
@ -52,6 +56,7 @@ class _DentalComplaintsState extends State<DentalComplaints> {
@override
Widget build(BuildContext context) {
projectViewModel = Provider.of(context);
return AppScaffold(
isShowAppBar: true,
appBarTitle: TranslationBase.of(context).chiefComplaints,

@ -531,7 +531,15 @@ class _SearchByClinicState extends State<SearchByClinic> {
searchInfo.clinic = selectedClinic;
searchInfo.date = DateTime.now();
navigateToDentalComplaints(context, searchInfo);
if(projectViewModel.isLogin) {
if(projectViewModel.user.age > 12) {
navigateToDentalComplaints(context, searchInfo);
} else {
callDoctorsSearchAPI(17);
}
} else {
navigateToDentalComplaints(context, searchInfo);
}
} else if (dropdownValue.split("-")[0] == "253") {
navigateToLaserClinic(context);
// callDoctorsSearchAPI();
@ -552,15 +560,15 @@ class _SearchByClinicState extends State<SearchByClinic> {
Navigator.push(context, FadePage(page: LiveCareHome()));
}
if (value == "schedule") {
callDoctorsSearchAPI();
callDoctorsSearchAPI(int.parse(dropdownValue.split("-")[0]));
}
});
} else {
callDoctorsSearchAPI();
callDoctorsSearchAPI(int.parse(dropdownValue.split("-")[0]));
}
}
callDoctorsSearchAPI() {
callDoctorsSearchAPI(int clinicID) {
GifLoaderDialogUtils.showMyDialog(context);
List<DoctorList> doctorsList = [];
List<String> arr = [];
@ -570,7 +578,7 @@ class _SearchByClinicState extends State<SearchByClinic> {
List<PatientDoctorAppointmentList> _patientDoctorAppointmentListHospital = List();
DoctorsListService service = new DoctorsListService();
service.getDoctorsList(int.parse(dropdownValue.split("-")[0]), projectDropdownValue != "" ? int.parse(projectDropdownValue) : 0, nearestAppo, context).then((res) {
service.getDoctorsList(clinicID, projectDropdownValue != "" ? int.parse(projectDropdownValue) : 0, nearestAppo, context).then((res) {
GifLoaderDialogUtils.hideDialog(context);
if (res['MessageStatus'] == 1) {
setState(() {

@ -18,8 +18,9 @@ class LiveCareHome extends StatefulWidget {
static bool showFooterButton = true;
static bool isLiveCareTypeSelected = false;
final bool isPharmacyLiveCare;
final String pharmacyLiveCareQRCode;
const LiveCareHome({Key key, this.isPharmacyLiveCare = false}) : super(key: key);
const LiveCareHome({Key key, this.isPharmacyLiveCare = false, this.pharmacyLiveCareQRCode = ""}) : super(key: key);
@override
_LiveCareHomeState createState() => _LiveCareHomeState();
@ -125,6 +126,7 @@ class _LiveCareHomeState extends State<LiveCareHome> with SingleTickerProviderSt
? ClinicList(
getLiveCareHistory: getLiveCareHistory,
isPharmacyLiveCare: widget.isPharmacyLiveCare,
pharmacyLiveCareQRCode: widget.pharmacyLiveCareQRCode,
)
: isDataLoaded
? LiveCarePendingRequest(getLiveCareHistory: getLiveCareHistory, pendingERRequestHistoryList: pendingERRequestHistoryList)

@ -1,9 +1,14 @@
import 'package:barcode_scan2/barcode_scan2.dart';
import 'package:diplomaticquarterapp/config/shared_pref_kay.dart';
import 'package:diplomaticquarterapp/core/viewModels/project_view_model.dart';
import 'package:diplomaticquarterapp/pages/livecare/livecare_home.dart';
import 'package:diplomaticquarterapp/services/livecare_services/livecare_provider.dart';
import 'package:diplomaticquarterapp/theme/colors.dart';
import 'package:diplomaticquarterapp/uitl/app_shared_preferences.dart';
import 'package:diplomaticquarterapp/uitl/gif_loader_dialog_utils.dart';
import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart';
import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart';
import 'package:diplomaticquarterapp/widgets/transitions/fade_page.dart';
import 'package:flutter/material.dart';
import 'package:flutter_svg/flutter_svg.dart';
import 'package:provider/provider.dart';
@ -18,6 +23,7 @@ class _LiveCareTypeSelectState extends State<LiveCareTypeSelect> {
AppSharedPreferences sharedPref = AppSharedPreferences();
ProjectViewModel projectViewModel;
String pharmacyLiveCareQRCode = "";
@override
void initState() {
@ -89,7 +95,6 @@ class _LiveCareTypeSelectState extends State<LiveCareTypeSelect> {
Container(
margin: EdgeInsets.only(top: 20.0),
child: Text(TranslationBase.of(context).livecareSummary, style: TextStyle(fontSize: 14.0, letterSpacing: -0.64, color: CustomColors.textColor, fontWeight: FontWeight.w600))),
GridView(
gridDelegate: SliverGridDelegateWithFixedCrossAxisCount(crossAxisCount: 2, crossAxisSpacing: 13, mainAxisSpacing: 9),
physics: NeverScrollableScrollPhysics(),
@ -98,6 +103,7 @@ class _LiveCareTypeSelectState extends State<LiveCareTypeSelect> {
children: [
_loginOptionButton(TranslationBase.of(context).livecareOption1, 'assets/images/new/Live_Care.svg', 1),
_loginOptionButton(TranslationBase.of(context).livecareOption4, 'assets/images/new/book appointment.svg', 2),
_loginOptionButton("Pharmacy LiveCare", 'assets/images/new/Live_Care.svg', 3),
],
),
SizedBox(
@ -116,9 +122,12 @@ class _LiveCareTypeSelectState extends State<LiveCareTypeSelect> {
if (_loginIndex == 1) {
Navigator.pop(context, "immediate");
projectViewModel.analytics.liveCare.livecare_immediate_consultation();
} else {
} else if (_loginIndex == 2) {
Navigator.pop(context, "schedule");
projectViewModel.analytics.liveCare.livecare_schedule_video_call();
} else {
//Pharmacy LiveCare
readQRCode();
}
},
child: Container(
@ -150,6 +159,25 @@ class _LiveCareTypeSelectState extends State<LiveCareTypeSelect> {
);
}
readQRCode() async {
pharmacyLiveCareQRCode = (await BarcodeScanner.scan())?.rawContent;
GifLoaderDialogUtils.showMyDialog(context);
LiveCareService service = new LiveCareService();
service.getPatientInfoByQR(pharmacyLiveCareQRCode, context).then((res) {
GifLoaderDialogUtils.hideDialog(context);
}).catchError((err) {
GifLoaderDialogUtils.hideDialog(context);
print(err);
startPharmacyLiveCareProcess();
});
}
startPharmacyLiveCareProcess() {
sharedPref.setString(LIVECARE_CLINIC_DATA, "Pharmacy LiveCare" + "-" + "501" + "-" + "7");
Navigator.pop(context, "pharmacy/$pharmacyLiveCareQRCode");
// Navigator.push(context, FadePage(page: LiveCareHome(isPharmacyLiveCare: true, pharmacyLiveCareQRCode: pharmacyLiveCareQRCode,)));
}
getLanguageID() async {
var languageID = await sharedPref.getStringWithDefaultValue(APP_LANGUAGE, 'ar');
setState(() {

@ -112,12 +112,12 @@ class _LiveCarePendingRequestState extends State<LiveCarePendingRequest> {
// cancelLiveCareRequest();
}),
),
// DefaultButton(
// TranslationBase.of(context).cancel,
// () {
// cancelLiveCareRequest();
// },
// ),
DefaultButton(
TranslationBase.of(context).cancel,
() {
cancelLiveCareRequest();
},
),
],
),
),

@ -39,9 +39,10 @@ import '../live_care_payment_page.dart';
class ClinicList extends StatefulWidget {
final Function getLiveCareHistory;
final bool isPharmacyLiveCare;
bool isPharmacyLiveCare;
String pharmacyLiveCareQRCode;
ClinicList({@required this.getLiveCareHistory, this.isPharmacyLiveCare = false});
ClinicList({@required this.getLiveCareHistory, this.isPharmacyLiveCare = false, this.pharmacyLiveCareQRCode = ""});
@override
_clinic_listState createState() => _clinic_listState();
@ -300,6 +301,7 @@ class _clinic_listState extends State<ClinicList> {
setState(() {});
},
patientShare: num.parse(getERAppointmentFeesList.total),
isFromAdvancePayment: widget.isPharmacyLiveCare,
))).then((value) {
print(value);
if (value != null) {
@ -316,8 +318,27 @@ class _clinic_listState extends State<ClinicList> {
selectedInstallmentPlan = paymentMethod[1];
this.amount = amount.toString();
browser.openPaymentBrowser(amount, "LiveCare Payment", Utils.getAppointmentTransID(appo.projectID, appo.clinicID, appo.appointmentNo), "12", authenticatedUser.emailAddress, paymentMethod[0],
authenticatedUser.patientType, authenticatedUser.firstName, authenticatedUser.patientID, authenticatedUser, browser, false, "4", selectedClinicID, context, "", "", "", "", paymentMethod[1]);
browser.openPaymentBrowser(
amount,
"LiveCare Payment",
widget.isPharmacyLiveCare ? widget.pharmacyLiveCareQRCode : Utils.getAppointmentTransID(appo.projectID, appo.clinicID, appo.appointmentNo),
"12",
authenticatedUser.emailAddress,
paymentMethod[0],
authenticatedUser.patientType,
authenticatedUser.firstName,
authenticatedUser.patientID,
authenticatedUser,
browser,
false,
"4",
selectedClinicID,
context,
"",
"",
"",
"",
paymentMethod[1]);
}
onBrowserLoadStart(String url) {
@ -425,13 +446,13 @@ class _clinic_listState extends State<ClinicList> {
final currency = projectViewModel.user.outSA == 0 ? "sar" : 'aed';
DoctorsListService service = new DoctorsListService();
GifLoaderDialogUtils.showMyDialog(context);
service.checkPaymentStatus(Utils.getAppointmentTransID(appo.projectID, appo.clinicID, appo.appointmentNo), context).then((res) {
service.checkPaymentStatus(widget.isPharmacyLiveCare ? widget.pharmacyLiveCareQRCode : Utils.getAppointmentTransID(appo.projectID, appo.clinicID, appo.appointmentNo), context).then((res) {
GifLoaderDialogUtils.hideDialog(context);
String paymentInfo = res['Response_Message'];
amount = res['Amount'].toString();
payment_method = res['PaymentMethod'];
if (paymentInfo == 'Success') {
addNewCallForPatientER(Utils.getAppointmentTransID(appo.projectID, appo.clinicID, appo.appointmentNo));
addNewCallForPatientER(widget.isPharmacyLiveCare ? widget.pharmacyLiveCareQRCode : Utils.getAppointmentTransID(appo.projectID, appo.clinicID, appo.appointmentNo));
} else {
AppToast.showErrorToast(message: res['Response_Message']);
projectViewModel.analytics.liveCare.livecare_immediate_consultation_payment_failed(
@ -527,6 +548,7 @@ class _clinic_listState extends State<ClinicList> {
openLiveCareSelectionDialog() async {
liveCareClinicIDs = await sharedPref.getString(LIVECARE_CLINIC_DATA);
sharedPref.remove(LIVECARE_CLINIC_DATA);
if (liveCareClinicIDs != null) {
selectedClinicID = int.parse(liveCareClinicIDs.split("-")[2]);
setState(() {
@ -535,8 +557,8 @@ class _clinic_listState extends State<ClinicList> {
// if(widget.isPharmacyLiveCare) {
//
// } else {
getLiveCareClinicsList();
startLiveCare();
getLiveCareClinicsList();
startLiveCare();
// }
} else {
Navigator.of(context)
@ -545,9 +567,17 @@ class _clinic_listState extends State<ClinicList> {
return LiveCareTypeSelect();
},
fullscreenDialog: true))
.then((value) {
.then((value) async {
if (value == null) {
Navigator.pop(context);
} else if (value.contains("-")) {
widget.isPharmacyLiveCare = true;
widget.pharmacyLiveCareQRCode = value.split("/")[1];
liveCareClinicIDs = await sharedPref.getString(LIVECARE_CLINIC_DATA);
selectedClinicID = int.parse(liveCareClinicIDs.split("-")[2]);
selectedClinicName = liveCareClinicIDs.split("-")[0];
sharedPref.remove(LIVECARE_CLINIC_DATA);
startLiveCare();
} else {
print(value);
if (value == "immediate") {

@ -65,12 +65,13 @@ class DoctorsListService extends BaseService {
"PatientID": authUser.patientID != null ? authUser.patientID : 0,
"gender": authUser.gender != null ? authUser.gender : 0,
"age": authUser.age != null ? authUser.age : 0,
"DateofBirth": authUser.dateofBirth != null ? authUser.dateofBirth : null,
"IsGetNearAppointment": false,
"SearchForVoiceCommand": doctorId != null && doctorId.length > 0 ? true : false,
"DoctorIDsList": doctorId,
"Latitude": lat != null ? lat.toString() : 0,
"Longitude": long != null ? long.toString() : 0,
"isDentalAllowedBackend": isContinueDentalPlan,
"isDentalAllowedBackend": clinicID == 17 ? true : isContinueDentalPlan,
"IsGetNearAppointment": isNearest,
if (isNearest) "SelectedDate": DateUtil.convertDateToString(DateTime.now()),
"License": true

@ -123,7 +123,8 @@ class ClinicListService extends BaseService {
"DeviceTypeID": 1,
"PatientID": 1,
"ContinueDentalPlan": true,
"IsSearchAppointmnetByClinicID": false
"IsSearchAppointmnetByClinicID": false,
"DateofBirth": authUser.dateofBirth
};
dynamic localRes;

@ -75,6 +75,7 @@ class _AppDrawerState extends State<AppDrawer> {
String booldType;
String notificationCount;
final authService = new AuthProvider();
String pharmacyLiveCareQRCode = "";
@override
Widget build(BuildContext context) {
@ -334,19 +335,19 @@ class _AppDrawerState extends State<AppDrawer> {
}
},
),
InkWell(
child: DrawerItem(TranslationBase.of(context).pharmacyLiveCare, SvgPicture.asset("assets/images/new/Live_Care.svg"),
isImageIcon: true,
bottomLine: false,
textColor: Theme.of(context).textTheme.bodyText1.color,
iconColor: Theme.of(context).textTheme.bodyText1.color,
sideArrow: true,
letterSpacing: -0.84,
projectProvider: projectProvider),
onTap: () {
readQRCode();
},
),
// InkWell(
// child: DrawerItem(TranslationBase.of(context).pharmacyLiveCare, SvgPicture.asset("assets/images/new/Live_Care.svg"),
// isImageIcon: true,
// bottomLine: false,
// textColor: Theme.of(context).textTheme.bodyText1.color,
// iconColor: Theme.of(context).textTheme.bodyText1.color,
// sideArrow: true,
// letterSpacing: -0.84,
// projectProvider: projectProvider),
// onTap: () {
// readQRCode();
// },
// ),
InkWell(
child: Stack(
children: [
@ -495,11 +496,11 @@ class _AppDrawerState extends State<AppDrawer> {
}
readQRCode() async {
String result = (await BarcodeScanner.scan())?.rawContent;
print(result);
pharmacyLiveCareQRCode = (await BarcodeScanner.scan())?.rawContent;
print(pharmacyLiveCareQRCode);
GifLoaderDialogUtils.showMyDialog(context);
LiveCareService service = new LiveCareService();
service.getPatientInfoByQR(result, context).then((res) {
service.getPatientInfoByQR(pharmacyLiveCareQRCode, context).then((res) {
GifLoaderDialogUtils.hideDialog(context);
}).catchError((err) {
GifLoaderDialogUtils.hideDialog(context);
@ -511,7 +512,7 @@ class _AppDrawerState extends State<AppDrawer> {
startPharmacyLiveCareProcess() {
sharedPref.setString(LIVECARE_CLINIC_DATA, "Pharmacy LiveCare" + "-" + "501" + "-" + "7");
Navigator.push(context, FadePage(page: LiveCareHome(isPharmacyLiveCare: true,)));
Navigator.push(context, FadePage(page: LiveCareHome(isPharmacyLiveCare: true, pharmacyLiveCareQRCode: pharmacyLiveCareQRCode,)));
}
drawerNavigator(context, routeName) {

@ -37,9 +37,9 @@ class MyInAppBrowser extends InAppBrowser {
// static String APPLE_PAY_PAYFORT_URL = 'https://hmgwebservices.com/PayFortWebLive/PayFortApi/MakeApplePayRequest'; // Payfort Payment Gateway URL LIVE
static String APPLE_PAY_PAYFORT_URL = 'https://hmgwebservices.com/PayFortWebLive/PayFortApi/MakeApplePayRequest'; // Payfort Payment Gateway URL UAT
// static String SERVICE_URL = 'https://hmgwebservices.com/PayFortWeb/pages/SendPayFortRequest.aspx'; // Payfort Payment Gateway URL UAT
static String SERVICE_URL = 'https://hmgwebservices.com/PayFortWeb/pages/SendPayFortRequest.aspx'; // Payfort Payment Gateway URL UAT
static String SERVICE_URL = 'https://hmgwebservices.com/PayFortWebLive/pages/SendPayFortRequest.aspx'; //Payfort Payment Gateway URL LIVE
// static String SERVICE_URL = 'https://hmgwebservices.com/PayFortWebLive/pages/SendPayFortRequest.aspx'; //Payfort Payment Gateway URL LIVE
// static String PRESCRIPTION_PAYMENT_WITH_ORDERID =
// 'https://uat.hmgwebservices.com/epharmacy/checkout/OpcCompleteRedirectionPaymentClientbyOrder?orderID=';
@ -143,7 +143,7 @@ class MyInAppBrowser extends InAppBrowser {
}
openPaymentBrowser(num amount, String orderDesc, String transactionID, String projId, String emailId, String paymentMethod, dynamic patientType, String patientName, dynamic patientID,
AuthenticatedUser authenticatedUser, InAppBrowser browser, bool isLiveCareAppo, var servID, var LiveServID,
AuthenticatedUser authenticatedUser, InAppBrowser browser, bool isLiveCareAppo, var servID, var LiveServID, BuildContext context,
[var appoDate, var appoNo, var clinicID, var doctorID, var installments]) async {
this.browser = browser;
await getPatientData();
@ -187,7 +187,8 @@ class MyInAppBrowser extends InAppBrowser {
service.applePayInsertRequest(applePayInsertRequest, context).then((res) {
if (context != null) GifLoaderDialogUtils.hideDialog(context);
String url = "https://hmgwebservices.com/HMGApplePayLive/applepay/pay?apq=" + res['result'];
String url = "https://hmgwebservices.com/HMGApplePayLive/applepay/pay?apq=" + res['result']; // Prod
// String url = "https://uat.hmgwebservices.com/HMGApplePayLiveNew/applepay/pay?apq=" + res['result']; // UAT
// safariBrowser.open(url: Uri.parse(url));
this.browser.openUrlRequest(urlRequest: URLRequest(url: Uri.parse(url)), options: _InAppBrowserOptions);
}).catchError((err) {

Loading…
Cancel
Save