|
|
|
@ -29,121 +29,119 @@ class ProcedureScreen extends StatelessWidget {
|
|
|
|
|
builder: (BuildContext context, ProcedureViewModel model, Widget child) =>
|
|
|
|
|
AppScaffold(
|
|
|
|
|
isShowAppBar: true,
|
|
|
|
|
baseViewModel: model,
|
|
|
|
|
appBar: PatientProfileHeaderNewDesignAppBar(
|
|
|
|
|
patient, arrivalType ?? '0', patientType),
|
|
|
|
|
body: NetworkBaseView(
|
|
|
|
|
baseViewModel: model,
|
|
|
|
|
child: SingleChildScrollView(
|
|
|
|
|
child: Container(
|
|
|
|
|
child: Column(
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 12,
|
|
|
|
|
),
|
|
|
|
|
Padding(
|
|
|
|
|
padding: const EdgeInsets.all(8.0),
|
|
|
|
|
child: Column(
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
Texts(
|
|
|
|
|
'Order Test or',
|
|
|
|
|
style: "caption2",
|
|
|
|
|
color: Colors.black,
|
|
|
|
|
fontSize: 13,
|
|
|
|
|
),
|
|
|
|
|
Texts(
|
|
|
|
|
'Procedure',
|
|
|
|
|
bold: true,
|
|
|
|
|
fontSize: 22,
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
body: SingleChildScrollView(
|
|
|
|
|
child: Container(
|
|
|
|
|
child: Column(
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 12,
|
|
|
|
|
),
|
|
|
|
|
Padding(
|
|
|
|
|
padding: const EdgeInsets.all(8.0),
|
|
|
|
|
child: Column(
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
|
children: [
|
|
|
|
|
Texts(
|
|
|
|
|
'Order Test or',
|
|
|
|
|
style: "caption2",
|
|
|
|
|
color: Colors.black,
|
|
|
|
|
fontSize: 13,
|
|
|
|
|
),
|
|
|
|
|
Texts(
|
|
|
|
|
'Procedure',
|
|
|
|
|
bold: true,
|
|
|
|
|
fontSize: 22,
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
if (patientType != null && patientType == '7' && patient.patientStatusType == 43)
|
|
|
|
|
InkWell(
|
|
|
|
|
onTap: () {
|
|
|
|
|
addSelectedProcedure(context, model, patient);
|
|
|
|
|
},
|
|
|
|
|
child: Container(
|
|
|
|
|
width: double.maxFinite,
|
|
|
|
|
height: 140,
|
|
|
|
|
margin: EdgeInsets.all(10),
|
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
|
color: Colors.grey[300],
|
|
|
|
|
borderRadius: BorderRadius.circular(10),
|
|
|
|
|
),
|
|
|
|
|
child: Center(
|
|
|
|
|
child: Container(
|
|
|
|
|
height: 90,
|
|
|
|
|
child: Column(
|
|
|
|
|
children: [
|
|
|
|
|
Container(
|
|
|
|
|
height: 40,
|
|
|
|
|
width: 40,
|
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
|
color: Colors.grey[600],
|
|
|
|
|
borderRadius: BorderRadius.circular(10),
|
|
|
|
|
),
|
|
|
|
|
child: Center(
|
|
|
|
|
child: Icon(
|
|
|
|
|
Icons.add,
|
|
|
|
|
color: Colors.white,
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
if (patientType != null && patientType == '7' && patient.patientStatusType == 43)
|
|
|
|
|
InkWell(
|
|
|
|
|
onTap: () {
|
|
|
|
|
addSelectedProcedure(context, model, patient);
|
|
|
|
|
},
|
|
|
|
|
child: Container(
|
|
|
|
|
width: double.maxFinite,
|
|
|
|
|
height: 140,
|
|
|
|
|
margin: EdgeInsets.all(10),
|
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
|
color: Colors.grey[300],
|
|
|
|
|
borderRadius: BorderRadius.circular(10),
|
|
|
|
|
),
|
|
|
|
|
child: Center(
|
|
|
|
|
child: Container(
|
|
|
|
|
height: 90,
|
|
|
|
|
child: Column(
|
|
|
|
|
children: [
|
|
|
|
|
Container(
|
|
|
|
|
height: 40,
|
|
|
|
|
width: 40,
|
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
|
color: Colors.grey[600],
|
|
|
|
|
borderRadius: BorderRadius.circular(10),
|
|
|
|
|
),
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 10,
|
|
|
|
|
child: Center(
|
|
|
|
|
child: Icon(
|
|
|
|
|
Icons.add,
|
|
|
|
|
color: Colors.white,
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
Texts(
|
|
|
|
|
'Add More Procedure',
|
|
|
|
|
color: Colors.grey[600],
|
|
|
|
|
fontWeight: FontWeight.w600,
|
|
|
|
|
)
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 10,
|
|
|
|
|
),
|
|
|
|
|
Texts(
|
|
|
|
|
'Add More Procedure',
|
|
|
|
|
color: Colors.grey[600],
|
|
|
|
|
fontWeight: FontWeight.w600,
|
|
|
|
|
)
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
if (model.procedureList.isNotEmpty)
|
|
|
|
|
...List.generate(
|
|
|
|
|
model.procedureList[0].rowcount,
|
|
|
|
|
(index) => ProcedureCard(
|
|
|
|
|
categoryID:
|
|
|
|
|
model.procedureList[0].entityList[index].categoryID,
|
|
|
|
|
entityList: model.procedureList[0].entityList[index],
|
|
|
|
|
onTap: () {
|
|
|
|
|
if (model.procedureList[0].entityList[index].categoryID ==
|
|
|
|
|
2 ||
|
|
|
|
|
model.procedureList[0].entityList[index].categoryID == 4)
|
|
|
|
|
updateProcedureForm(context,
|
|
|
|
|
model: model,
|
|
|
|
|
patient: patient,
|
|
|
|
|
remarks: model
|
|
|
|
|
.procedureList[0].entityList[index].remarks,
|
|
|
|
|
orderType: model.procedureList[0]
|
|
|
|
|
.entityList[index].orderType
|
|
|
|
|
.toString(),
|
|
|
|
|
orderNo: model
|
|
|
|
|
.procedureList[0].entityList[index].orderNo,
|
|
|
|
|
procedureName: model.procedureList[0]
|
|
|
|
|
.entityList[index].procedureName,
|
|
|
|
|
categoreId: model.procedureList[0]
|
|
|
|
|
.entityList[index].categoryID
|
|
|
|
|
.toString(),
|
|
|
|
|
procedureId: model.procedureList[0]
|
|
|
|
|
.entityList[index].procedureId,
|
|
|
|
|
limetNo: model.procedureList[0]
|
|
|
|
|
.entityList[index].lineItemNo);
|
|
|
|
|
// } else
|
|
|
|
|
// helpers.showErrorToast(
|
|
|
|
|
// 'You Cant Update This Procedure');
|
|
|
|
|
},
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
if (model.procedureList.isNotEmpty)
|
|
|
|
|
...List.generate(
|
|
|
|
|
model.procedureList[0].rowcount,
|
|
|
|
|
(index) => ProcedureCard(
|
|
|
|
|
categoryID:
|
|
|
|
|
model.procedureList[0].entityList[index].categoryID,
|
|
|
|
|
entityList: model.procedureList[0].entityList[index],
|
|
|
|
|
onTap: () {
|
|
|
|
|
if (model.procedureList[0].entityList[index].categoryID ==
|
|
|
|
|
2 ||
|
|
|
|
|
model.procedureList[0].entityList[index].categoryID == 4)
|
|
|
|
|
updateProcedureForm(context,
|
|
|
|
|
model: model,
|
|
|
|
|
patient: patient,
|
|
|
|
|
remarks: model
|
|
|
|
|
.procedureList[0].entityList[index].remarks,
|
|
|
|
|
orderType: model.procedureList[0]
|
|
|
|
|
.entityList[index].orderType
|
|
|
|
|
.toString(),
|
|
|
|
|
orderNo: model
|
|
|
|
|
.procedureList[0].entityList[index].orderNo,
|
|
|
|
|
procedureName: model.procedureList[0]
|
|
|
|
|
.entityList[index].procedureName,
|
|
|
|
|
categoreId: model.procedureList[0]
|
|
|
|
|
.entityList[index].categoryID
|
|
|
|
|
.toString(),
|
|
|
|
|
procedureId: model.procedureList[0]
|
|
|
|
|
.entityList[index].procedureId,
|
|
|
|
|
limetNo: model.procedureList[0]
|
|
|
|
|
.entityList[index].lineItemNo);
|
|
|
|
|
// } else
|
|
|
|
|
// helpers.showErrorToast(
|
|
|
|
|
// 'You Cant Update This Procedure');
|
|
|
|
|
},
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|