small fix

merge-requests/954/head
Elham Rababh 3 years ago
parent 05b656416d
commit d9b2a618f5

@ -142,318 +142,327 @@ class _UpdateAssessmentPageState extends State<UpdateAssessmentPage>
return Container(
margin: EdgeInsets.only(
left: 5, right: 5, top: 15, bottom: 15),
child: Row(
mainAxisAlignment:
MainAxisAlignment.spaceBetween,
crossAxisAlignment:
CrossAxisAlignment.start,
child: Column(
children: [
Column(
crossAxisAlignment:
CrossAxisAlignment.start,
Row(
children: [
RichText(
text: new TextSpan(
style: new TextStyle(
fontSize: SizeConfig
.getTextMultiplierBasedOnWidth() *
3.6,
color: Color(0xFF2E303A),
fontFamily: 'Poppins',
fontWeight: FontWeight.w600,
letterSpacing: -0.4),
children: <TextSpan>[
new TextSpan(
text: "ICD : ".toUpperCase(),
),
new TextSpan(
text: assessment
.selectedICD.code
.trim()
.toUpperCase() ??
""),
],
),
),
Container(
width: MediaQuery.of(context)
.size
.width *
0.50,
child: RichText(
text: new TextSpan(
style: new TextStyle(
fontSize: SizeConfig
.getTextMultiplierBasedOnWidth() *
5,
color: Color(0xFF2E303A),
fontFamily: 'Poppins',
fontWeight: FontWeight.w600,
letterSpacing: -0.64,
),
children: <TextSpan>[
new TextSpan(
text: assessment
.selectedICD.description
.toString(),
),
],
),
),
),
RichText(
text: new TextSpan(
style: new TextStyle(
RichText(
text: new TextSpan(
style: new TextStyle(
fontSize: SizeConfig
.getTextMultiplierBasedOnWidth() *
3.5,
.getTextMultiplierBasedOnWidth() *
3.6,
color: Color(0xFF2E303A),
fontFamily: 'Poppins',
fontWeight: FontWeight.w600,
letterSpacing: -0.4),
children: <TextSpan>[
new TextSpan(
text: "ICD : ".toUpperCase(),
),
children: <TextSpan>[
new TextSpan(
text: TranslationBase.of(
context)
.appointmentNo,
style: new TextStyle(
fontSize: SizeConfig
.getTextMultiplierBasedOnWidth() *
3,
letterSpacing: -0.4,
color: Color(0xFF575757),
),
),
new TextSpan(
text: assessment.appointmentId
.toString() ??
"",
style: new TextStyle(
fontSize: SizeConfig
.getTextMultiplierBasedOnWidth() *
3.6,
letterSpacing: -0.48,
color: Color(0xFF2B353E),
),
),
],
),
new TextSpan(
text: assessment
.selectedICD.code
.trim()
.toUpperCase() ??
""),
],
),
RichText(
text: new TextSpan(
style: new TextStyle(
fontSize: SizeConfig
.getTextMultiplierBasedOnWidth() *
3,
color: Color(0xFF2E303A),
fontFamily: 'Poppins',
fontWeight: FontWeight.w600),
children: <TextSpan>[
new TextSpan(
text: TranslationBase.of(
context)
.condition +
" : ",
style: new TextStyle(
letterSpacing: -0.4,
color: Color(0xFF575757),
),
Column(
crossAxisAlignment:
CrossAxisAlignment.end,
children: [
AppText(
assessment.createdOn != null
? AppDateUtils
.getDayMonthYearDateFormatted(
DateTime.parse(
assessment
.createdOn), isMonthShort: true)
: AppDateUtils
.getDayMonthYearDateFormatted(
DateTime.now()),
fontWeight: FontWeight.w600,
fontSize: SizeConfig
.getTextMultiplierBasedOnWidth() *
3.6,
),
AppText(
assessment.createdOn != null
? AppDateUtils.getHour(
DateTime.parse(
assessment
.createdOn))
: AppDateUtils.getHour(
DateTime.now()),
fontWeight: FontWeight.w600,
color: Color(0xFF575757),
fontSize: SizeConfig
.getTextMultiplierBasedOnWidth() *
3.6,
),
],
),
],
mainAxisAlignment: MainAxisAlignment.spaceBetween,
crossAxisAlignment: CrossAxisAlignment.start,
),
Row(
mainAxisAlignment:
MainAxisAlignment.spaceBetween,
crossAxisAlignment:
CrossAxisAlignment.start,
children: [
Column(
crossAxisAlignment:
CrossAxisAlignment.start,
children: [
Container(
width: MediaQuery.of(context)
.size
.width *
0.50,
child: RichText(
text: new TextSpan(
style: new TextStyle(
fontSize: SizeConfig
.getTextMultiplierBasedOnWidth() *
4.3,
color: Color(0xFF2E303A),
fontFamily: 'Poppins',
fontWeight: FontWeight.w600,
letterSpacing: -0.64,
),
children: <TextSpan>[
new TextSpan(
text: assessment
.selectedICD.description
.toString(),
),
],
),
),
new TextSpan(
text: projectViewModel
.isArabic
? assessment
.selectedDiagnosisCondition
.nameAr
: assessment
.selectedDiagnosisCondition
.nameEn,
),
RichText(
text: new TextSpan(
style: new TextStyle(
fontSize: SizeConfig
.getTextMultiplierBasedOnWidth() *
3.6,
letterSpacing: -0.48,
color: Color(0xFF2B353E),
3.5,
color: Color(0xFF2E303A),
fontFamily: 'Poppins',
fontWeight: FontWeight.w600,
),
),
],
),
),
RichText(
text: new TextSpan(
style: new TextStyle(
fontSize: SizeConfig
.getTextMultiplierBasedOnWidth() *
3,
color: Color(0xFF2E303A),
fontFamily: 'Poppins',
fontWeight: FontWeight.w600),
children: <TextSpan>[
new TextSpan(
text: TranslationBase.of(
children: <TextSpan>[
new TextSpan(
text: TranslationBase.of(
context)
.dType +
' : ',
style: new TextStyle(
letterSpacing: -0.4,
color: Color(0xFF575757),
),
.appointmentNo,
style: new TextStyle(
fontSize: SizeConfig
.getTextMultiplierBasedOnWidth() *
3,
letterSpacing: -0.4,
color: Color(0xFF575757),
),
),
new TextSpan(
text: assessment.appointmentId
.toString() ??
"",
style: new TextStyle(
fontSize: SizeConfig
.getTextMultiplierBasedOnWidth() *
3.6,
letterSpacing: -0.48,
color: Color(0xFF2B353E),
),
),
],
),
new TextSpan(
text: projectViewModel
.isArabic
? assessment
.selectedDiagnosisType
.nameAr
: assessment
.selectedDiagnosisType
.nameEn,
),
RichText(
text: new TextSpan(
style: new TextStyle(
fontSize: SizeConfig
.getTextMultiplierBasedOnWidth() *
3.6,
letterSpacing: -0.48,
color: Color(0xFF2B353E),
),
),
],
),
),
if (assessment.doctorName != null)
RichText(
text: new TextSpan(
style: new TextStyle(
fontSize: SizeConfig
.getTextMultiplierBasedOnWidth() *
3.6,
color: Color(0xFF2E303A),
fontFamily: 'Poppins',
fontWeight:
FontWeight.w600),
children: <TextSpan>[
new TextSpan(
text: TranslationBase.of(
context)
.doctor +
' : ',
style: new TextStyle(
fontSize: SizeConfig
.getTextMultiplierBasedOnWidth() *
3,
letterSpacing: -0.4,
color: Color(0xFF575757),
color: Color(0xFF2E303A),
fontFamily: 'Poppins',
fontWeight: FontWeight.w600),
children: <TextSpan>[
new TextSpan(
text: TranslationBase.of(
context)
.condition +
" : ",
style: new TextStyle(
letterSpacing: -0.4,
color: Color(0xFF575757),
),
),
),
new TextSpan(
text:
assessment.doctorName ??
'',
style: new TextStyle(
new TextSpan(
text: projectViewModel
.isArabic
? assessment
.selectedDiagnosisCondition
.nameAr
: assessment
.selectedDiagnosisCondition
.nameEn,
style: new TextStyle(
fontSize: SizeConfig
.getTextMultiplierBasedOnWidth() *
3.6,
letterSpacing: -0.48,
color: Color(0xFF2B353E),
),
),
],
),
),
RichText(
text: new TextSpan(
style: new TextStyle(
fontSize: SizeConfig
.getTextMultiplierBasedOnWidth() *
3.6,
letterSpacing: -0.48,
color: Color(0xFF2B353E),
3,
color: Color(0xFF2E303A),
fontFamily: 'Poppins',
fontWeight: FontWeight.w600),
children: <TextSpan>[
new TextSpan(
text: TranslationBase.of(
context)
.dType +
' : ',
style: new TextStyle(
letterSpacing: -0.4,
color: Color(0xFF575757),
),
),
),
],
new TextSpan(
text: projectViewModel
.isArabic
? assessment
.selectedDiagnosisType
.nameAr
: assessment
.selectedDiagnosisType
.nameEn,
style: new TextStyle(
fontSize: SizeConfig
.getTextMultiplierBasedOnWidth() *
3.6,
letterSpacing: -0.48,
color: Color(0xFF2B353E),
),
),
],
),
),
),
SizedBox(
height: 6,
),
Row(
mainAxisAlignment:
MainAxisAlignment.start,
crossAxisAlignment:
CrossAxisAlignment.start,
children: [
if (assessment.doctorName != null)
RichText(
text: new TextSpan(
style: new TextStyle(
fontSize: SizeConfig
.getTextMultiplierBasedOnWidth() *
3.6,
color: Color(0xFF2E303A),
fontFamily: 'Poppins',
fontWeight:
FontWeight.w600),
children: <TextSpan>[
new TextSpan(
text: TranslationBase.of(
context)
.doctor +
' : ',
style: new TextStyle(
fontSize: SizeConfig
.getTextMultiplierBasedOnWidth() *
3,
letterSpacing: -0.4,
color: Color(0xFF575757),
),
),
new TextSpan(
text:
assessment.doctorName ??
'',
style: new TextStyle(
fontSize: SizeConfig
.getTextMultiplierBasedOnWidth() *
3.6,
letterSpacing: -0.48,
color: Color(0xFF2B353E),
),
),
],
),
),
SizedBox(
height: 6,
),
AppText(
(assessment.remark != null &&
assessment.remark !=
'')
? TranslationBase.of(
context)
.remarks +
" : "
: '',
fontSize: SizeConfig
.getTextMultiplierBasedOnWidth() *
3,
color: Color(0xFF2E303A),
fontFamily: 'Poppins',
fontWeight: FontWeight.w600),
RemarkText(
remark: assessment.remark ?? "",
),
],
),
],
),
Column(
crossAxisAlignment:
CrossAxisAlignment.end,
children: [
Row(
children: [
Column(
Row(
mainAxisAlignment:
MainAxisAlignment.start,
crossAxisAlignment:
CrossAxisAlignment.end,
CrossAxisAlignment.start,
children: [
AppText(
assessment.createdOn != null
? AppDateUtils
.getDayMonthYearDateFormatted(
DateTime.parse(
assessment
.createdOn))
: AppDateUtils
.getDayMonthYearDateFormatted(
DateTime.now()),
fontWeight: FontWeight.w600,
fontSize: SizeConfig
.getTextMultiplierBasedOnWidth() *
3.6,
SizedBox(
height: 6,
),
AppText(
assessment.createdOn != null
? AppDateUtils.getHour(
DateTime.parse(
assessment
.createdOn))
: AppDateUtils.getHour(
DateTime.now()),
fontWeight: FontWeight.w600,
color: Color(0xFF575757),
fontSize: SizeConfig
.getTextMultiplierBasedOnWidth() *
3.6,
(assessment.remark != null &&
assessment.remark !=
'')
? TranslationBase.of(
context)
.remarks +
" : "
: '',
fontSize: SizeConfig
.getTextMultiplierBasedOnWidth() *
3,
color: Color(0xFF2E303A),
fontFamily: 'Poppins',
fontWeight: FontWeight.w600),
RemarkText(
remark: assessment.remark ?? "",
),
],
),
],
),
SizedBox(
height: MediaQuery.of(context)
.size
.height *
0.05,
Column(
crossAxisAlignment:
CrossAxisAlignment.end,
children: [
SizedBox(
height: MediaQuery.of(context)
.size
.height *
0.05,
),
InkWell(
onTap: () {
openAssessmentDialog(context,
isUpdate: true,
assessment: assessment,
model: model);
},
child: Icon(
DoctorApp.edit,
size: 18,
),
)
],
),
InkWell(
onTap: () {
openAssessmentDialog(context,
isUpdate: true,
assessment: assessment,
model: model);
},
child: Icon(
DoctorApp.edit,
size: 18,
),
)
],
),
],

@ -5,13 +5,14 @@ import 'package:flutter/material.dart';
class HeaderRow extends StatelessWidget {
final String label;
final String value;
final bool isExpanded;
const HeaderRow({Key key, this.label, this.value}) : super(key: key);
const HeaderRow({Key key, this.label, this.value, this.isExpanded = false}) : super(key: key);
@override
Widget build(BuildContext context) {
return Row(
// crossAxisAlignment: CrossAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
AppText(
label,
@ -23,6 +24,13 @@ class HeaderRow extends StatelessWidget {
SizedBox(
width: 1,
),
isExpanded?Expanded(child: AppText(
value,
fontSize: SizeConfig.getTextMultiplierBasedOnWidth() * 3.5,
color: Color(0xFF2E303A),
fontWeight: FontWeight.w700,
isCopyable: true,
), ):
AppText(
value,
fontSize: SizeConfig.getTextMultiplierBasedOnWidth() * 3.5,

@ -343,7 +343,8 @@ class PatientProfileAppBar extends StatelessWidget with PreferredSizeWidget {
crossAxisAlignment: CrossAxisAlignment.start,
children: <Widget>[
AppText(
Helpers.convertToTitleCase('${TranslationBase.of(context).dr}$doctorName'),
Helpers.convertToTitleCase(
'${TranslationBase.of(context).dr}$doctorName'),
color: Color(0xFF2E303A),
fontWeight: FontWeight.w700,
fontSize: SizeConfig
@ -368,11 +369,15 @@ class PatientProfileAppBar extends StatelessWidget with PreferredSizeWidget {
),
if (clinic != null)
Container(
width: MediaQuery.of(context).size.width * 0.51,
width:
MediaQuery.of(context).size.width *
0.51,
child: HeaderRow(
label: 'Clinic: ',
value: Helpers.convertToTitleCase(clinic) ?? '',
),
label: 'Clinic: ',
value: Helpers.convertToTitleCase(
clinic) ??
'',
isExpanded: true),
),
if (isMedicalFile && episode != null)
HeaderRow(
@ -423,4 +428,3 @@ class PatientProfileAppBar extends StatelessWidget with PreferredSizeWidget {
(SizeConfig.isWidthLarge ? 25 : 20)
: height);
}

Loading…
Cancel
Save