|
|
|
@ -54,495 +54,510 @@ class _UpdateAssessmentPageState extends State<UpdateAssessmentPage> {
|
|
|
|
|
ProjectViewModel projectViewModel = Provider.of(context);
|
|
|
|
|
|
|
|
|
|
return BaseView<SOAPViewModel>(
|
|
|
|
|
onModelReady: (model) async {
|
|
|
|
|
widget.mySelectedAssessmentList.clear();
|
|
|
|
|
GetAssessmentReqModel getAssessmentReqModel = GetAssessmentReqModel(
|
|
|
|
|
patientMRN: widget.patientInfo.patientMRN,
|
|
|
|
|
episodeID: widget.patientInfo.episodeNo.toString(),
|
|
|
|
|
editedBy: '',
|
|
|
|
|
doctorID: '',
|
|
|
|
|
appointmentNo: widget.patientInfo.appointmentNo);
|
|
|
|
|
await model.getPatientAssessment(getAssessmentReqModel);
|
|
|
|
|
if (model.patientAssessmentList.isNotEmpty) {
|
|
|
|
|
if (model.listOfDiagnosisCondition.length == 0) {
|
|
|
|
|
await model.getMasterLookup(MasterKeysService.DiagnosisCondition);
|
|
|
|
|
}
|
|
|
|
|
if (model.listOfDiagnosisType.length == 0) {
|
|
|
|
|
await model.getMasterLookup(MasterKeysService.DiagnosisType);
|
|
|
|
|
}
|
|
|
|
|
if (model.listOfICD10.length == 0) {
|
|
|
|
|
await model.getMasterLookup(MasterKeysService.ICD10);
|
|
|
|
|
}
|
|
|
|
|
model.patientAssessmentList.forEach((element) {
|
|
|
|
|
MasterKeyModel diagnosisType = model.getOneMasterKey(
|
|
|
|
|
masterKeys: MasterKeysService.DiagnosisType,
|
|
|
|
|
id: element.diagnosisTypeID,
|
|
|
|
|
);
|
|
|
|
|
MasterKeyModel selectedICD = model.getOneMasterKey(
|
|
|
|
|
masterKeys: MasterKeysService.ICD10,
|
|
|
|
|
id: element.icdCode10ID,
|
|
|
|
|
);
|
|
|
|
|
MasterKeyModel diagnosisCondition = model.getOneMasterKey(
|
|
|
|
|
masterKeys: MasterKeysService.DiagnosisCondition,
|
|
|
|
|
id: element.conditionID,
|
|
|
|
|
);
|
|
|
|
|
if (diagnosisCondition != null &&
|
|
|
|
|
diagnosisType != null &&
|
|
|
|
|
diagnosisCondition != null) {
|
|
|
|
|
MySelectedAssessment temMySelectedAssessment =
|
|
|
|
|
MySelectedAssessment(
|
|
|
|
|
appointmentId: element.appointmentNo,
|
|
|
|
|
remark: element.remarks,
|
|
|
|
|
selectedDiagnosisType: diagnosisType,
|
|
|
|
|
selectedDiagnosisCondition: diagnosisCondition,
|
|
|
|
|
selectedICD: selectedICD,
|
|
|
|
|
doctorID: element.doctorID,
|
|
|
|
|
doctorName: element.doctorName,
|
|
|
|
|
createdBy: element.createdBy,
|
|
|
|
|
createdOn: element.createdOn,
|
|
|
|
|
icdCode10ID: element.icdCode10ID);
|
|
|
|
|
|
|
|
|
|
widget.mySelectedAssessmentList.add(temMySelectedAssessment);
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
onModelReady: (model) async {
|
|
|
|
|
widget.mySelectedAssessmentList.clear();
|
|
|
|
|
GetAssessmentReqModel getAssessmentReqModel = GetAssessmentReqModel(
|
|
|
|
|
patientMRN: widget.patientInfo.patientMRN,
|
|
|
|
|
episodeID: widget.patientInfo.episodeNo.toString(),
|
|
|
|
|
editedBy: '',
|
|
|
|
|
doctorID: '',
|
|
|
|
|
appointmentNo: widget.patientInfo.appointmentNo);
|
|
|
|
|
await model.getPatientAssessment(getAssessmentReqModel);
|
|
|
|
|
if (model.patientAssessmentList.isNotEmpty) {
|
|
|
|
|
if (model.listOfDiagnosisCondition.length == 0) {
|
|
|
|
|
await model.getMasterLookup(MasterKeysService.DiagnosisCondition);
|
|
|
|
|
}
|
|
|
|
|
if (model.listOfDiagnosisType.length == 0) {
|
|
|
|
|
await model.getMasterLookup(MasterKeysService.DiagnosisType);
|
|
|
|
|
}
|
|
|
|
|
if (model.listOfICD10.length == 0) {
|
|
|
|
|
await model.getMasterLookup(MasterKeysService.ICD10);
|
|
|
|
|
}
|
|
|
|
|
model.patientAssessmentList.forEach((element) {
|
|
|
|
|
MasterKeyModel diagnosisType = model.getOneMasterKey(
|
|
|
|
|
masterKeys: MasterKeysService.DiagnosisType,
|
|
|
|
|
id: element.diagnosisTypeID,
|
|
|
|
|
);
|
|
|
|
|
MasterKeyModel selectedICD = model.getOneMasterKey(
|
|
|
|
|
masterKeys: MasterKeysService.ICD10,
|
|
|
|
|
id: element.icdCode10ID,
|
|
|
|
|
);
|
|
|
|
|
MasterKeyModel diagnosisCondition = model.getOneMasterKey(
|
|
|
|
|
masterKeys: MasterKeysService.DiagnosisCondition,
|
|
|
|
|
id: element.conditionID,
|
|
|
|
|
);
|
|
|
|
|
if (diagnosisCondition != null &&
|
|
|
|
|
diagnosisType != null &&
|
|
|
|
|
diagnosisCondition != null) {
|
|
|
|
|
MySelectedAssessment temMySelectedAssessment =
|
|
|
|
|
MySelectedAssessment(
|
|
|
|
|
appointmentId: element.appointmentNo,
|
|
|
|
|
remark: element.remarks,
|
|
|
|
|
selectedDiagnosisType: diagnosisType,
|
|
|
|
|
selectedDiagnosisCondition: diagnosisCondition,
|
|
|
|
|
selectedICD: selectedICD,
|
|
|
|
|
doctorID: element.doctorID,
|
|
|
|
|
doctorName: element.doctorName,
|
|
|
|
|
createdBy: element.createdBy,
|
|
|
|
|
createdOn: element.createdOn,
|
|
|
|
|
icdCode10ID: element.icdCode10ID);
|
|
|
|
|
|
|
|
|
|
widget.changeLoadingState(false);
|
|
|
|
|
},
|
|
|
|
|
builder: (_, model, w) => AppScaffold(
|
|
|
|
|
isShowAppBar: false,
|
|
|
|
|
// baseViewModel: model,
|
|
|
|
|
body: SingleChildScrollView(
|
|
|
|
|
physics: ScrollPhysics(),
|
|
|
|
|
child: Container(
|
|
|
|
|
color: Color(0xffF8F8F8),
|
|
|
|
|
child: Center(
|
|
|
|
|
child: FractionallySizedBox(
|
|
|
|
|
widthFactor: 0.9,
|
|
|
|
|
child: Column(
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 30,
|
|
|
|
|
widget.mySelectedAssessmentList.add(temMySelectedAssessment);
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
widget.changeLoadingState(false);
|
|
|
|
|
},
|
|
|
|
|
builder: (_, model, w) => AppScaffold(
|
|
|
|
|
isShowAppBar: false,
|
|
|
|
|
// baseViewModel: model,
|
|
|
|
|
body: SingleChildScrollView(
|
|
|
|
|
physics: ScrollPhysics(),
|
|
|
|
|
child: Container(
|
|
|
|
|
color: Color(0xffF8F8F8),
|
|
|
|
|
child: Center(
|
|
|
|
|
child: FractionallySizedBox(
|
|
|
|
|
widthFactor: 0.9,
|
|
|
|
|
child: Column(
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 30,
|
|
|
|
|
),
|
|
|
|
|
Container(
|
|
|
|
|
width: double.infinity,
|
|
|
|
|
margin: EdgeInsets.only(top: 10, left: 10, right: 10),
|
|
|
|
|
padding: EdgeInsets.all(8.0),
|
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
|
color: Colors.white,
|
|
|
|
|
borderRadius: BorderRadius.all(
|
|
|
|
|
Radius.circular(10.0),
|
|
|
|
|
),
|
|
|
|
|
Container(
|
|
|
|
|
width: double.infinity,
|
|
|
|
|
margin: EdgeInsets.only(top: 10, left: 10, right: 10),
|
|
|
|
|
padding: EdgeInsets.all(8.0),
|
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
|
color: Colors.white,
|
|
|
|
|
borderRadius: BorderRadius.all(
|
|
|
|
|
Radius.circular(10.0),
|
|
|
|
|
border: Border.all(color: Colors.grey[200], width: 0.5),
|
|
|
|
|
),
|
|
|
|
|
child: HeaderBodyExpandableNotifier(
|
|
|
|
|
headerWidget: Row(
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
|
|
children: [
|
|
|
|
|
Padding(
|
|
|
|
|
padding: EdgeInsets.all(12.0),
|
|
|
|
|
child: Row(
|
|
|
|
|
children: [
|
|
|
|
|
Texts(TranslationBase.of(context).assessment,
|
|
|
|
|
variant:
|
|
|
|
|
isAssessmentExpand ? "bodyText" : '',
|
|
|
|
|
bold: isAssessmentExpand ? true : false,
|
|
|
|
|
color: Colors.black),
|
|
|
|
|
Icon(
|
|
|
|
|
FontAwesomeIcons.asterisk,
|
|
|
|
|
color: Colors.black,
|
|
|
|
|
size: 10,
|
|
|
|
|
)
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
border:
|
|
|
|
|
Border.all(color: Colors.grey[200], width: 0.5),
|
|
|
|
|
InkWell(
|
|
|
|
|
onTap: () {
|
|
|
|
|
setState(() {
|
|
|
|
|
isAssessmentExpand = !isAssessmentExpand;
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
child: Icon(isAssessmentExpand
|
|
|
|
|
? EvaIcons.arrowUp
|
|
|
|
|
: EvaIcons.arrowDown))
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
bodyWidget: Column(children: [
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 20,
|
|
|
|
|
),
|
|
|
|
|
child: HeaderBodyExpandableNotifier(
|
|
|
|
|
headerWidget: Row(
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
|
|
children: [
|
|
|
|
|
Padding(
|
|
|
|
|
padding: EdgeInsets.all(12.0),
|
|
|
|
|
child: Row(
|
|
|
|
|
children: [
|
|
|
|
|
Texts(
|
|
|
|
|
TranslationBase.of(context)
|
|
|
|
|
.assessment,
|
|
|
|
|
variant: isAssessmentExpand
|
|
|
|
|
? "bodyText"
|
|
|
|
|
: '',
|
|
|
|
|
bold:
|
|
|
|
|
isAssessmentExpand ? true : false,
|
|
|
|
|
color: Colors.black),
|
|
|
|
|
Icon(
|
|
|
|
|
FontAwesomeIcons.asterisk,
|
|
|
|
|
color: Colors.black,
|
|
|
|
|
size: 10,
|
|
|
|
|
)
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
InkWell(
|
|
|
|
|
onTap: () {
|
|
|
|
|
setState(() {
|
|
|
|
|
isAssessmentExpand =
|
|
|
|
|
!isAssessmentExpand;
|
|
|
|
|
});
|
|
|
|
|
Column(
|
|
|
|
|
children: [
|
|
|
|
|
Container(
|
|
|
|
|
margin:
|
|
|
|
|
EdgeInsets.only(left: 5, right: 5, top: 15),
|
|
|
|
|
child: TextFields(
|
|
|
|
|
hintText: TranslationBase.of(context)
|
|
|
|
|
.addAssessment,
|
|
|
|
|
fontSize: 13.5,
|
|
|
|
|
onTapTextFields: () {
|
|
|
|
|
openAssessmentDialog(context,
|
|
|
|
|
isUpdate: false, model: model);
|
|
|
|
|
},
|
|
|
|
|
child: Icon(isAssessmentExpand
|
|
|
|
|
? EvaIcons.arrowUp
|
|
|
|
|
: EvaIcons.arrowDown))
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
bodyWidget: Column(children: [
|
|
|
|
|
readOnly: true,
|
|
|
|
|
suffixIcon: EvaIcons.plusSquare,
|
|
|
|
|
suffixIconColor: Colors.black,
|
|
|
|
|
fontWeight: FontWeight.w600,
|
|
|
|
|
validator: (value) {
|
|
|
|
|
if (value == null)
|
|
|
|
|
return TranslationBase.of(context)
|
|
|
|
|
.emptyMessage;
|
|
|
|
|
else
|
|
|
|
|
return null;
|
|
|
|
|
}),
|
|
|
|
|
),
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 20,
|
|
|
|
|
),
|
|
|
|
|
Column(
|
|
|
|
|
children: [
|
|
|
|
|
Container(
|
|
|
|
|
children: widget.mySelectedAssessmentList
|
|
|
|
|
.map((assessment) {
|
|
|
|
|
return Container(
|
|
|
|
|
margin: EdgeInsets.only(
|
|
|
|
|
left: 5, right: 5, top: 15),
|
|
|
|
|
child: TextFields(
|
|
|
|
|
hintText: TranslationBase.of(context)
|
|
|
|
|
.addAssessment,
|
|
|
|
|
fontSize: 13.5,
|
|
|
|
|
onTapTextFields: () {
|
|
|
|
|
openAssessmentDialog(context,
|
|
|
|
|
isUpdate: false, model: model);
|
|
|
|
|
},
|
|
|
|
|
readOnly: true,
|
|
|
|
|
suffixIcon: EvaIcons.plusSquare,
|
|
|
|
|
suffixIconColor: Colors.black,
|
|
|
|
|
fontWeight: FontWeight.w600,
|
|
|
|
|
validator: (value) {
|
|
|
|
|
if (value == null)
|
|
|
|
|
return TranslationBase.of(context)
|
|
|
|
|
.emptyMessage;
|
|
|
|
|
else
|
|
|
|
|
return null;
|
|
|
|
|
}),
|
|
|
|
|
),
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 20,
|
|
|
|
|
),
|
|
|
|
|
Column(
|
|
|
|
|
children: widget.mySelectedAssessmentList
|
|
|
|
|
.map((assessment) {
|
|
|
|
|
return Container(
|
|
|
|
|
margin: EdgeInsets.only(
|
|
|
|
|
left: 5, right: 5, top: 15),
|
|
|
|
|
child: Row(
|
|
|
|
|
mainAxisAlignment:
|
|
|
|
|
MainAxisAlignment.spaceBetween,
|
|
|
|
|
child: Row(
|
|
|
|
|
mainAxisAlignment:
|
|
|
|
|
MainAxisAlignment.spaceBetween,
|
|
|
|
|
crossAxisAlignment:
|
|
|
|
|
CrossAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
Column(
|
|
|
|
|
crossAxisAlignment:
|
|
|
|
|
CrossAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
Column(
|
|
|
|
|
Row(
|
|
|
|
|
children: [
|
|
|
|
|
AppText(
|
|
|
|
|
"ICD : ".toUpperCase(),
|
|
|
|
|
fontSize: 10,
|
|
|
|
|
color: Colors.grey,
|
|
|
|
|
),
|
|
|
|
|
Container(
|
|
|
|
|
child: AppText(
|
|
|
|
|
assessment.selectedICD.code
|
|
|
|
|
.trim()
|
|
|
|
|
.toUpperCase() ??
|
|
|
|
|
"",
|
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
|
fontSize: 11,
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
Row(
|
|
|
|
|
mainAxisAlignment:
|
|
|
|
|
MainAxisAlignment.start,
|
|
|
|
|
crossAxisAlignment:
|
|
|
|
|
CrossAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
Row(
|
|
|
|
|
children: [
|
|
|
|
|
AppText(
|
|
|
|
|
"ICD : ".toUpperCase(),
|
|
|
|
|
fontSize: 10,
|
|
|
|
|
color: Colors.grey,
|
|
|
|
|
),
|
|
|
|
|
Container(
|
|
|
|
|
child: AppText(
|
|
|
|
|
assessment.selectedICD
|
|
|
|
|
.code
|
|
|
|
|
.trim()
|
|
|
|
|
.toUpperCase() ??
|
|
|
|
|
"",
|
|
|
|
|
fontWeight:
|
|
|
|
|
FontWeight.w700,
|
|
|
|
|
fontSize: 11,
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
AppText(
|
|
|
|
|
TranslationBase.of(context)
|
|
|
|
|
.ICDName +
|
|
|
|
|
" : ",
|
|
|
|
|
fontSize: 13,
|
|
|
|
|
color: Colors.grey,
|
|
|
|
|
),
|
|
|
|
|
Row(
|
|
|
|
|
mainAxisAlignment:
|
|
|
|
|
MainAxisAlignment.start,
|
|
|
|
|
crossAxisAlignment:
|
|
|
|
|
CrossAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
AppText(
|
|
|
|
|
TranslationBase.of(
|
|
|
|
|
context)
|
|
|
|
|
.ICDName +
|
|
|
|
|
" : ",
|
|
|
|
|
fontSize: 13,
|
|
|
|
|
color: Colors.grey,
|
|
|
|
|
),
|
|
|
|
|
Container(
|
|
|
|
|
width:
|
|
|
|
|
MediaQuery.of(context)
|
|
|
|
|
.size
|
|
|
|
|
.width *
|
|
|
|
|
0.29,
|
|
|
|
|
child: AppText(
|
|
|
|
|
assessment.selectedICD
|
|
|
|
|
.description
|
|
|
|
|
.toString(),
|
|
|
|
|
fontWeight:
|
|
|
|
|
FontWeight.w700,
|
|
|
|
|
fontSize: 10,
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
Container(
|
|
|
|
|
width: MediaQuery.of(context)
|
|
|
|
|
.size
|
|
|
|
|
.width *
|
|
|
|
|
0.29,
|
|
|
|
|
child: AppText(
|
|
|
|
|
assessment
|
|
|
|
|
.selectedICD.description
|
|
|
|
|
.toString(),
|
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
|
fontSize: 10,
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
Row(
|
|
|
|
|
mainAxisAlignment:
|
|
|
|
|
MainAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
AppText(
|
|
|
|
|
TranslationBase.of(
|
|
|
|
|
context)
|
|
|
|
|
.appointmentNo,
|
|
|
|
|
fontSize: 10,
|
|
|
|
|
color: Colors.grey,
|
|
|
|
|
),
|
|
|
|
|
AppText(
|
|
|
|
|
assessment.appointmentId
|
|
|
|
|
.toString(),
|
|
|
|
|
fontSize: 11,
|
|
|
|
|
fontWeight:
|
|
|
|
|
FontWeight.w700,
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
Row(
|
|
|
|
|
mainAxisAlignment:
|
|
|
|
|
MainAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
AppText(
|
|
|
|
|
TranslationBase.of(context)
|
|
|
|
|
.appointmentNo,
|
|
|
|
|
fontSize: 10,
|
|
|
|
|
color: Colors.grey,
|
|
|
|
|
),
|
|
|
|
|
Row(
|
|
|
|
|
mainAxisAlignment:
|
|
|
|
|
MainAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
AppText(
|
|
|
|
|
TranslationBase.of(
|
|
|
|
|
context)
|
|
|
|
|
.condition +
|
|
|
|
|
" : ",
|
|
|
|
|
fontSize: 10,
|
|
|
|
|
color: Colors.grey,
|
|
|
|
|
),
|
|
|
|
|
AppText(
|
|
|
|
|
projectViewModel.isArabic
|
|
|
|
|
? assessment
|
|
|
|
|
.selectedDiagnosisCondition
|
|
|
|
|
.nameAr
|
|
|
|
|
: assessment
|
|
|
|
|
.selectedDiagnosisCondition
|
|
|
|
|
.nameEn,
|
|
|
|
|
fontSize: 11,
|
|
|
|
|
fontWeight:
|
|
|
|
|
FontWeight.w700,
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
AppText(
|
|
|
|
|
assessment.appointmentId
|
|
|
|
|
.toString(),
|
|
|
|
|
fontSize: 11,
|
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
|
),
|
|
|
|
|
Row(
|
|
|
|
|
mainAxisAlignment:
|
|
|
|
|
MainAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
AppText(
|
|
|
|
|
TranslationBase.of(
|
|
|
|
|
context)
|
|
|
|
|
.dType +
|
|
|
|
|
' : ',
|
|
|
|
|
fontSize: 10,
|
|
|
|
|
color: Colors.grey,
|
|
|
|
|
),
|
|
|
|
|
AppText(
|
|
|
|
|
projectViewModel.isArabic
|
|
|
|
|
? assessment
|
|
|
|
|
.selectedDiagnosisType
|
|
|
|
|
.nameAr
|
|
|
|
|
: assessment
|
|
|
|
|
.selectedDiagnosisType
|
|
|
|
|
.nameEn,
|
|
|
|
|
fontSize: 11,
|
|
|
|
|
fontWeight:
|
|
|
|
|
FontWeight.w700,
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
Row(
|
|
|
|
|
mainAxisAlignment:
|
|
|
|
|
MainAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
AppText(
|
|
|
|
|
TranslationBase.of(context)
|
|
|
|
|
.condition +
|
|
|
|
|
" : ",
|
|
|
|
|
fontSize: 10,
|
|
|
|
|
color: Colors.grey,
|
|
|
|
|
),
|
|
|
|
|
if (assessment.doctorName !=
|
|
|
|
|
null)
|
|
|
|
|
Row(
|
|
|
|
|
mainAxisAlignment:
|
|
|
|
|
MainAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
AppText(
|
|
|
|
|
TranslationBase.of(
|
|
|
|
|
context)
|
|
|
|
|
.doc,
|
|
|
|
|
fontSize: 10,
|
|
|
|
|
color: Colors.grey,
|
|
|
|
|
),
|
|
|
|
|
AppText(
|
|
|
|
|
assessment.doctorName ??
|
|
|
|
|
'',
|
|
|
|
|
fontSize: 11,
|
|
|
|
|
fontWeight:
|
|
|
|
|
FontWeight.w700,
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
AppText(
|
|
|
|
|
projectViewModel.isArabic
|
|
|
|
|
? assessment
|
|
|
|
|
.selectedDiagnosisCondition
|
|
|
|
|
.nameAr
|
|
|
|
|
: assessment
|
|
|
|
|
.selectedDiagnosisCondition
|
|
|
|
|
.nameEn,
|
|
|
|
|
fontSize: 11,
|
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
Row(
|
|
|
|
|
mainAxisAlignment:
|
|
|
|
|
MainAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
AppText(
|
|
|
|
|
TranslationBase.of(context)
|
|
|
|
|
.dType +
|
|
|
|
|
' : ',
|
|
|
|
|
fontSize: 10,
|
|
|
|
|
color: Colors.grey,
|
|
|
|
|
),
|
|
|
|
|
AppText(
|
|
|
|
|
projectViewModel.isArabic
|
|
|
|
|
? assessment
|
|
|
|
|
.selectedDiagnosisType
|
|
|
|
|
.nameAr
|
|
|
|
|
: assessment
|
|
|
|
|
.selectedDiagnosisType
|
|
|
|
|
.nameEn,
|
|
|
|
|
fontSize: 11,
|
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
if (assessment.doctorName != null)
|
|
|
|
|
Row(
|
|
|
|
|
mainAxisAlignment:
|
|
|
|
|
MainAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
AppText(
|
|
|
|
|
TranslationBase.of(context)
|
|
|
|
|
.doc,
|
|
|
|
|
fontSize: 10,
|
|
|
|
|
color: Colors.grey,
|
|
|
|
|
),
|
|
|
|
|
AppText(
|
|
|
|
|
assessment.doctorName ?? '',
|
|
|
|
|
fontSize: 11,
|
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 6,
|
|
|
|
|
),
|
|
|
|
|
Row(
|
|
|
|
|
mainAxisAlignment:
|
|
|
|
|
MainAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 6,
|
|
|
|
|
),
|
|
|
|
|
Row(
|
|
|
|
|
mainAxisAlignment:
|
|
|
|
|
MainAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 6,
|
|
|
|
|
),
|
|
|
|
|
AppText(
|
|
|
|
|
assessment.remark !=
|
|
|
|
|
null ||
|
|
|
|
|
assessment
|
|
|
|
|
.remark ==
|
|
|
|
|
''
|
|
|
|
|
? TranslationBase.of(
|
|
|
|
|
context)
|
|
|
|
|
.remarks +
|
|
|
|
|
" : "
|
|
|
|
|
: '',
|
|
|
|
|
fontSize: 10,
|
|
|
|
|
color: Colors.grey,
|
|
|
|
|
),
|
|
|
|
|
Container(
|
|
|
|
|
width:
|
|
|
|
|
MediaQuery.of(context)
|
|
|
|
|
.size
|
|
|
|
|
.width *
|
|
|
|
|
0.38,
|
|
|
|
|
child: AppText(
|
|
|
|
|
assessment.remark ?? "",
|
|
|
|
|
fontSize: 11,
|
|
|
|
|
fontWeight:
|
|
|
|
|
FontWeight.w700,
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
AppText(
|
|
|
|
|
assessment.remark != null ||
|
|
|
|
|
assessment.remark ==
|
|
|
|
|
''
|
|
|
|
|
? TranslationBase.of(
|
|
|
|
|
context)
|
|
|
|
|
.remarks +
|
|
|
|
|
" : "
|
|
|
|
|
: '',
|
|
|
|
|
fontSize: 10,
|
|
|
|
|
color: Colors.grey,
|
|
|
|
|
),
|
|
|
|
|
Container(
|
|
|
|
|
width: MediaQuery.of(context)
|
|
|
|
|
.size
|
|
|
|
|
.width *
|
|
|
|
|
0.38,
|
|
|
|
|
child: AppText(
|
|
|
|
|
assessment.remark ?? "",
|
|
|
|
|
fontSize: 11,
|
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
Column(
|
|
|
|
|
crossAxisAlignment:
|
|
|
|
|
CrossAxisAlignment.start,
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
Column(
|
|
|
|
|
crossAxisAlignment:
|
|
|
|
|
CrossAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
Row(
|
|
|
|
|
children: [
|
|
|
|
|
Row(
|
|
|
|
|
children: [
|
|
|
|
|
AppText(
|
|
|
|
|
assessment.createdOn !=
|
|
|
|
|
AppText(
|
|
|
|
|
assessment.createdOn != null
|
|
|
|
|
? DateTime.parse(
|
|
|
|
|
assessment
|
|
|
|
|
.createdOn)
|
|
|
|
|
.day
|
|
|
|
|
.toString()
|
|
|
|
|
: DateTime.now()
|
|
|
|
|
.day
|
|
|
|
|
.toString(),
|
|
|
|
|
fontWeight: FontWeight.bold,
|
|
|
|
|
fontSize: 15,
|
|
|
|
|
),
|
|
|
|
|
AppText(" "),
|
|
|
|
|
AppText(
|
|
|
|
|
Helpers.getMonth(assessment
|
|
|
|
|
.createdOn !=
|
|
|
|
|
null
|
|
|
|
|
? DateTime.parse(
|
|
|
|
|
assessment
|
|
|
|
|
.createdOn)
|
|
|
|
|
.day
|
|
|
|
|
.toString()
|
|
|
|
|
.month
|
|
|
|
|
: DateTime.now()
|
|
|
|
|
.day
|
|
|
|
|
.toString(),
|
|
|
|
|
fontWeight:
|
|
|
|
|
FontWeight.bold,
|
|
|
|
|
fontSize: 15,
|
|
|
|
|
),
|
|
|
|
|
AppText(" "),
|
|
|
|
|
AppText(
|
|
|
|
|
Helpers.getMonth(assessment
|
|
|
|
|
.createdOn !=
|
|
|
|
|
null
|
|
|
|
|
? DateTime.parse(
|
|
|
|
|
assessment
|
|
|
|
|
.createdOn)
|
|
|
|
|
.month
|
|
|
|
|
: DateTime.now()
|
|
|
|
|
.month)
|
|
|
|
|
.toUpperCase(),
|
|
|
|
|
fontSize: 13,
|
|
|
|
|
color: Colors.grey,
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: MediaQuery.of(context)
|
|
|
|
|
.size
|
|
|
|
|
.height *
|
|
|
|
|
0.05,
|
|
|
|
|
.month)
|
|
|
|
|
.toUpperCase(),
|
|
|
|
|
fontSize: 13,
|
|
|
|
|
color: Colors.grey,
|
|
|
|
|
),
|
|
|
|
|
InkWell(
|
|
|
|
|
onTap: () {
|
|
|
|
|
openAssessmentDialog(
|
|
|
|
|
context,
|
|
|
|
|
isUpdate: true,
|
|
|
|
|
assessment: assessment,
|
|
|
|
|
model: model);
|
|
|
|
|
},
|
|
|
|
|
child: Icon(EvaIcons.edit2),
|
|
|
|
|
)
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
// Column(
|
|
|
|
|
// children: [
|
|
|
|
|
// // SizedBox(
|
|
|
|
|
// // height: 60,
|
|
|
|
|
// // ),
|
|
|
|
|
// InkWell(
|
|
|
|
|
// onTap: () {
|
|
|
|
|
// openAssessmentDialog(
|
|
|
|
|
// context,
|
|
|
|
|
// isUpdate: true,
|
|
|
|
|
// assessment: assessment,
|
|
|
|
|
// model: model);
|
|
|
|
|
// },
|
|
|
|
|
// child: Icon(EvaIcons.edit2),
|
|
|
|
|
// )
|
|
|
|
|
// ],
|
|
|
|
|
// ),
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: MediaQuery.of(context)
|
|
|
|
|
.size
|
|
|
|
|
.height *
|
|
|
|
|
0.05,
|
|
|
|
|
),
|
|
|
|
|
InkWell(
|
|
|
|
|
onTap: () {
|
|
|
|
|
openAssessmentDialog(context,
|
|
|
|
|
isUpdate: true,
|
|
|
|
|
assessment: assessment,
|
|
|
|
|
model: model);
|
|
|
|
|
},
|
|
|
|
|
child: Icon(EvaIcons.edit2),
|
|
|
|
|
)
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
);
|
|
|
|
|
}).toList(),
|
|
|
|
|
)
|
|
|
|
|
],
|
|
|
|
|
// Column(
|
|
|
|
|
// children: [
|
|
|
|
|
// // SizedBox(
|
|
|
|
|
// // height: 60,
|
|
|
|
|
// // ),
|
|
|
|
|
// InkWell(
|
|
|
|
|
// onTap: () {
|
|
|
|
|
// openAssessmentDialog(
|
|
|
|
|
// context,
|
|
|
|
|
// isUpdate: true,
|
|
|
|
|
// assessment: assessment,
|
|
|
|
|
// model: model);
|
|
|
|
|
// },
|
|
|
|
|
// child: Icon(EvaIcons.edit2),
|
|
|
|
|
// )
|
|
|
|
|
// ],
|
|
|
|
|
// ),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
);
|
|
|
|
|
}).toList(),
|
|
|
|
|
)
|
|
|
|
|
]),
|
|
|
|
|
isExpand: isAssessmentExpand,
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
DividerWithSpacesAround(
|
|
|
|
|
height: 30,
|
|
|
|
|
),
|
|
|
|
|
Row(
|
|
|
|
|
children: [
|
|
|
|
|
Container(
|
|
|
|
|
width: MediaQuery.of(context).size.width * 0.4,
|
|
|
|
|
child: AppButton(
|
|
|
|
|
title: 'Previous',
|
|
|
|
|
color: Colors.white38,
|
|
|
|
|
fontColor: Colors.black,
|
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
|
loading: model.state == ViewState.BusyLocal,
|
|
|
|
|
onPressed: () async {
|
|
|
|
|
Navigator.pop(context);
|
|
|
|
|
},
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
SizedBox(
|
|
|
|
|
width: MediaQuery.of(context).size.width * 0.05,
|
|
|
|
|
),
|
|
|
|
|
Container(
|
|
|
|
|
width: MediaQuery.of(context).size.width * 0.4,
|
|
|
|
|
child: AppButton(
|
|
|
|
|
title: TranslationBase.of(context).next,
|
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
|
loading: model.state == ViewState.BusyLocal,
|
|
|
|
|
onPressed: () async {
|
|
|
|
|
if (widget.mySelectedAssessmentList.isEmpty) {
|
|
|
|
|
helpers.showErrorToast(
|
|
|
|
|
TranslationBase.of(context)
|
|
|
|
|
.assessmentErrorMsg);
|
|
|
|
|
} else {
|
|
|
|
|
widget.changePageViewIndex(3);
|
|
|
|
|
widget.changeLoadingState(true);
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 30,
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
],
|
|
|
|
|
)
|
|
|
|
|
]),
|
|
|
|
|
isExpand: isAssessmentExpand,
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
DividerWithSpacesAround(
|
|
|
|
|
height: 30,
|
|
|
|
|
),
|
|
|
|
|
// Row(
|
|
|
|
|
// children: [
|
|
|
|
|
// Container(
|
|
|
|
|
// width: MediaQuery.of(context).size.width * 0.4,
|
|
|
|
|
// child: AppButton(
|
|
|
|
|
// title: 'Previous',
|
|
|
|
|
// color: Colors.white38,
|
|
|
|
|
// fontColor: Colors.black,
|
|
|
|
|
// fontWeight: FontWeight.w700,
|
|
|
|
|
// loading: model.state == ViewState.BusyLocal,
|
|
|
|
|
// onPressed: () async {
|
|
|
|
|
// Navigator.pop(context);
|
|
|
|
|
// },
|
|
|
|
|
// ),
|
|
|
|
|
// ),
|
|
|
|
|
// SizedBox(
|
|
|
|
|
// width: MediaQuery.of(context).size.width * 0.05,
|
|
|
|
|
// ),
|
|
|
|
|
// Container(
|
|
|
|
|
// width: MediaQuery.of(context).size.width * 0.4,
|
|
|
|
|
// child: AppButton(
|
|
|
|
|
// title: TranslationBase.of(context).next,
|
|
|
|
|
// fontWeight: FontWeight.w700,
|
|
|
|
|
// loading: model.state == ViewState.BusyLocal,
|
|
|
|
|
// onPressed: () async {
|
|
|
|
|
// if (widget.mySelectedAssessmentList.isEmpty) {
|
|
|
|
|
// helpers.showErrorToast(
|
|
|
|
|
// TranslationBase.of(context)
|
|
|
|
|
// .assessmentErrorMsg);
|
|
|
|
|
// } else {
|
|
|
|
|
// widget.changePageViewIndex(3);
|
|
|
|
|
// widget.changeLoadingState(true);
|
|
|
|
|
// }
|
|
|
|
|
// },
|
|
|
|
|
// ),
|
|
|
|
|
// ),
|
|
|
|
|
// ],
|
|
|
|
|
// ),
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 130,
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
bottomSheet: Padding(
|
|
|
|
|
padding: const EdgeInsets.all(12.0),
|
|
|
|
|
child: Row(
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.center,
|
|
|
|
|
children: [
|
|
|
|
|
Container(
|
|
|
|
|
width: MediaQuery.of(context).size.width * 0.4,
|
|
|
|
|
child: AppButton(
|
|
|
|
|
title: 'Previous',
|
|
|
|
|
color: Colors.white38,
|
|
|
|
|
fontColor: Colors.black,
|
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
|
loading: model.state == ViewState.BusyLocal,
|
|
|
|
|
onPressed: () async {
|
|
|
|
|
widget.changePageViewIndex(1);
|
|
|
|
|
},
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
)));
|
|
|
|
|
SizedBox(
|
|
|
|
|
width: MediaQuery.of(context).size.width * 0.05,
|
|
|
|
|
),
|
|
|
|
|
Container(
|
|
|
|
|
width: MediaQuery.of(context).size.width * 0.4,
|
|
|
|
|
child: AppButton(
|
|
|
|
|
title: TranslationBase.of(context).next,
|
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
|
loading: model.state == ViewState.BusyLocal,
|
|
|
|
|
onPressed: () async {
|
|
|
|
|
if (widget.mySelectedAssessmentList.isEmpty) {
|
|
|
|
|
helpers.showErrorToast(
|
|
|
|
|
TranslationBase.of(context).assessmentErrorMsg);
|
|
|
|
|
} else {
|
|
|
|
|
widget.changePageViewIndex(3);
|
|
|
|
|
widget.changeLoadingState(true);
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
openAssessmentDialog(BuildContext context,
|
|
|
|
|