|
|
|
|
@ -35,18 +35,18 @@ class PatientCard extends StatelessWidget {
|
|
|
|
|
color: Colors.white,
|
|
|
|
|
),
|
|
|
|
|
child: Stack(children: [
|
|
|
|
|
// if (SERVICES_PATIANT2[int.parse(patientType)] != "List_MyInPatient")
|
|
|
|
|
// Container(
|
|
|
|
|
// height: MediaQuery.of(context).size.height * .20,
|
|
|
|
|
// width: 5,
|
|
|
|
|
// decoration: BoxDecoration(
|
|
|
|
|
// borderRadius: BorderRadius.only(
|
|
|
|
|
// topLeft: Radius.circular(10),
|
|
|
|
|
// bottomLeft: Radius.circular(10)),
|
|
|
|
|
// color: patientInfo.patientStatusType == 43
|
|
|
|
|
// ? Colors.green[500]
|
|
|
|
|
// : Colors.red[800],
|
|
|
|
|
// )),
|
|
|
|
|
if (isInpatient)
|
|
|
|
|
Container(
|
|
|
|
|
height: MediaQuery.of(context).size.height * .20,
|
|
|
|
|
width: 5,
|
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
|
borderRadius: BorderRadius.only(
|
|
|
|
|
topLeft: Radius.circular(10),
|
|
|
|
|
bottomLeft: Radius.circular(10)),
|
|
|
|
|
color: patientInfo.patientStatusType == 43
|
|
|
|
|
? Colors.green[500]
|
|
|
|
|
: Colors.red[800],
|
|
|
|
|
)),
|
|
|
|
|
Container(
|
|
|
|
|
padding: EdgeInsets.only(left: 10, right: 0, bottom: 0),
|
|
|
|
|
child: InkWell(
|
|
|
|
|
@ -55,48 +55,47 @@ class PatientCard extends StatelessWidget {
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 10,
|
|
|
|
|
),
|
|
|
|
|
// SERVICES_PATIANT2[int.parse(patientType)] ==
|
|
|
|
|
// "List_MyOutPatient"
|
|
|
|
|
// ? Padding(
|
|
|
|
|
// padding: EdgeInsets.only(left: 12.0),
|
|
|
|
|
// child: Row(
|
|
|
|
|
// mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
|
|
// children: [
|
|
|
|
|
// patientInfo.patientStatusType == 43
|
|
|
|
|
// ? AppText(
|
|
|
|
|
// TranslationBase.of(context).arrivedP,
|
|
|
|
|
// color: Colors.green,
|
|
|
|
|
// fontWeight: FontWeight.bold,
|
|
|
|
|
// fontFamily: 'Poppins',
|
|
|
|
|
// fontSize: 12,
|
|
|
|
|
// )
|
|
|
|
|
// : AppText(
|
|
|
|
|
// TranslationBase.of(context).notArrived,
|
|
|
|
|
// color: Colors.red[800],
|
|
|
|
|
// fontWeight: FontWeight.bold,
|
|
|
|
|
// fontFamily: 'Poppins',
|
|
|
|
|
// fontSize: 12,
|
|
|
|
|
// ),
|
|
|
|
|
// this.arrivalType == '1'
|
|
|
|
|
// ? AppText(
|
|
|
|
|
// patientInfo.startTime != null
|
|
|
|
|
// ? patientInfo.startTime
|
|
|
|
|
// : patientInfo.startTimes,
|
|
|
|
|
// fontFamily: 'Poppins',
|
|
|
|
|
// fontWeight: FontWeight.w600,
|
|
|
|
|
// )
|
|
|
|
|
// : patientInfo.arrivedOn != null
|
|
|
|
|
// ? AppText(
|
|
|
|
|
// DateUtils.convertStringToDateFormat(
|
|
|
|
|
// patientInfo.arrivedOn,
|
|
|
|
|
// 'MM-dd-yyyy HH:mm'),
|
|
|
|
|
// fontFamily: 'Poppins',
|
|
|
|
|
// fontWeight: FontWeight.w600,
|
|
|
|
|
// )
|
|
|
|
|
// : SizedBox()
|
|
|
|
|
// ],
|
|
|
|
|
// ))
|
|
|
|
|
// : SizedBox(),
|
|
|
|
|
!isInpatient
|
|
|
|
|
? Padding(
|
|
|
|
|
padding: EdgeInsets.only(left: 12.0),
|
|
|
|
|
child: Row(
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
|
|
children: [
|
|
|
|
|
patientInfo.patientStatusType == 43
|
|
|
|
|
? AppText(
|
|
|
|
|
TranslationBase.of(context).arrivedP,
|
|
|
|
|
color: Colors.green,
|
|
|
|
|
fontWeight: FontWeight.bold,
|
|
|
|
|
fontFamily: 'Poppins',
|
|
|
|
|
fontSize: 12,
|
|
|
|
|
)
|
|
|
|
|
: AppText(
|
|
|
|
|
TranslationBase.of(context).notArrived,
|
|
|
|
|
color: Colors.red[800],
|
|
|
|
|
fontWeight: FontWeight.bold,
|
|
|
|
|
fontFamily: 'Poppins',
|
|
|
|
|
fontSize: 12,
|
|
|
|
|
),
|
|
|
|
|
this.arrivalType == '1'
|
|
|
|
|
? AppText(
|
|
|
|
|
patientInfo.startTime != null
|
|
|
|
|
? patientInfo.startTime
|
|
|
|
|
: patientInfo.startTimes,
|
|
|
|
|
fontFamily: 'Poppins',
|
|
|
|
|
fontWeight: FontWeight.w600,
|
|
|
|
|
)
|
|
|
|
|
: patientInfo.arrivedOn != null
|
|
|
|
|
? AppText(
|
|
|
|
|
DateUtils.getDayMonthYearDateFormatted(DateUtils.convertStringToDate(
|
|
|
|
|
patientInfo.arrivedOn,
|
|
|
|
|
)),
|
|
|
|
|
fontFamily: 'Poppins',
|
|
|
|
|
fontWeight: FontWeight.w600,
|
|
|
|
|
)
|
|
|
|
|
: SizedBox()
|
|
|
|
|
],
|
|
|
|
|
))
|
|
|
|
|
: SizedBox(),
|
|
|
|
|
Padding(
|
|
|
|
|
padding: EdgeInsets.only(left: 12.0),
|
|
|
|
|
child: Row(
|
|
|
|
|
@ -213,33 +212,32 @@ class PatientCard extends StatelessWidget {
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
// if (SERVICES_PATIANT2[int.parse(patientType)] !=
|
|
|
|
|
// "List_MyInPatient")
|
|
|
|
|
// Container(
|
|
|
|
|
// child: RichText(
|
|
|
|
|
// text: new TextSpan(
|
|
|
|
|
// style: new TextStyle(
|
|
|
|
|
// fontSize: 2.0 * SizeConfig.textMultiplier,
|
|
|
|
|
// color: Colors.black,
|
|
|
|
|
// fontFamily: 'Poppins',
|
|
|
|
|
// ),
|
|
|
|
|
// children: <TextSpan>[
|
|
|
|
|
// new TextSpan(
|
|
|
|
|
// text:
|
|
|
|
|
// TranslationBase.of(context).age +
|
|
|
|
|
// " : ",
|
|
|
|
|
// style: TextStyle(fontSize: 14)),
|
|
|
|
|
// new TextSpan(
|
|
|
|
|
// text:
|
|
|
|
|
// "${DateUtils.getAgeByBirthday(patientInfo.dateofBirth, context)}",
|
|
|
|
|
// style: TextStyle(
|
|
|
|
|
// fontWeight: FontWeight.w700,
|
|
|
|
|
// fontSize: 15)),
|
|
|
|
|
// ],
|
|
|
|
|
// ),
|
|
|
|
|
// ),
|
|
|
|
|
// ),
|
|
|
|
|
if (isInpatient == true)
|
|
|
|
|
if (isInpatient)
|
|
|
|
|
Container(
|
|
|
|
|
child: RichText(
|
|
|
|
|
text: new TextSpan(
|
|
|
|
|
style: new TextStyle(
|
|
|
|
|
fontSize: 2.0 * SizeConfig.textMultiplier,
|
|
|
|
|
color: Colors.black,
|
|
|
|
|
fontFamily: 'Poppins',
|
|
|
|
|
),
|
|
|
|
|
children: <TextSpan>[
|
|
|
|
|
new TextSpan(
|
|
|
|
|
text:
|
|
|
|
|
TranslationBase.of(context).age +
|
|
|
|
|
" : ",
|
|
|
|
|
style: TextStyle(fontSize: 14)),
|
|
|
|
|
new TextSpan(
|
|
|
|
|
text:
|
|
|
|
|
"${DateUtils.getAgeByBirthday(patientInfo.dateofBirth, context)}",
|
|
|
|
|
style: TextStyle(
|
|
|
|
|
fontWeight: FontWeight.w700,
|
|
|
|
|
fontSize: 15)),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
if (isInpatient )
|
|
|
|
|
Container(
|
|
|
|
|
child: RichText(
|
|
|
|
|
text: new TextSpan(
|
|
|
|
|
@ -370,28 +368,26 @@ class PatientCard extends StatelessWidget {
|
|
|
|
|
//)
|
|
|
|
|
]))
|
|
|
|
|
]),
|
|
|
|
|
// SERVICES_PATIANT2[int.parse(patientType)] ==
|
|
|
|
|
// "List_MyOutPatient"
|
|
|
|
|
// ? Row(
|
|
|
|
|
// mainAxisAlignment: MainAxisAlignment.end,
|
|
|
|
|
// children: [
|
|
|
|
|
// Container(
|
|
|
|
|
// padding: EdgeInsets.all(4),
|
|
|
|
|
// child: Image.asset(
|
|
|
|
|
// patientInfo.appointmentType ==
|
|
|
|
|
// 'Regular' &&
|
|
|
|
|
// patientInfo.visitTypeId == 100
|
|
|
|
|
// ? 'assets/images/livecare.png'
|
|
|
|
|
// : patientInfo.appointmentType ==
|
|
|
|
|
// 'Walkin'
|
|
|
|
|
// ? 'assets/images/walkin.png'
|
|
|
|
|
// : 'assets/images/booked.png',
|
|
|
|
|
// height: 25,
|
|
|
|
|
// width: 35,
|
|
|
|
|
// )),
|
|
|
|
|
// ])
|
|
|
|
|
// :
|
|
|
|
|
(isInpatient == true)
|
|
|
|
|
!isInpatient
|
|
|
|
|
? Row(
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.end,
|
|
|
|
|
children: [
|
|
|
|
|
Container(
|
|
|
|
|
padding: EdgeInsets.all(4),
|
|
|
|
|
child: Image.asset(
|
|
|
|
|
patientInfo.appointmentType ==
|
|
|
|
|
'Regular' &&
|
|
|
|
|
patientInfo.visitTypeId == 100
|
|
|
|
|
? 'assets/images/livecare.png'
|
|
|
|
|
: patientInfo.appointmentType ==
|
|
|
|
|
'Walkin'
|
|
|
|
|
? 'assets/images/walkin.png'
|
|
|
|
|
: 'assets/images/booked.png',
|
|
|
|
|
height: 25,
|
|
|
|
|
width: 35,
|
|
|
|
|
)),
|
|
|
|
|
])
|
|
|
|
|
: (isInpatient == true)
|
|
|
|
|
? Row(
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.end,
|
|
|
|
|
children: [
|
|
|
|
|
|