lab result & railogy fix

merge-requests/796/head
hussam al-habibeh 5 years ago
parent 8d493f40fa
commit 0535566232

@ -18,12 +18,7 @@ class LabResultWidget extends StatelessWidget {
final bool isInpatient; final bool isInpatient;
LabResultWidget( LabResultWidget(
{Key key, {Key key, this.filterName, this.patientLabResultList, this.patientLabOrder, this.patient, this.isInpatient})
this.filterName,
this.patientLabResultList,
this.patientLabOrder,
this.patient,
this.isInpatient})
: super(key: key); : super(key: key);
ProjectViewModel projectViewModel; ProjectViewModel projectViewModel;
@ -37,32 +32,32 @@ class LabResultWidget extends StatelessWidget {
crossAxisAlignment: CrossAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start,
children: <Widget>[ children: <Widget>[
// if (!isInpatient) // if (!isInpatient)
Row( Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween, mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [ children: [
AppText(filterName), AppText(filterName),
InkWell( InkWell(
onTap: () { onTap: () {
Navigator.push( Navigator.push(
context, context,
FadePage( FadePage(
page: FlowChartPage( page: FlowChartPage(
filterName: filterName, filterName: filterName,
patientLabOrder: patientLabOrder, patientLabOrder: patientLabOrder,
patient: patient, patient: patient,
isInpatient: isInpatient, isInpatient: isInpatient,
),
), ),
); ),
}, );
child: AppText( },
TranslationBase.of(context).showMoreBtn, child: AppText(
textDecoration: TextDecoration.underline, TranslationBase.of(context).showMoreBtn,
color: Colors.blue, textDecoration: TextDecoration.underline,
), color: Colors.blue,
), ),
], ),
), ],
),
Row( Row(
children: [ children: [
Expanded( Expanded(
@ -122,8 +117,7 @@ class LabResultWidget extends StatelessWidget {
color: Colors.white, color: Colors.white,
child: Center( child: Center(
child: AppText( child: AppText(
'${patientLabResultList[index].testCode}\n' + '${patientLabResultList[index].testCode}\n' + patientLabResultList[index].description,
patientLabResultList[index].description,
textAlign: TextAlign.center, textAlign: TextAlign.center,
), ),
), ),
@ -135,9 +129,8 @@ class LabResultWidget extends StatelessWidget {
color: Colors.white, color: Colors.white,
child: Center( child: Center(
child: AppText( child: AppText(
patientLabResultList[index].resultValue ??""+ patientLabResultList[index].resultValue ??
" " + "" + " " + "${patientLabResultList[index].uOM ?? ""}",
"${patientLabResultList[index].uOM ?? ""}",
textAlign: TextAlign.center, textAlign: TextAlign.center,
), ),
), ),

@ -88,20 +88,16 @@ class _LaboratoryResultWidgetState extends State<LaboratoryResultWidget> {
children: <Widget>[ children: <Widget>[
Expanded( Expanded(
child: Container( child: Container(
margin: EdgeInsets.only( margin: EdgeInsets.only(left: 10, right: 10),
left: 10, right: 10),
child: AppText( child: AppText(
TranslationBase.of(context) TranslationBase.of(context).generalResult,
.generalResult,
bold: true, bold: true,
))), ))),
Container( Container(
width: 25, width: 25,
height: 25, height: 25,
child: Icon( child: Icon(
_isShowMoreGeneral _isShowMoreGeneral ? Icons.keyboard_arrow_up : Icons.keyboard_arrow_down,
? Icons.keyboard_arrow_up
: Icons.keyboard_arrow_down,
color: Colors.grey[800], color: Colors.grey[800],
size: 22, size: 22,
), ),
@ -132,11 +128,8 @@ class _LaboratoryResultWidgetState extends State<LaboratoryResultWidget> {
model.labResultLists.length, model.labResultLists.length,
(index) => LabResultWidget( (index) => LabResultWidget(
patientLabOrder: widget.patientLabOrder, patientLabOrder: widget.patientLabOrder,
filterName: model filterName: model.labResultLists[index].filterName,
.labResultLists[index].filterName, patientLabResultList: model.labResultLists[index].patientLabResultList,
patientLabResultList: model
.labResultLists[index]
.patientLabResultList,
patient: widget.patient, patient: widget.patient,
isInpatient: widget.isInpatient, isInpatient: widget.isInpatient,
), ),
@ -173,20 +166,16 @@ class _LaboratoryResultWidgetState extends State<LaboratoryResultWidget> {
children: <Widget>[ children: <Widget>[
Expanded( Expanded(
child: Container( child: Container(
margin: EdgeInsets.only( margin: EdgeInsets.only(left: 10, right: 10),
left: 10, right: 10),
child: AppText( child: AppText(
TranslationBase.of(context) TranslationBase.of(context).specialResult,
.specialResult,
bold: true, bold: true,
))), ))),
Container( Container(
width: 25, width: 25,
height: 25, height: 25,
child: Icon( child: Icon(
_isShowMore _isShowMore ? Icons.keyboard_arrow_up : Icons.keyboard_arrow_down,
? Icons.keyboard_arrow_up
: Icons.keyboard_arrow_down,
color: Colors.grey[800], color: Colors.grey[800],
size: 22, size: 22,
), ),
@ -211,14 +200,10 @@ class _LaboratoryResultWidgetState extends State<LaboratoryResultWidget> {
width: double.infinity, width: double.infinity,
child: !Helpers.isTextHtml(widget.details) child: !Helpers.isTextHtml(widget.details)
? AppText( ? AppText(
widget.details ?? widget.details ?? TranslationBase.of(context).noDataAvailable,
TranslationBase.of(context)
.noDataAvailable,
) )
: Html( : Html(
data: widget.details ?? data: widget.details ?? TranslationBase.of(context).noDataAvailable,
TranslationBase.of(context)
.noDataAvailable,
), ),
), ),
), ),

Loading…
Cancel
Save