|
|
|
@ -16,20 +16,20 @@ class PatientProfileAppBar extends StatelessWidget
|
|
|
|
with PreferredSizeWidget {
|
|
|
|
with PreferredSizeWidget {
|
|
|
|
final PatientProfileAppBarModel patientProfileAppBarModel;
|
|
|
|
final PatientProfileAppBarModel patientProfileAppBarModel;
|
|
|
|
final bool isFromLabResult;
|
|
|
|
final bool isFromLabResult;
|
|
|
|
final VoidCallback onPressed;
|
|
|
|
final VoidCallback? onPressed;
|
|
|
|
|
|
|
|
|
|
|
|
PatientProfileAppBar(
|
|
|
|
PatientProfileAppBar(
|
|
|
|
{this.patientProfileAppBarModel, this.isFromLabResult=false, this.onPressed});
|
|
|
|
{required this.patientProfileAppBarModel, this.isFromLabResult=false, this.onPressed});
|
|
|
|
|
|
|
|
|
|
|
|
@override
|
|
|
|
@override
|
|
|
|
Widget build(BuildContext context) {
|
|
|
|
Widget build(BuildContext context) {
|
|
|
|
ProjectViewModel projectViewModel = Provider.of(context);
|
|
|
|
ProjectViewModel projectViewModel = Provider.of(context);
|
|
|
|
|
|
|
|
|
|
|
|
int gender = 1;
|
|
|
|
int gender = 1;
|
|
|
|
if (patientProfileAppBarModel.patient.patientDetails != null) {
|
|
|
|
if (patientProfileAppBarModel.patient!.patientDetails != null) {
|
|
|
|
gender = patientProfileAppBarModel.patient.patientDetails.gender;
|
|
|
|
gender = patientProfileAppBarModel.patient!.patientDetails!.gender!;
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|
gender = patientProfileAppBarModel.patient.gender;
|
|
|
|
gender = patientProfileAppBarModel.patient!.gender!;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
return Container(
|
|
|
|
return Container(
|
|
|
|
@ -54,22 +54,22 @@ class PatientProfileAppBar extends StatelessWidget
|
|
|
|
color: Color(0xFF2B353E), //Colors.black,
|
|
|
|
color: Color(0xFF2B353E), //Colors.black,
|
|
|
|
onPressed: () {
|
|
|
|
onPressed: () {
|
|
|
|
if(onPressed!=null)
|
|
|
|
if(onPressed!=null)
|
|
|
|
onPressed();
|
|
|
|
onPressed!();
|
|
|
|
Navigator.pop(context);
|
|
|
|
Navigator.pop(context);
|
|
|
|
},
|
|
|
|
},
|
|
|
|
),
|
|
|
|
),
|
|
|
|
Expanded(
|
|
|
|
Expanded(
|
|
|
|
child: AppText(
|
|
|
|
child: AppText(
|
|
|
|
patientProfileAppBarModel.patient.firstName != null
|
|
|
|
patientProfileAppBarModel.patient!.firstName != null
|
|
|
|
? (Helpers.capitalize(
|
|
|
|
? (Helpers.capitalize(
|
|
|
|
patientProfileAppBarModel.patient.firstName) +
|
|
|
|
patientProfileAppBarModel.patient!.firstName) +
|
|
|
|
" " +
|
|
|
|
" " +
|
|
|
|
Helpers.capitalize(
|
|
|
|
Helpers.capitalize(
|
|
|
|
patientProfileAppBarModel.patient.lastName))
|
|
|
|
patientProfileAppBarModel.patient!.lastName))
|
|
|
|
: Helpers.capitalize(
|
|
|
|
: Helpers.capitalize(
|
|
|
|
patientProfileAppBarModel.patient.fullName ??
|
|
|
|
patientProfileAppBarModel.patient!.fullName ??
|
|
|
|
patientProfileAppBarModel
|
|
|
|
patientProfileAppBarModel
|
|
|
|
.patient.patientDetails.fullName),
|
|
|
|
.patient!.patientDetails!.fullName!),
|
|
|
|
fontSize: SizeConfig.textMultiplier * 1.8,
|
|
|
|
fontSize: SizeConfig.textMultiplier * 1.8,
|
|
|
|
fontWeight: FontWeight.bold,
|
|
|
|
fontWeight: FontWeight.bold,
|
|
|
|
fontFamily: 'Poppins',
|
|
|
|
fontFamily: 'Poppins',
|
|
|
|
@ -90,7 +90,7 @@ class PatientProfileAppBar extends StatelessWidget
|
|
|
|
child: InkWell(
|
|
|
|
child: InkWell(
|
|
|
|
onTap: () {
|
|
|
|
onTap: () {
|
|
|
|
launch("tel://" +
|
|
|
|
launch("tel://" +
|
|
|
|
patientProfileAppBarModel.patient.mobileNumber);
|
|
|
|
patientProfileAppBarModel.patient!.mobileNumber!);
|
|
|
|
},
|
|
|
|
},
|
|
|
|
child: Icon(
|
|
|
|
child: Icon(
|
|
|
|
Icons.phone,
|
|
|
|
Icons.phone,
|
|
|
|
@ -121,13 +121,13 @@ class PatientProfileAppBar extends StatelessWidget
|
|
|
|
child: Column(
|
|
|
|
child: Column(
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
children: [
|
|
|
|
children: [
|
|
|
|
patientProfileAppBarModel.patient.patientStatusType != null
|
|
|
|
patientProfileAppBarModel.patient!.patientStatusType != null
|
|
|
|
? Container(
|
|
|
|
? Container(
|
|
|
|
child: Row(
|
|
|
|
child: Row(
|
|
|
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
|
children: [
|
|
|
|
children: [
|
|
|
|
patientProfileAppBarModel
|
|
|
|
patientProfileAppBarModel
|
|
|
|
.patient.patientStatusType ==
|
|
|
|
.patient!.patientStatusType ==
|
|
|
|
43
|
|
|
|
43
|
|
|
|
? AppText(
|
|
|
|
? AppText(
|
|
|
|
TranslationBase.of(context).arrivedP,
|
|
|
|
TranslationBase.of(context).arrivedP,
|
|
|
|
@ -143,14 +143,14 @@ class PatientProfileAppBar extends StatelessWidget
|
|
|
|
fontFamily: 'Poppins',
|
|
|
|
fontFamily: 'Poppins',
|
|
|
|
fontSize: 12,
|
|
|
|
fontSize: 12,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
patientProfileAppBarModel.patient.startTime !=
|
|
|
|
patientProfileAppBarModel.patient!.startTime !=
|
|
|
|
null
|
|
|
|
null
|
|
|
|
? AppText(
|
|
|
|
? AppText(
|
|
|
|
patientProfileAppBarModel
|
|
|
|
patientProfileAppBarModel
|
|
|
|
.patient.startTime !=
|
|
|
|
.patient!.startTime !=
|
|
|
|
null
|
|
|
|
null
|
|
|
|
? patientProfileAppBarModel
|
|
|
|
? patientProfileAppBarModel
|
|
|
|
.patient.startTime
|
|
|
|
.patient!.startTime
|
|
|
|
: '',
|
|
|
|
: '',
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
fontSize: 12,
|
|
|
|
fontSize: 12,
|
|
|
|
@ -180,7 +180,7 @@ class PatientProfileAppBar extends StatelessWidget
|
|
|
|
),
|
|
|
|
),
|
|
|
|
new TextSpan(
|
|
|
|
new TextSpan(
|
|
|
|
text: patientProfileAppBarModel
|
|
|
|
text: patientProfileAppBarModel
|
|
|
|
.patient.patientId
|
|
|
|
.patient!.patientId
|
|
|
|
.toString(),
|
|
|
|
.toString(),
|
|
|
|
style: TextStyle(
|
|
|
|
style: TextStyle(
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
@ -194,28 +194,28 @@ class PatientProfileAppBar extends StatelessWidget
|
|
|
|
Row(
|
|
|
|
Row(
|
|
|
|
children: [
|
|
|
|
children: [
|
|
|
|
AppText(
|
|
|
|
AppText(
|
|
|
|
patientProfileAppBarModel.patient.nationalityName ??
|
|
|
|
patientProfileAppBarModel.patient!.nationalityName ??
|
|
|
|
patientProfileAppBarModel
|
|
|
|
patientProfileAppBarModel
|
|
|
|
.patient.nationality ??
|
|
|
|
.patient!.nationality ??
|
|
|
|
patientProfileAppBarModel
|
|
|
|
patientProfileAppBarModel
|
|
|
|
.patient.nationalityId ??
|
|
|
|
.patient!.nationalityId ??
|
|
|
|
'',
|
|
|
|
'',
|
|
|
|
fontWeight: FontWeight.bold,
|
|
|
|
fontWeight: FontWeight.bold,
|
|
|
|
fontSize: 12,
|
|
|
|
fontSize: 12,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
patientProfileAppBarModel
|
|
|
|
patientProfileAppBarModel
|
|
|
|
.patient.nationalityFlagURL !=
|
|
|
|
.patient!.nationalityFlagURL !=
|
|
|
|
null
|
|
|
|
null
|
|
|
|
? ClipRRect(
|
|
|
|
? ClipRRect(
|
|
|
|
borderRadius: BorderRadius.circular(20.0),
|
|
|
|
borderRadius: BorderRadius.circular(20.0),
|
|
|
|
child: Image.network(
|
|
|
|
child: Image.network(
|
|
|
|
patientProfileAppBarModel
|
|
|
|
patientProfileAppBarModel
|
|
|
|
.patient.nationalityFlagURL,
|
|
|
|
.patient!.nationalityFlagURL!,
|
|
|
|
height: 25,
|
|
|
|
height: 25,
|
|
|
|
width: 30,
|
|
|
|
width: 30,
|
|
|
|
errorBuilder: (BuildContext context,
|
|
|
|
errorBuilder: (BuildContext context,
|
|
|
|
Object exception,
|
|
|
|
Object exception,
|
|
|
|
StackTrace stackTrace) {
|
|
|
|
StackTrace? stackTrace) {
|
|
|
|
return Text('No Image');
|
|
|
|
return Text('No Image');
|
|
|
|
},
|
|
|
|
},
|
|
|
|
))
|
|
|
|
))
|
|
|
|
@ -234,7 +234,7 @@ class PatientProfileAppBar extends StatelessWidget
|
|
|
|
),
|
|
|
|
),
|
|
|
|
children: <TextSpan>[
|
|
|
|
children: <TextSpan>[
|
|
|
|
new TextSpan(
|
|
|
|
new TextSpan(
|
|
|
|
text: TranslationBase.of(context).age + " : ",
|
|
|
|
text: TranslationBase.of(context).age! + " : ",
|
|
|
|
style: TextStyle(
|
|
|
|
style: TextStyle(
|
|
|
|
fontSize: 10,
|
|
|
|
fontSize: 10,
|
|
|
|
fontWeight: FontWeight.w600,
|
|
|
|
fontWeight: FontWeight.w600,
|
|
|
|
@ -242,7 +242,7 @@ class PatientProfileAppBar extends StatelessWidget
|
|
|
|
)),
|
|
|
|
)),
|
|
|
|
new TextSpan(
|
|
|
|
new TextSpan(
|
|
|
|
text:
|
|
|
|
text:
|
|
|
|
"${AppDateUtils.getAgeByBirthday(patientProfileAppBarModel.patient.patientDetails != null ? patientProfileAppBarModel.patient.patientDetails.dateofBirth ?? "" : patientProfileAppBarModel.patient.dateofBirth ?? "", context, isServerFormat: !patientProfileAppBarModel.isFromLiveCare)}",
|
|
|
|
"${AppDateUtils.getAgeByBirthday(patientProfileAppBarModel.patient!.patientDetails != null ? patientProfileAppBarModel.patient!.patientDetails!.dateofBirth ?? "" : patientProfileAppBarModel.patient!.dateofBirth ?? "", context, isServerFormat: !patientProfileAppBarModel.isFromLiveCare!)}",
|
|
|
|
style: TextStyle(
|
|
|
|
style: TextStyle(
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
fontSize: 12,
|
|
|
|
fontSize: 12,
|
|
|
|
@ -253,15 +253,15 @@ class PatientProfileAppBar extends StatelessWidget
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
|
|
|
|
|
|
|
|
if (patientProfileAppBarModel.patient.appointmentDate !=
|
|
|
|
if (patientProfileAppBarModel.patient!.appointmentDate !=
|
|
|
|
null &&
|
|
|
|
null &&
|
|
|
|
patientProfileAppBarModel
|
|
|
|
patientProfileAppBarModel
|
|
|
|
.patient.appointmentDate.isNotEmpty && !isFromLabResult)
|
|
|
|
.patient!.appointmentDate!.isNotEmpty && !isFromLabResult)
|
|
|
|
Row(
|
|
|
|
Row(
|
|
|
|
mainAxisAlignment: MainAxisAlignment.start,
|
|
|
|
mainAxisAlignment: MainAxisAlignment.start,
|
|
|
|
children: <Widget>[
|
|
|
|
children: <Widget>[
|
|
|
|
AppText(
|
|
|
|
AppText(
|
|
|
|
TranslationBase.of(context).appointmentDate + " : ",
|
|
|
|
TranslationBase.of(context).appointmentDate! + " : ",
|
|
|
|
fontSize: 10,
|
|
|
|
fontSize: 10,
|
|
|
|
color: Color(0xFF575757),
|
|
|
|
color: Color(0xFF575757),
|
|
|
|
fontWeight: FontWeight.w600,
|
|
|
|
fontWeight: FontWeight.w600,
|
|
|
|
@ -274,7 +274,7 @@ class PatientProfileAppBar extends StatelessWidget
|
|
|
|
AppDateUtils.getDayMonthYearDateFormatted(
|
|
|
|
AppDateUtils.getDayMonthYearDateFormatted(
|
|
|
|
AppDateUtils.convertStringToDate(
|
|
|
|
AppDateUtils.convertStringToDate(
|
|
|
|
patientProfileAppBarModel
|
|
|
|
patientProfileAppBarModel
|
|
|
|
.patient.appointmentDate)),
|
|
|
|
.patient!.appointmentDate!)),
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
fontSize: 12,
|
|
|
|
fontSize: 12,
|
|
|
|
color: Color(0xFF2E303A),
|
|
|
|
color: Color(0xFF2E303A),
|
|
|
|
@ -284,7 +284,7 @@ class PatientProfileAppBar extends StatelessWidget
|
|
|
|
)
|
|
|
|
)
|
|
|
|
],
|
|
|
|
],
|
|
|
|
),
|
|
|
|
),
|
|
|
|
if (patientProfileAppBarModel.isFromLabResult)
|
|
|
|
if (patientProfileAppBarModel.isFromLabResult!)
|
|
|
|
Container(
|
|
|
|
Container(
|
|
|
|
child: RichText(
|
|
|
|
child: RichText(
|
|
|
|
text: new TextSpan(
|
|
|
|
text: new TextSpan(
|
|
|
|
@ -304,7 +304,7 @@ class PatientProfileAppBar extends StatelessWidget
|
|
|
|
)),
|
|
|
|
)),
|
|
|
|
new TextSpan(
|
|
|
|
new TextSpan(
|
|
|
|
text:
|
|
|
|
text:
|
|
|
|
'${AppDateUtils.getDayMonthYearDateFormatted(patientProfileAppBarModel.appointmentDate, isArabic: projectViewModel.isArabic)}',
|
|
|
|
'${AppDateUtils.getDayMonthYearDateFormatted(patientProfileAppBarModel.appointmentDate!, isArabic: projectViewModel.isArabic)}',
|
|
|
|
style: TextStyle(
|
|
|
|
style: TextStyle(
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
fontSize: 12)),
|
|
|
|
fontSize: 12)),
|
|
|
|
@ -316,10 +316,10 @@ class PatientProfileAppBar extends StatelessWidget
|
|
|
|
Column(
|
|
|
|
Column(
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
children: [
|
|
|
|
children: [
|
|
|
|
if (patientProfileAppBarModel.patient.admissionDate !=
|
|
|
|
if (patientProfileAppBarModel.patient!.admissionDate !=
|
|
|
|
null &&
|
|
|
|
null &&
|
|
|
|
patientProfileAppBarModel
|
|
|
|
patientProfileAppBarModel
|
|
|
|
.patient.admissionDate.isNotEmpty)
|
|
|
|
.patient!.admissionDate!.isNotEmpty)
|
|
|
|
Container(
|
|
|
|
Container(
|
|
|
|
child: RichText(
|
|
|
|
child: RichText(
|
|
|
|
text: new TextSpan(
|
|
|
|
text: new TextSpan(
|
|
|
|
@ -332,26 +332,26 @@ class PatientProfileAppBar extends StatelessWidget
|
|
|
|
children: <TextSpan>[
|
|
|
|
children: <TextSpan>[
|
|
|
|
new TextSpan(
|
|
|
|
new TextSpan(
|
|
|
|
text: patientProfileAppBarModel
|
|
|
|
text: patientProfileAppBarModel
|
|
|
|
.patient.admissionDate ==
|
|
|
|
.patient!.admissionDate ==
|
|
|
|
null
|
|
|
|
null
|
|
|
|
? ""
|
|
|
|
? ""
|
|
|
|
: TranslationBase.of(context)
|
|
|
|
: TranslationBase.of(context)
|
|
|
|
.admissionDate +
|
|
|
|
.admissionDate! +
|
|
|
|
" : ",
|
|
|
|
" : ",
|
|
|
|
style: TextStyle(fontSize: 10)),
|
|
|
|
style: TextStyle(fontSize: 10)),
|
|
|
|
new TextSpan(
|
|
|
|
new TextSpan(
|
|
|
|
text: patientProfileAppBarModel
|
|
|
|
text: patientProfileAppBarModel
|
|
|
|
.patient.admissionDate ==
|
|
|
|
.patient!.admissionDate ==
|
|
|
|
null
|
|
|
|
null
|
|
|
|
? ""
|
|
|
|
? ""
|
|
|
|
: "${AppDateUtils.getDayMonthYearDateFormatted((AppDateUtils.getDateTimeFromServerFormat(patientProfileAppBarModel.patient.admissionDate.toString())))}",
|
|
|
|
: "${AppDateUtils.getDayMonthYearDateFormatted((AppDateUtils.getDateTimeFromServerFormat(patientProfileAppBarModel.patient!.admissionDate.toString())))}",
|
|
|
|
style: TextStyle(
|
|
|
|
style: TextStyle(
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
fontSize: 12,
|
|
|
|
fontSize: 12,
|
|
|
|
color: Color(0xFF2E303A),
|
|
|
|
color: Color(0xFF2E303A),
|
|
|
|
)),
|
|
|
|
)),
|
|
|
|
]))),
|
|
|
|
]))),
|
|
|
|
if (patientProfileAppBarModel.patient.admissionDate !=
|
|
|
|
if (patientProfileAppBarModel.patient!.admissionDate !=
|
|
|
|
null)
|
|
|
|
null)
|
|
|
|
Row(
|
|
|
|
Row(
|
|
|
|
children: [
|
|
|
|
children: [
|
|
|
|
@ -360,20 +360,20 @@ class PatientProfileAppBar extends StatelessWidget
|
|
|
|
fontSize: 10,
|
|
|
|
fontSize: 10,
|
|
|
|
fontWeight: FontWeight.w600,
|
|
|
|
fontWeight: FontWeight.w600,
|
|
|
|
color: Color(0xFF575757)),
|
|
|
|
color: Color(0xFF575757)),
|
|
|
|
if (patientProfileAppBarModel
|
|
|
|
if (patientProfileAppBarModel!
|
|
|
|
.isDischargedPatient &&
|
|
|
|
.isDischargedPatient! &&
|
|
|
|
patientProfileAppBarModel
|
|
|
|
patientProfileAppBarModel
|
|
|
|
.patient.dischargeDate !=
|
|
|
|
.patient!.dischargeDate !=
|
|
|
|
null)
|
|
|
|
null)
|
|
|
|
AppText(
|
|
|
|
AppText(
|
|
|
|
"${AppDateUtils.getDateTimeFromServerFormat(patientProfileAppBarModel.patient.dischargeDate).difference(AppDateUtils.getDateTimeFromServerFormat(patientProfileAppBarModel.patient.admissionDate)).inDays + 1}",
|
|
|
|
"${AppDateUtils.getDateTimeFromServerFormat(patientProfileAppBarModel.patient!.dischargeDate!).difference(AppDateUtils.getDateTimeFromServerFormat(patientProfileAppBarModel.patient!.admissionDate!)).inDays + 1}",
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
fontSize: 12,
|
|
|
|
fontSize: 12,
|
|
|
|
color: Color(0xFF2E303A),
|
|
|
|
color: Color(0xFF2E303A),
|
|
|
|
)
|
|
|
|
)
|
|
|
|
else
|
|
|
|
else
|
|
|
|
AppText(
|
|
|
|
AppText(
|
|
|
|
"${DateTime.now().difference(AppDateUtils.getDateTimeFromServerFormat(patientProfileAppBarModel.patient.admissionDate)).inDays + 1}",
|
|
|
|
"${DateTime.now().difference(AppDateUtils.getDateTimeFromServerFormat(patientProfileAppBarModel.patient!.admissionDate!)).inDays + 1}",
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
fontSize: 12,
|
|
|
|
fontSize: 12,
|
|
|
|
color: Color(0xFF2E303A),
|
|
|
|
color: Color(0xFF2E303A),
|
|
|
|
@ -386,7 +386,7 @@ class PatientProfileAppBar extends StatelessWidget
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
]),
|
|
|
|
]),
|
|
|
|
if (patientProfileAppBarModel.isAppointmentHeader)
|
|
|
|
if (patientProfileAppBarModel.isAppointmentHeader!)
|
|
|
|
Row(
|
|
|
|
Row(
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
children: [
|
|
|
|
children: [
|
|
|
|
@ -401,8 +401,8 @@ class PatientProfileAppBar extends StatelessWidget
|
|
|
|
shape: BoxShape.rectangle,
|
|
|
|
shape: BoxShape.rectangle,
|
|
|
|
border: Border(
|
|
|
|
border: Border(
|
|
|
|
bottom:
|
|
|
|
bottom:
|
|
|
|
BorderSide(color: Colors.grey[400], width: 2.5),
|
|
|
|
BorderSide(color: Colors.grey[400]!, width: 2.5),
|
|
|
|
left: BorderSide(color: Colors.grey[400], width: 2.5),
|
|
|
|
left: BorderSide(color: Colors.grey[400]!, width: 2.5),
|
|
|
|
)),
|
|
|
|
)),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
Expanded(
|
|
|
|
Expanded(
|
|
|
|
@ -436,7 +436,7 @@ class PatientProfileAppBar extends StatelessWidget
|
|
|
|
if (patientProfileAppBarModel.orderNo !=
|
|
|
|
if (patientProfileAppBarModel.orderNo !=
|
|
|
|
null &&
|
|
|
|
null &&
|
|
|
|
!patientProfileAppBarModel
|
|
|
|
!patientProfileAppBarModel
|
|
|
|
.isPrescriptions)
|
|
|
|
.isPrescriptions!)
|
|
|
|
Row(
|
|
|
|
Row(
|
|
|
|
children: <Widget>[
|
|
|
|
children: <Widget>[
|
|
|
|
AppText(
|
|
|
|
AppText(
|
|
|
|
@ -454,8 +454,8 @@ class PatientProfileAppBar extends StatelessWidget
|
|
|
|
),
|
|
|
|
),
|
|
|
|
if (patientProfileAppBarModel.invoiceNO !=
|
|
|
|
if (patientProfileAppBarModel.invoiceNO !=
|
|
|
|
null &&
|
|
|
|
null &&
|
|
|
|
!patientProfileAppBarModel
|
|
|
|
!patientProfileAppBarModel!
|
|
|
|
.isPrescriptions)
|
|
|
|
.isPrescriptions!)
|
|
|
|
Row(
|
|
|
|
Row(
|
|
|
|
children: <Widget>[
|
|
|
|
children: <Widget>[
|
|
|
|
AppText(
|
|
|
|
AppText(
|
|
|
|
@ -506,7 +506,7 @@ class PatientProfileAppBar extends StatelessWidget
|
|
|
|
],
|
|
|
|
],
|
|
|
|
),
|
|
|
|
),
|
|
|
|
if (patientProfileAppBarModel
|
|
|
|
if (patientProfileAppBarModel
|
|
|
|
.isMedicalFile &&
|
|
|
|
.isMedicalFile! &&
|
|
|
|
patientProfileAppBarModel.episode !=
|
|
|
|
patientProfileAppBarModel.episode !=
|
|
|
|
null)
|
|
|
|
null)
|
|
|
|
Row(
|
|
|
|
Row(
|
|
|
|
@ -525,7 +525,7 @@ class PatientProfileAppBar extends StatelessWidget
|
|
|
|
],
|
|
|
|
],
|
|
|
|
),
|
|
|
|
),
|
|
|
|
if (patientProfileAppBarModel
|
|
|
|
if (patientProfileAppBarModel
|
|
|
|
.isMedicalFile &&
|
|
|
|
.isMedicalFile! &&
|
|
|
|
patientProfileAppBarModel.visitDate !=
|
|
|
|
patientProfileAppBarModel.visitDate !=
|
|
|
|
null)
|
|
|
|
null)
|
|
|
|
Row(
|
|
|
|
Row(
|
|
|
|
@ -544,12 +544,12 @@ class PatientProfileAppBar extends StatelessWidget
|
|
|
|
],
|
|
|
|
],
|
|
|
|
),
|
|
|
|
),
|
|
|
|
if (!patientProfileAppBarModel
|
|
|
|
if (!patientProfileAppBarModel
|
|
|
|
.isMedicalFile)
|
|
|
|
.isMedicalFile!)
|
|
|
|
Row(
|
|
|
|
Row(
|
|
|
|
children: <Widget>[
|
|
|
|
children: <Widget>[
|
|
|
|
AppText(
|
|
|
|
AppText(
|
|
|
|
!patientProfileAppBarModel
|
|
|
|
!patientProfileAppBarModel
|
|
|
|
.isPrescriptions
|
|
|
|
.isPrescriptions!
|
|
|
|
? 'Result Date:'
|
|
|
|
? 'Result Date:'
|
|
|
|
: 'Prescriptions Date ',
|
|
|
|
: 'Prescriptions Date ',
|
|
|
|
fontSize: 10,
|
|
|
|
fontSize: 10,
|
|
|
|
@ -557,7 +557,7 @@ class PatientProfileAppBar extends StatelessWidget
|
|
|
|
color: Color(0xFF575757),
|
|
|
|
color: Color(0xFF575757),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
AppText(
|
|
|
|
AppText(
|
|
|
|
'${AppDateUtils.getDayMonthYearDateFormatted(patientProfileAppBarModel.appointmentDate, isArabic: projectViewModel.isArabic)}',
|
|
|
|
'${AppDateUtils.getDayMonthYearDateFormatted(patientProfileAppBarModel.appointmentDate!, isArabic: projectViewModel.isArabic)}',
|
|
|
|
fontSize: 12,
|
|
|
|
fontSize: 12,
|
|
|
|
)
|
|
|
|
)
|
|
|
|
],
|
|
|
|
],
|
|
|
|
@ -581,14 +581,14 @@ class PatientProfileAppBar extends StatelessWidget
|
|
|
|
Size get preferredSize => Size(
|
|
|
|
Size get preferredSize => Size(
|
|
|
|
double.maxFinite,
|
|
|
|
double.maxFinite,
|
|
|
|
patientProfileAppBarModel.height == 0
|
|
|
|
patientProfileAppBarModel.height == 0
|
|
|
|
? patientProfileAppBarModel.isAppointmentHeader
|
|
|
|
? patientProfileAppBarModel.isAppointmentHeader!
|
|
|
|
? 270
|
|
|
|
? 270
|
|
|
|
: ((patientProfileAppBarModel.patient.appointmentDate != null &&patientProfileAppBarModel.patient.appointmentDate.isNotEmpty )
|
|
|
|
: ((patientProfileAppBarModel.patient!.appointmentDate! != null &&patientProfileAppBarModel.patient!.appointmentDate!.isNotEmpty )
|
|
|
|
? patientProfileAppBarModel.isFromLabResult?170:150
|
|
|
|
? patientProfileAppBarModel.isFromLabResult!?170:150
|
|
|
|
: patientProfileAppBarModel.patient.admissionDate != null
|
|
|
|
: patientProfileAppBarModel.patient!.admissionDate != null
|
|
|
|
? patientProfileAppBarModel.isFromLabResult?170:150
|
|
|
|
? patientProfileAppBarModel.isFromLabResult!?170:150
|
|
|
|
: patientProfileAppBarModel.isDischargedPatient
|
|
|
|
: patientProfileAppBarModel.isDischargedPatient!
|
|
|
|
? 240
|
|
|
|
? 240!
|
|
|
|
: 130)
|
|
|
|
: 130!)
|
|
|
|
: patientProfileAppBarModel.height);
|
|
|
|
: patientProfileAppBarModel.height!);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|