add arrow to patient card

merge-requests/822/head
mosazaid 4 years ago
parent e334dbd221
commit c608b5601d

@ -348,58 +348,62 @@ class PatientCard extends StatelessWidget {
width: 10,
),
Expanded(
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
CustomRow(
label: TranslationBase.of(context).fileNumber,
value: patientInfo.patientId.toString(),
),
//if (isInpatient)
CustomRow(
label: TranslationBase.of(context).age + " : ",
value:
"${AppDateUtils.getAgeByBirthday(patientInfo.dateofBirth, context, isServerFormat: !isFromLiveCare)}",
),
if (isInpatient)
CustomRow(
label: patientInfo.admissionDate == null
? ""
: TranslationBase.of(context)
.admissionDate +
" : ",
value: patientInfo.admissionDate == null
? ""
: "${AppDateUtils.convertDateFromServerFormat(patientInfo.admissionDate.toString(), 'yyyy-MM-dd')}",
),
if (patientInfo.admissionDate != null)
CustomRow(
label: TranslationBase.of(context).numOfDays +
" : ",
value:
"${DateTime.now().difference(AppDateUtils.getDateTimeFromServerFormat(patientInfo.admissionDate)).inDays + 1}",
),
if (patientInfo.admissionDate != null)
CustomRow(
label:
TranslationBase.of(context).roomNo + " : ",
value: "${patientInfo.roomId}",
),
if (isFromLiveCare)
Column(
children: [
child: Row(
children: [
Expanded(
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
CustomRow(
label: TranslationBase.of(context).clinic +
" : ",
value: patientInfo.clinicName,
label: TranslationBase.of(context).fileNumber,
value: patientInfo.patientId.toString(),
),
],
CustomRow(
label: TranslationBase.of(context).age + " : ",
value:
"${AppDateUtils.getAgeByBirthday(patientInfo.dateofBirth, context, isServerFormat: !isFromLiveCare)}",
),
if (isInpatient)
CustomRow(
label: patientInfo.admissionDate == null
? ""
: TranslationBase.of(context)
.admissionDate +
" : ",
value: patientInfo.admissionDate == null
? ""
: "${AppDateUtils.convertDateFromServerFormat(patientInfo.admissionDate.toString(), 'yyyy-MM-dd')}",
),
if (patientInfo.admissionDate != null)
CustomRow(
label: TranslationBase.of(context).numOfDays +
" : ",
value:
"${DateTime.now().difference(AppDateUtils.getDateTimeFromServerFormat(patientInfo.admissionDate)).inDays + 1}",
),
if (patientInfo.admissionDate != null)
CustomRow(
label:
TranslationBase.of(context).roomNo + " : ",
value: "${patientInfo.roomId}",
),
if (isFromLiveCare)
Column(
children: [
CustomRow(
label: TranslationBase.of(context).clinic +
" : ",
value: patientInfo.clinicName,
),
],
),
]),
),
]))
Icon(Icons.arrow_forward, size: 24,),
],
))
]),
isFromLiveCare
? Row(

Loading…
Cancel
Save