|
|
|
|
@ -6,7 +6,7 @@ import 'dart:typed_data';
|
|
|
|
|
import 'package:auto_size_text/auto_size_text.dart';
|
|
|
|
|
import 'package:badges/badges.dart' as badge_import;
|
|
|
|
|
import 'package:cached_network_image/cached_network_image.dart';
|
|
|
|
|
import 'package:connectivity/connectivity.dart';
|
|
|
|
|
import 'package:connectivity_plus/connectivity_plus.dart';
|
|
|
|
|
import 'package:crypto/crypto.dart' as crypto;
|
|
|
|
|
import 'package:diplomaticquarterapp/config/config.dart';
|
|
|
|
|
import 'package:diplomaticquarterapp/config/shared_pref_kay.dart';
|
|
|
|
|
@ -75,7 +75,7 @@ class Utils {
|
|
|
|
|
/// Check The Internet Connection
|
|
|
|
|
static Future<bool> checkConnection({bool bypassConnectionCheck = false}) async {
|
|
|
|
|
if (bypassConnectionCheck) return true;
|
|
|
|
|
|
|
|
|
|
//return true;
|
|
|
|
|
ConnectivityResult connectivityResult = await (Connectivity().checkConnectivity());
|
|
|
|
|
if ((connectivityResult == ConnectivityResult.mobile) || (connectivityResult == ConnectivityResult.wifi)) {
|
|
|
|
|
return true;
|
|
|
|
|
@ -101,9 +101,14 @@ class Utils {
|
|
|
|
|
static showPermissionConsentDialog(BuildContext context, String message, VoidCallback? onTap) {
|
|
|
|
|
showDialog(
|
|
|
|
|
context: context,
|
|
|
|
|
builder: (cxt) => CovidConsentDialog(
|
|
|
|
|
okTitle: TranslationBase.of(context).acceptLbl,
|
|
|
|
|
title: TranslationBase.of(context).covidConsentHeader,
|
|
|
|
|
builder: (cxt) =>
|
|
|
|
|
CovidConsentDialog(
|
|
|
|
|
okTitle: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.acceptLbl,
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.covidConsentHeader,
|
|
|
|
|
message: message,
|
|
|
|
|
onTap: onTap!,
|
|
|
|
|
));
|
|
|
|
|
@ -156,19 +161,21 @@ class Utils {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
static String getAdvancePaymentTransID(int projectID, int fileNumber) {
|
|
|
|
|
return projectID.toString() + '-' + fileNumber.toString() + '-' + DateTime.now().millisecondsSinceEpoch.toString();
|
|
|
|
|
return projectID.toString() + '-' + fileNumber.toString() + '-' + DateTime
|
|
|
|
|
.now()
|
|
|
|
|
.millisecondsSinceEpoch
|
|
|
|
|
.toString();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
bool validateIDBox(String value, type) {
|
|
|
|
|
String pattern = loginIDPattern(type).toString(); //r'^\d+(?:\.\d+)?$';
|
|
|
|
|
|
|
|
|
|
RegExp regex = new RegExp(pattern);
|
|
|
|
|
bool validateIDBox(String value, int type) {
|
|
|
|
|
String pattern = loginIDPattern(type); // Get the pattern based on type
|
|
|
|
|
RegExp regex = RegExp(pattern);
|
|
|
|
|
return regex.hasMatch(value);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
String loginIDPattern(loginType) {
|
|
|
|
|
String loginIDPattern(int loginType) {
|
|
|
|
|
var length = loginType == 1 ? 10 : 1;
|
|
|
|
|
return "([0-9]{" + length.toString() + "})";
|
|
|
|
|
return "([0-9]{$length})";
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
static showProgressDialog(context, [String message = "Loading..."]) async {
|
|
|
|
|
@ -226,74 +233,86 @@ class Utils {
|
|
|
|
|
onTap: () => projectViewModel!.havePrivilege(5) ? Navigator.push(context!, FadePage(page: MyAppointments())) : null,
|
|
|
|
|
child: isLogin!
|
|
|
|
|
? Stack(children: [
|
|
|
|
|
Container(
|
|
|
|
|
width: double.infinity,
|
|
|
|
|
height: double.infinity,
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context!).myAppointments,
|
|
|
|
|
imagePath: 'appointment_list.svg',
|
|
|
|
|
subTitle: TranslationBase.of(context!).myAppointmentsList,
|
|
|
|
|
hasBadge: true,
|
|
|
|
|
isEnable: projectViewModel!.havePrivilege(5)),
|
|
|
|
|
),
|
|
|
|
|
projectViewModel.isArabic
|
|
|
|
|
? !projectViewModel.user!.isFamily
|
|
|
|
|
? Positioned(
|
|
|
|
|
left: 8,
|
|
|
|
|
top: 4,
|
|
|
|
|
child: badge_import.Badge(
|
|
|
|
|
badgeAnimation: badge_import.BadgeAnimation.fade(toAnimate: false),
|
|
|
|
|
badgeStyle: badge_import.BadgeStyle(
|
|
|
|
|
elevation: 0,
|
|
|
|
|
shape: badge_import.BadgeShape.circle,
|
|
|
|
|
badgeColor: secondaryColor!.withOpacity(1.0),
|
|
|
|
|
borderRadius: BorderRadius.circular(8),
|
|
|
|
|
),
|
|
|
|
|
position: badge_import.BadgePosition.topEnd(),
|
|
|
|
|
badgeContent: Container(
|
|
|
|
|
padding: EdgeInsets.all(2.0),
|
|
|
|
|
child: Text(count.toString(), style: TextStyle(color: Colors.white, fontWeight: FontWeight.bold, fontSize: 12.0)),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
)
|
|
|
|
|
: Container()
|
|
|
|
|
: !projectViewModel.user!.isFamily
|
|
|
|
|
? Positioned(
|
|
|
|
|
right: 8,
|
|
|
|
|
top: 4,
|
|
|
|
|
child: badge_import.Badge(
|
|
|
|
|
position: badge_import.BadgePosition.topEnd(),
|
|
|
|
|
badgeAnimation: badge_import.BadgeAnimation.fade(toAnimate: false),
|
|
|
|
|
badgeStyle: badge_import.BadgeStyle(
|
|
|
|
|
elevation: 0,
|
|
|
|
|
shape: badge_import.BadgeShape.circle,
|
|
|
|
|
badgeColor: secondaryColor!.withOpacity(1.0),
|
|
|
|
|
borderRadius: BorderRadius.circular(8),
|
|
|
|
|
),
|
|
|
|
|
badgeContent: Container(
|
|
|
|
|
padding: EdgeInsets.all(2.0),
|
|
|
|
|
child: Text(count.toString(), style: TextStyle(color: Colors.white, fontWeight: FontWeight.bold, fontSize: 12.0)),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
)
|
|
|
|
|
: Container(),
|
|
|
|
|
])
|
|
|
|
|
: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context!).myAppointments,
|
|
|
|
|
Container(
|
|
|
|
|
width: double.infinity,
|
|
|
|
|
height: double.infinity,
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context!)
|
|
|
|
|
.myAppointments,
|
|
|
|
|
imagePath: 'appointment_list.svg',
|
|
|
|
|
subTitle: TranslationBase.of(context!).myAppointmentsList,
|
|
|
|
|
subTitle: TranslationBase
|
|
|
|
|
.of(context!)
|
|
|
|
|
.myAppointmentsList,
|
|
|
|
|
hasBadge: true,
|
|
|
|
|
isEnable: projectViewModel!.havePrivilege(5),
|
|
|
|
|
isEnable: projectViewModel!.havePrivilege(5)),
|
|
|
|
|
),
|
|
|
|
|
projectViewModel.isArabic
|
|
|
|
|
? !projectViewModel.user!.isFamily
|
|
|
|
|
? Positioned(
|
|
|
|
|
left: 8,
|
|
|
|
|
top: 4,
|
|
|
|
|
child: badge_import.Badge(
|
|
|
|
|
badgeAnimation: badge_import.BadgeAnimation.fade(toAnimate: false),
|
|
|
|
|
badgeStyle: badge_import.BadgeStyle(
|
|
|
|
|
elevation: 0,
|
|
|
|
|
shape: badge_import.BadgeShape.circle,
|
|
|
|
|
badgeColor: secondaryColor!.withOpacity(1.0),
|
|
|
|
|
borderRadius: BorderRadius.circular(8),
|
|
|
|
|
),
|
|
|
|
|
position: badge_import.BadgePosition.topEnd(),
|
|
|
|
|
badgeContent: Container(
|
|
|
|
|
padding: EdgeInsets.all(2.0),
|
|
|
|
|
child: Text(count.toString(), style: TextStyle(color: Colors.white, fontWeight: FontWeight.bold, fontSize: 12.0)),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
)
|
|
|
|
|
: Container()
|
|
|
|
|
: !projectViewModel.user!.isFamily
|
|
|
|
|
? Positioned(
|
|
|
|
|
right: 8,
|
|
|
|
|
top: 4,
|
|
|
|
|
child: badge_import.Badge(
|
|
|
|
|
position: badge_import.BadgePosition.topEnd(),
|
|
|
|
|
badgeAnimation: badge_import.BadgeAnimation.fade(toAnimate: false),
|
|
|
|
|
badgeStyle: badge_import.BadgeStyle(
|
|
|
|
|
elevation: 0,
|
|
|
|
|
shape: badge_import.BadgeShape.circle,
|
|
|
|
|
badgeColor: secondaryColor!.withOpacity(1.0),
|
|
|
|
|
borderRadius: BorderRadius.circular(8),
|
|
|
|
|
),
|
|
|
|
|
badgeContent: Container(
|
|
|
|
|
padding: EdgeInsets.all(2.0),
|
|
|
|
|
child: Text(count.toString(), style: TextStyle(color: Colors.white, fontWeight: FontWeight.bold, fontSize: 12.0)),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
)
|
|
|
|
|
: Container(),
|
|
|
|
|
])
|
|
|
|
|
: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context!)
|
|
|
|
|
.myAppointments,
|
|
|
|
|
imagePath: 'appointment_list.svg',
|
|
|
|
|
subTitle: TranslationBase
|
|
|
|
|
.of(context!)
|
|
|
|
|
.myAppointmentsList,
|
|
|
|
|
hasBadge: true,
|
|
|
|
|
isEnable: projectViewModel!.havePrivilege(5),
|
|
|
|
|
),
|
|
|
|
|
));
|
|
|
|
|
|
|
|
|
|
if (projectViewModel.havePrivilege(10)) {
|
|
|
|
|
medical.add(InkWell(
|
|
|
|
|
onTap: () => Navigator.push(context, FadePage(page: LabsHomePage())),
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context).lab,
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.lab,
|
|
|
|
|
imagePath: 'lab_result.svg',
|
|
|
|
|
subTitle: TranslationBase.of(context).labSubtitle,
|
|
|
|
|
subTitle: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.labSubtitle,
|
|
|
|
|
),
|
|
|
|
|
));
|
|
|
|
|
}
|
|
|
|
|
@ -301,9 +320,13 @@ class Utils {
|
|
|
|
|
medical.add(InkWell(
|
|
|
|
|
onTap: () => projectViewModel.havePrivilege(7) ? Navigator.push(context, FadePage(page: RadiologyHomePage())) : null,
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context).radiology,
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.radiology,
|
|
|
|
|
imagePath: 'radiology.svg',
|
|
|
|
|
subTitle: TranslationBase.of(context).radiologySubtitle,
|
|
|
|
|
subTitle: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.radiologySubtitle,
|
|
|
|
|
isEnable: projectViewModel.havePrivilege(7),
|
|
|
|
|
),
|
|
|
|
|
));
|
|
|
|
|
@ -311,24 +334,33 @@ class Utils {
|
|
|
|
|
medical.add(InkWell(
|
|
|
|
|
onTap: () => projectViewModel.havePrivilege(12) ? Navigator.push(context, FadePage(page: HomePrescriptionsPage())) : null,
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context).medicines,
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.medicines,
|
|
|
|
|
imagePath: 'medicine_prescription.svg',
|
|
|
|
|
subTitle: TranslationBase.of(context).medicinesSubtitle,
|
|
|
|
|
subTitle: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.medicinesSubtitle,
|
|
|
|
|
isEnable: projectViewModel.havePrivilege(12),
|
|
|
|
|
),
|
|
|
|
|
));
|
|
|
|
|
|
|
|
|
|
medical.add(InkWell(
|
|
|
|
|
onTap: () => projectViewModel.havePrivilege(25)
|
|
|
|
|
onTap: () =>
|
|
|
|
|
projectViewModel.havePrivilege(25)
|
|
|
|
|
? Navigator.push(
|
|
|
|
|
context,
|
|
|
|
|
FadePage(page: VitalSignDetailsScreen()),
|
|
|
|
|
)
|
|
|
|
|
context,
|
|
|
|
|
FadePage(page: VitalSignDetailsScreen()),
|
|
|
|
|
)
|
|
|
|
|
: null,
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context).vitalSigns,
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.vitalSigns,
|
|
|
|
|
imagePath: 'vital_signs.svg',
|
|
|
|
|
subTitle: TranslationBase.of(context).vitalSignsSubtitle,
|
|
|
|
|
subTitle: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.vitalSignsSubtitle,
|
|
|
|
|
isEnable: projectViewModel.havePrivilege(25),
|
|
|
|
|
),
|
|
|
|
|
));
|
|
|
|
|
@ -338,32 +370,45 @@ class Utils {
|
|
|
|
|
if (projectViewModel.havePrivilege(48)) Navigator.push(context, FadePage(page: ActiveMedicationsPage()));
|
|
|
|
|
},
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context).myMedical,
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.myMedical,
|
|
|
|
|
imagePath: 'active_medication.svg',
|
|
|
|
|
subTitle: TranslationBase.of(context).myMedicalSubtitle,
|
|
|
|
|
subTitle: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.myMedicalSubtitle,
|
|
|
|
|
isEnable: projectViewModel.havePrivilege(48),
|
|
|
|
|
),
|
|
|
|
|
));
|
|
|
|
|
|
|
|
|
|
medical.add(InkWell(
|
|
|
|
|
onTap: () => projectViewModel.havePrivilege(6)
|
|
|
|
|
onTap: () =>
|
|
|
|
|
projectViewModel.havePrivilege(6)
|
|
|
|
|
? Navigator.push(
|
|
|
|
|
context,
|
|
|
|
|
FadePage(
|
|
|
|
|
page: DoctorHomePage(),
|
|
|
|
|
),
|
|
|
|
|
)
|
|
|
|
|
context,
|
|
|
|
|
FadePage(
|
|
|
|
|
page: DoctorHomePage(),
|
|
|
|
|
),
|
|
|
|
|
)
|
|
|
|
|
: null,
|
|
|
|
|
child:
|
|
|
|
|
MedicalProfileItem(title: TranslationBase.of(context).myDoctor, imagePath: 'my_doc.svg', subTitle: TranslationBase.of(context).myDoctorSubtitle, isEnable: projectViewModel.havePrivilege(6)),
|
|
|
|
|
MedicalProfileItem(title: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.myDoctor, imagePath: 'my_doc.svg', subTitle: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.myDoctorSubtitle, isEnable: projectViewModel.havePrivilege(6)),
|
|
|
|
|
));
|
|
|
|
|
|
|
|
|
|
medical.add(InkWell(
|
|
|
|
|
onTap: () => projectViewModel.havePrivilege(14) ? Navigator.push(context, FadePage(page: MyInvoices())) : null,
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context).invoicesList,
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.invoicesList,
|
|
|
|
|
imagePath: 'invoice_list.svg',
|
|
|
|
|
subTitle: TranslationBase.of(context).myInvoice,
|
|
|
|
|
subTitle: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.myInvoice,
|
|
|
|
|
isEnable: projectViewModel.havePrivilege(14),
|
|
|
|
|
),
|
|
|
|
|
));
|
|
|
|
|
@ -372,10 +417,14 @@ class Utils {
|
|
|
|
|
onTap: () => projectViewModel.havePrivilege(85) ? Navigator.push(context, FadePage(page: AnicllaryOrders())) : null,
|
|
|
|
|
// onTap: () => Navigator.push(context, FadePage(page: AnicllaryOrders())),
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context).anicllaryOrders,
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.anicllaryOrders,
|
|
|
|
|
imagePath: 'ancillary.svg',
|
|
|
|
|
isPngImage: false,
|
|
|
|
|
subTitle: TranslationBase.of(context).myInvoice,
|
|
|
|
|
subTitle: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.myInvoice,
|
|
|
|
|
isEnable: projectViewModel.havePrivilege(85),
|
|
|
|
|
),
|
|
|
|
|
));
|
|
|
|
|
@ -383,19 +432,35 @@ class Utils {
|
|
|
|
|
medical.add(InkWell(
|
|
|
|
|
onTap: () => projectViewModel.havePrivilege(14) ? Navigator.push(context, FadePage(page: EyeMeasurementsPage())) : null,
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context).eye,
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.eye,
|
|
|
|
|
imagePath: 'eye_measurement.svg',
|
|
|
|
|
subTitle: TranslationBase.of(context).eyeSubtitle,
|
|
|
|
|
subTitle: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.eyeSubtitle,
|
|
|
|
|
isEnable: projectViewModel.havePrivilege(14),
|
|
|
|
|
),
|
|
|
|
|
));
|
|
|
|
|
|
|
|
|
|
medical.add(InkWell(
|
|
|
|
|
onTap: () => projectViewModel.havePrivilege(22) ? Navigator.push(context, FadePage(page: InsuranceCard(appointmentNo: 0,))) : null,
|
|
|
|
|
onTap: () =>
|
|
|
|
|
projectViewModel.havePrivilege(22)
|
|
|
|
|
? Navigator.push(
|
|
|
|
|
context,
|
|
|
|
|
FadePage(
|
|
|
|
|
page: InsuranceCard(
|
|
|
|
|
appointmentNo: 0,
|
|
|
|
|
)))
|
|
|
|
|
: null,
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context).insurance,
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.insurance,
|
|
|
|
|
imagePath: 'insurance_card.svg',
|
|
|
|
|
subTitle: TranslationBase.of(context).insuranceSubtitle,
|
|
|
|
|
subTitle: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.insuranceSubtitle,
|
|
|
|
|
isEnable: projectViewModel.havePrivilege(22),
|
|
|
|
|
),
|
|
|
|
|
));
|
|
|
|
|
@ -405,18 +470,34 @@ class Utils {
|
|
|
|
|
Navigator.push(context, FadePage(page: InsuranceUpdate()));
|
|
|
|
|
},
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context).updateInsurance,
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.updateInsurance,
|
|
|
|
|
imagePath: 'insurance_card.svg',
|
|
|
|
|
subTitle: TranslationBase.of(context).updateInsuranceSubtitle,
|
|
|
|
|
subTitle: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.updateInsuranceSubtitle,
|
|
|
|
|
),
|
|
|
|
|
));
|
|
|
|
|
|
|
|
|
|
medical.add(InkWell(
|
|
|
|
|
onTap: () => projectViewModel.havePrivilege(18) ? Navigator.push(context, FadePage(page: InsuranceApproval(appointmentNo: 0,))) : null,
|
|
|
|
|
onTap: () =>
|
|
|
|
|
projectViewModel.havePrivilege(18)
|
|
|
|
|
? Navigator.push(
|
|
|
|
|
context,
|
|
|
|
|
FadePage(
|
|
|
|
|
page: InsuranceApproval(
|
|
|
|
|
appointmentNo: 0,
|
|
|
|
|
)))
|
|
|
|
|
: null,
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context).insuranceApproval,
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.insuranceApproval,
|
|
|
|
|
imagePath: 'insurance_approval.svg',
|
|
|
|
|
subTitle: TranslationBase.of(context).insuranceApprovalSubtitle,
|
|
|
|
|
subTitle: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.insuranceApprovalSubtitle,
|
|
|
|
|
isEnable: projectViewModel.havePrivilege(18),
|
|
|
|
|
),
|
|
|
|
|
));
|
|
|
|
|
@ -424,9 +505,13 @@ class Utils {
|
|
|
|
|
medical.add(InkWell(
|
|
|
|
|
onTap: () => projectViewModel.havePrivilege(23) ? Navigator.push(context, FadePage(page: AllergiesPage())) : null,
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context).allergies,
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.allergies,
|
|
|
|
|
imagePath: 'allergies_diagnosed.svg',
|
|
|
|
|
subTitle: TranslationBase.of(context).allergiesSubtitle,
|
|
|
|
|
subTitle: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.allergiesSubtitle,
|
|
|
|
|
isEnable: projectViewModel.havePrivilege(23),
|
|
|
|
|
),
|
|
|
|
|
));
|
|
|
|
|
@ -434,9 +519,13 @@ class Utils {
|
|
|
|
|
medical.add(InkWell(
|
|
|
|
|
onTap: () => projectViewModel.havePrivilege(26) ? Navigator.push(context, FadePage(page: MyVaccines())) : null,
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context).myVaccines,
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.myVaccines,
|
|
|
|
|
imagePath: 'vaccine_list.svg',
|
|
|
|
|
subTitle: TranslationBase.of(context).myVaccinesSubtitle,
|
|
|
|
|
subTitle: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.myVaccinesSubtitle,
|
|
|
|
|
isEnable: projectViewModel.havePrivilege(26),
|
|
|
|
|
),
|
|
|
|
|
));
|
|
|
|
|
@ -444,9 +533,13 @@ class Utils {
|
|
|
|
|
medical.add(InkWell(
|
|
|
|
|
onTap: () => projectViewModel.havePrivilege(20) ? Navigator.push(context, FadePage(page: HomeReportPage())) : null,
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context).medical,
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.medical,
|
|
|
|
|
imagePath: 'medical_report.svg',
|
|
|
|
|
subTitle: TranslationBase.of(context).medicalSubtitle,
|
|
|
|
|
subTitle: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.medicalSubtitle,
|
|
|
|
|
isEnable: projectViewModel.havePrivilege(20),
|
|
|
|
|
),
|
|
|
|
|
));
|
|
|
|
|
@ -454,9 +547,13 @@ class Utils {
|
|
|
|
|
medical.add(InkWell(
|
|
|
|
|
onTap: () => projectViewModel.havePrivilege(19) ? Navigator.push(context, FadePage(page: MonthlyReportsPage())) : null,
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context).monthly,
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.monthly,
|
|
|
|
|
imagePath: 'monthly_report.svg',
|
|
|
|
|
subTitle: TranslationBase.of(context).monthlySubtitle,
|
|
|
|
|
subTitle: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.monthlySubtitle,
|
|
|
|
|
isEnable: projectViewModel.havePrivilege(19),
|
|
|
|
|
),
|
|
|
|
|
));
|
|
|
|
|
@ -464,9 +561,13 @@ class Utils {
|
|
|
|
|
medical.add(InkWell(
|
|
|
|
|
onTap: () => projectViewModel.havePrivilege(16) ? Navigator.push(context, FadePage(page: PatientSickLeavePage())) : null,
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context).sick,
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.sick,
|
|
|
|
|
imagePath: 'sick_leave.svg',
|
|
|
|
|
subTitle: TranslationBase.of(context).sickSubtitle,
|
|
|
|
|
subTitle: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.sickSubtitle,
|
|
|
|
|
isEnable: projectViewModel.havePrivilege(16),
|
|
|
|
|
),
|
|
|
|
|
));
|
|
|
|
|
@ -474,9 +575,13 @@ class Utils {
|
|
|
|
|
medical.add(InkWell(
|
|
|
|
|
onTap: () => projectViewModel.havePrivilege(47) ? Navigator.push(context, FadePage(page: MyBalancePage())) : null,
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context).myBalance,
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.myBalance,
|
|
|
|
|
imagePath: 'balance_credit.svg',
|
|
|
|
|
subTitle: TranslationBase.of(context).myBalanceSubtitle,
|
|
|
|
|
subTitle: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.myBalanceSubtitle,
|
|
|
|
|
isEnable: projectViewModel.havePrivilege(47),
|
|
|
|
|
),
|
|
|
|
|
));
|
|
|
|
|
@ -491,9 +596,13 @@ class Utils {
|
|
|
|
|
medical.add(InkWell(
|
|
|
|
|
onTap: () => projectViewModel.havePrivilege(24) ? Navigator.push(context, FadePage(page: MyTrackers())) : null,
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context).myTrackers,
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.myTrackers,
|
|
|
|
|
imagePath: 'tracker.svg',
|
|
|
|
|
subTitle: TranslationBase.of(context).myTrackersSubtitle,
|
|
|
|
|
subTitle: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.myTrackersSubtitle,
|
|
|
|
|
isEnable: projectViewModel.havePrivilege(24),
|
|
|
|
|
),
|
|
|
|
|
));
|
|
|
|
|
@ -501,9 +610,13 @@ class Utils {
|
|
|
|
|
medical.add(InkWell(
|
|
|
|
|
onTap: () => projectViewModel.havePrivilege(30) ? Navigator.push(context, FadePage(page: SmartWatchInstructions())) : null,
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context).smartWatchesSubtitle,
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.smartWatchesSubtitle,
|
|
|
|
|
imagePath: 'smart_watch.svg',
|
|
|
|
|
subTitle: TranslationBase.of(context).smartWatches,
|
|
|
|
|
subTitle: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.smartWatches,
|
|
|
|
|
isEnable: projectViewModel.havePrivilege(30),
|
|
|
|
|
),
|
|
|
|
|
));
|
|
|
|
|
@ -511,14 +624,20 @@ class Utils {
|
|
|
|
|
medical.add(InkWell(
|
|
|
|
|
onTap: () => projectViewModel.havePrivilege(28) ? Navigator.push(context, FadePage(page: AskDoctorHomPage())) : null,
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context).askYourSubtitle, imagePath: 'ask_doctor.svg', subTitle: TranslationBase.of(context).askYour, isEnable: projectViewModel.havePrivilege(28)),
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.askYourSubtitle, imagePath: 'ask_doctor.svg', subTitle: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.askYour, isEnable: projectViewModel.havePrivilege(28)),
|
|
|
|
|
));
|
|
|
|
|
|
|
|
|
|
if (projectViewModel.havePrivilege(32) || true) {
|
|
|
|
|
medical.add(InkWell(
|
|
|
|
|
onTap: () {
|
|
|
|
|
if (Platform.isAndroid) {
|
|
|
|
|
showPermissionConsentDialog(context, TranslationBase.of(context).wifiPermission, () {
|
|
|
|
|
showPermissionConsentDialog(context, TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.wifiPermission, () {
|
|
|
|
|
connectWifi(projectViewModel, context);
|
|
|
|
|
});
|
|
|
|
|
} else {
|
|
|
|
|
@ -526,9 +645,13 @@ class Utils {
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context).internet,
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.internet,
|
|
|
|
|
imagePath: 'internet_connection.svg',
|
|
|
|
|
subTitle: TranslationBase.of(context).internetSubtitle,
|
|
|
|
|
subTitle: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.internetSubtitle,
|
|
|
|
|
),
|
|
|
|
|
));
|
|
|
|
|
}
|
|
|
|
|
@ -536,9 +659,13 @@ class Utils {
|
|
|
|
|
medical.add(InkWell(
|
|
|
|
|
onTap: () => projectViewModel.havePrivilege(40) ? launch('whatsapp://send?phone=18885521858&text=') : null,
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context).chatbot,
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.chatbot,
|
|
|
|
|
imagePath: 'chatbot.svg',
|
|
|
|
|
subTitle: TranslationBase.of(context).chatbotSubtitle,
|
|
|
|
|
subTitle: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.chatbotSubtitle,
|
|
|
|
|
isEnable: projectViewModel.havePrivilege(40),
|
|
|
|
|
),
|
|
|
|
|
));
|
|
|
|
|
@ -607,69 +734,81 @@ class Utils {
|
|
|
|
|
onTap: () => projectViewModel!.havePrivilege(5) ? Navigator.push(context!, FadePage(page: MyAppointments())) : null,
|
|
|
|
|
child: isLogin!
|
|
|
|
|
? Stack(children: [
|
|
|
|
|
MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context!).myAppointments,
|
|
|
|
|
imagePath: 'appointment_list.svg',
|
|
|
|
|
subTitle: TranslationBase.of(context!).myAppointmentsList,
|
|
|
|
|
hasBadge: true,
|
|
|
|
|
isEnable: projectViewModel!.havePrivilege(5)),
|
|
|
|
|
projectViewModel.isArabic!
|
|
|
|
|
? !projectViewModel.isLoginChild
|
|
|
|
|
? Positioned(
|
|
|
|
|
left: 8,
|
|
|
|
|
top: 4,
|
|
|
|
|
child: badge_import.Badge(
|
|
|
|
|
position: badge_import.BadgePosition.topEnd(),
|
|
|
|
|
badgeAnimation: badge_import.BadgeAnimation.fade(toAnimate: false),
|
|
|
|
|
badgeStyle: badge_import.BadgeStyle(
|
|
|
|
|
elevation: 0,
|
|
|
|
|
shape: badge_import.BadgeShape.circle,
|
|
|
|
|
badgeColor: secondaryColor!.withOpacity(1.0),
|
|
|
|
|
borderRadius: BorderRadius.circular(8),
|
|
|
|
|
),
|
|
|
|
|
badgeContent: Container(
|
|
|
|
|
padding: EdgeInsets.all(2.0),
|
|
|
|
|
child: Text(count.toString(), style: TextStyle(color: Colors.white, fontWeight: FontWeight.bold, fontSize: 12.0)),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
)
|
|
|
|
|
: Container()
|
|
|
|
|
: !projectViewModel.isLoginChild
|
|
|
|
|
? Positioned(
|
|
|
|
|
right: 8,
|
|
|
|
|
top: 4,
|
|
|
|
|
child: badge_import.Badge(
|
|
|
|
|
badgeAnimation: badge_import.BadgeAnimation.fade(toAnimate: false),
|
|
|
|
|
badgeStyle: badge_import.BadgeStyle(
|
|
|
|
|
elevation: 0,
|
|
|
|
|
shape: badge_import.BadgeShape.circle,
|
|
|
|
|
badgeColor: secondaryColor!.withOpacity(1.0),
|
|
|
|
|
borderRadius: BorderRadius.circular(8),
|
|
|
|
|
),
|
|
|
|
|
position: badge_import.BadgePosition.topEnd(),
|
|
|
|
|
badgeContent: Container(
|
|
|
|
|
padding: EdgeInsets.all(2.0),
|
|
|
|
|
child: Text(count.toString(), style: TextStyle(color: Colors.white, fontWeight: FontWeight.bold, fontSize: 12.0)),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
)
|
|
|
|
|
: Container(),
|
|
|
|
|
])
|
|
|
|
|
: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context!).myAppointments,
|
|
|
|
|
imagePath: 'appointment_list.svg',
|
|
|
|
|
subTitle: TranslationBase.of(context!).myAppointmentsList,
|
|
|
|
|
hasBadge: true,
|
|
|
|
|
isEnable: projectViewModel!.havePrivilege(5),
|
|
|
|
|
MedicalProfileItem(
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context!)
|
|
|
|
|
.myAppointments,
|
|
|
|
|
imagePath: 'appointment_list.svg',
|
|
|
|
|
subTitle: TranslationBase
|
|
|
|
|
.of(context!)
|
|
|
|
|
.myAppointmentsList,
|
|
|
|
|
hasBadge: true,
|
|
|
|
|
isEnable: projectViewModel!.havePrivilege(5)),
|
|
|
|
|
projectViewModel.isArabic!
|
|
|
|
|
? !projectViewModel.isLoginChild
|
|
|
|
|
? Positioned(
|
|
|
|
|
left: 8,
|
|
|
|
|
top: 4,
|
|
|
|
|
child: badge_import.Badge(
|
|
|
|
|
position: badge_import.BadgePosition.topEnd(),
|
|
|
|
|
badgeAnimation: badge_import.BadgeAnimation.fade(toAnimate: false),
|
|
|
|
|
badgeStyle: badge_import.BadgeStyle(
|
|
|
|
|
elevation: 0,
|
|
|
|
|
shape: badge_import.BadgeShape.circle,
|
|
|
|
|
badgeColor: secondaryColor!.withOpacity(1.0),
|
|
|
|
|
borderRadius: BorderRadius.circular(8),
|
|
|
|
|
),
|
|
|
|
|
badgeContent: Container(
|
|
|
|
|
padding: EdgeInsets.all(2.0),
|
|
|
|
|
child: Text(count.toString(), style: TextStyle(color: Colors.white, fontWeight: FontWeight.bold, fontSize: 12.0)),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
)
|
|
|
|
|
: Container()
|
|
|
|
|
: !projectViewModel.isLoginChild
|
|
|
|
|
? Positioned(
|
|
|
|
|
right: 8,
|
|
|
|
|
top: 4,
|
|
|
|
|
child: badge_import.Badge(
|
|
|
|
|
badgeAnimation: badge_import.BadgeAnimation.fade(toAnimate: false),
|
|
|
|
|
badgeStyle: badge_import.BadgeStyle(
|
|
|
|
|
elevation: 0,
|
|
|
|
|
shape: badge_import.BadgeShape.circle,
|
|
|
|
|
badgeColor: secondaryColor!.withOpacity(1.0),
|
|
|
|
|
borderRadius: BorderRadius.circular(8),
|
|
|
|
|
),
|
|
|
|
|
position: badge_import.BadgePosition.topEnd(),
|
|
|
|
|
badgeContent: Container(
|
|
|
|
|
padding: EdgeInsets.all(2.0),
|
|
|
|
|
child: Text(count.toString(), style: TextStyle(color: Colors.white, fontWeight: FontWeight.bold, fontSize: 12.0)),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
)
|
|
|
|
|
: Container(),
|
|
|
|
|
])
|
|
|
|
|
: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context!)
|
|
|
|
|
.myAppointments,
|
|
|
|
|
imagePath: 'appointment_list.svg',
|
|
|
|
|
subTitle: TranslationBase
|
|
|
|
|
.of(context!)
|
|
|
|
|
.myAppointmentsList,
|
|
|
|
|
hasBadge: true,
|
|
|
|
|
isEnable: projectViewModel!.havePrivilege(5),
|
|
|
|
|
),
|
|
|
|
|
));
|
|
|
|
|
|
|
|
|
|
medical.add(InkWell(
|
|
|
|
|
onTap: () => projectViewModel.havePrivilege(10) ? Navigator.push(context, FadePage(page: LabsHomePage())) : null,
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context).lab,
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.lab,
|
|
|
|
|
imagePath: 'lab_result.svg',
|
|
|
|
|
subTitle: TranslationBase.of(context).labSubtitle,
|
|
|
|
|
subTitle: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.labSubtitle,
|
|
|
|
|
isEnable: projectViewModel.havePrivilege(10),
|
|
|
|
|
),
|
|
|
|
|
));
|
|
|
|
|
@ -677,9 +816,13 @@ class Utils {
|
|
|
|
|
medical.add(InkWell(
|
|
|
|
|
onTap: () => projectViewModel.havePrivilege(7) ? Navigator.push(context, FadePage(page: RadiologyHomePage())) : null,
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context).radiology,
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.radiology,
|
|
|
|
|
imagePath: 'radiology.svg',
|
|
|
|
|
subTitle: TranslationBase.of(context).radiologySubtitle,
|
|
|
|
|
subTitle: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.radiologySubtitle,
|
|
|
|
|
isEnable: projectViewModel.havePrivilege(7),
|
|
|
|
|
),
|
|
|
|
|
));
|
|
|
|
|
@ -687,24 +830,33 @@ class Utils {
|
|
|
|
|
medical.add(InkWell(
|
|
|
|
|
onTap: () => projectViewModel.havePrivilege(12) ? Navigator.push(context, FadePage(page: HomePrescriptionsPage())) : null,
|
|
|
|
|
child: MedicalProfileItem(
|
|
|
|
|
title: TranslationBase.of(context).medicines,
|
|
|
|
|
title: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.medicines,
|
|
|
|
|
imagePath: 'medicine_prescription.svg',
|
|
|
|
|
subTitle: TranslationBase.of(context).medicinesSubtitle,
|
|
|
|
|
subTitle: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.medicinesSubtitle,
|
|
|
|
|
isEnable: projectViewModel.havePrivilege(12),
|
|
|
|
|
),
|
|
|
|
|
));
|
|
|
|
|
|
|
|
|
|
medical.add(InkWell(
|
|
|
|
|
onTap: () => projectViewModel.havePrivilege(6)
|
|
|
|
|
onTap: () =>
|
|
|
|
|
projectViewModel.havePrivilege(6)
|
|
|
|
|
? Navigator.push(
|
|
|
|
|
context,
|
|
|
|
|
FadePage(
|
|
|
|
|
page: DoctorHomePage(),
|
|
|
|
|
),
|
|
|
|
|
)
|
|
|
|
|
context,
|
|
|
|
|
FadePage(
|
|
|
|
|
page: DoctorHomePage(),
|
|
|
|
|
),
|
|
|
|
|
)
|
|
|
|
|
: null,
|
|
|
|
|
child:
|
|
|
|
|
MedicalProfileItem(title: TranslationBase.of(context).myDoctor, imagePath: 'my_doc.svg', subTitle: TranslationBase.of(context).myDoctorSubtitle, isEnable: projectViewModel.havePrivilege(6)),
|
|
|
|
|
MedicalProfileItem(title: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.myDoctor, imagePath: 'my_doc.svg', subTitle: TranslationBase
|
|
|
|
|
.of(context)
|
|
|
|
|
.myDoctorSubtitle, isEnable: projectViewModel.havePrivilege(6)),
|
|
|
|
|
));
|
|
|
|
|
|
|
|
|
|
return medical;
|
|
|
|
|
@ -744,7 +896,11 @@ class Utils {
|
|
|
|
|
SizedBox(height: 6),
|
|
|
|
|
Text(
|
|
|
|
|
text,
|
|
|
|
|
style: TextStyle(fontSize: 12, fontWeight: FontWeight.w600, color: Color(0xff2E303A), letterSpacing: -0.48, height: 18 / 12),
|
|
|
|
|
style: TextStyle(fontSize: 12,
|
|
|
|
|
fontWeight: FontWeight.w600,
|
|
|
|
|
color: Color(0xff2E303A),
|
|
|
|
|
letterSpacing: -0.48,
|
|
|
|
|
height: 18 / 12),
|
|
|
|
|
),
|
|
|
|
|
SizedBox(height: 5),
|
|
|
|
|
if (showDivider)
|
|
|
|
|
@ -765,10 +921,16 @@ class Utils {
|
|
|
|
|
children: [
|
|
|
|
|
SizedBox(height: 12),
|
|
|
|
|
Text(
|
|
|
|
|
isCapitable && !projectViewModel.isArabic ? text.toLowerCase().capitalizeFirstofEach : text,
|
|
|
|
|
isCapitable && !projectViewModel.isArabic ? text
|
|
|
|
|
.toLowerCase()
|
|
|
|
|
.capitalizeFirstofEach : text,
|
|
|
|
|
maxLines: 2,
|
|
|
|
|
overflow: TextOverflow.ellipsis,
|
|
|
|
|
style: TextStyle(fontSize: 12, fontWeight: FontWeight.w600, color: Color(0xff575757), letterSpacing: -0.4, height: 16 / 10),
|
|
|
|
|
style: TextStyle(fontSize: 12,
|
|
|
|
|
fontWeight: FontWeight.w600,
|
|
|
|
|
color: Color(0xff575757),
|
|
|
|
|
letterSpacing: -0.4,
|
|
|
|
|
height: 16 / 10),
|
|
|
|
|
),
|
|
|
|
|
SizedBox(height: 12),
|
|
|
|
|
if (!isLast)
|
|
|
|
|
@ -783,7 +945,10 @@ class Utils {
|
|
|
|
|
|
|
|
|
|
static Future<bool> isGoogleServicesAvailable() async {
|
|
|
|
|
GooglePlayServicesAvailability availability = await GoogleApiAvailability.instance.checkGooglePlayServicesAvailability();
|
|
|
|
|
String status = availability.toString().split('.').last;
|
|
|
|
|
String status = availability
|
|
|
|
|
.toString()
|
|
|
|
|
.split('.')
|
|
|
|
|
.last;
|
|
|
|
|
if (status == "success") {
|
|
|
|
|
return true;
|
|
|
|
|
}
|
|
|
|
|
@ -798,10 +963,17 @@ class Utils {
|
|
|
|
|
children: [
|
|
|
|
|
SizedBox(height: 14),
|
|
|
|
|
AutoSizeText(
|
|
|
|
|
isCapitable ? text.toLowerCase().capitalizeFirstofEach : text,
|
|
|
|
|
isCapitable ? text
|
|
|
|
|
.toLowerCase()
|
|
|
|
|
.capitalizeFirstofEach : text,
|
|
|
|
|
maxLines: 1,
|
|
|
|
|
minFontSize: 6,
|
|
|
|
|
style: TextStyle(decoration: TextDecoration.underline, fontSize: 12, fontWeight: FontWeight.w600, color: Color(0xffD02127), letterSpacing: -0.48, height: 18 / 12),
|
|
|
|
|
style: TextStyle(decoration: TextDecoration.underline,
|
|
|
|
|
fontSize: 12,
|
|
|
|
|
fontWeight: FontWeight.w600,
|
|
|
|
|
color: Color(0xffD02127),
|
|
|
|
|
letterSpacing: -0.48,
|
|
|
|
|
height: 18 / 12),
|
|
|
|
|
),
|
|
|
|
|
SizedBox(height: 10),
|
|
|
|
|
if (!isLast)
|
|
|
|
|
|