|
|
|
|
@ -1,3 +1,4 @@
|
|
|
|
|
import 'package:doctor_app_flutter/config/size_config.dart';
|
|
|
|
|
import 'package:doctor_app_flutter/core/viewModel/prescription/prescription_view_model.dart';
|
|
|
|
|
import 'package:doctor_app_flutter/core/model/patient/patiant_info_model.dart';
|
|
|
|
|
import 'package:doctor_app_flutter/screens/base/base_view.dart';
|
|
|
|
|
@ -11,8 +12,10 @@ import 'package:doctor_app_flutter/widgets/patients/patient_service_title.dart';
|
|
|
|
|
import 'package:doctor_app_flutter/widgets/patients/profile/add-order/addNewOrder.dart';
|
|
|
|
|
import 'package:doctor_app_flutter/widgets/patients/profile/app_bar/patient-profile-app-bar.dart';
|
|
|
|
|
import 'package:doctor_app_flutter/widgets/shared/app_scaffold_widget.dart';
|
|
|
|
|
import 'package:doctor_app_flutter/widgets/shared/card_with_bg_widget.dart';
|
|
|
|
|
import 'package:doctor_app_flutter/widgets/shared/doctor_card.dart';
|
|
|
|
|
import 'package:doctor_app_flutter/widgets/shared/network_base_view.dart';
|
|
|
|
|
import 'package:doctor_app_flutter/widgets/shared/user-guid/CusomRow.dart';
|
|
|
|
|
import 'package:doctor_app_flutter/widgets/shared/user-guid/in_patient_doctor_card.dart';
|
|
|
|
|
import 'package:doctor_app_flutter/widgets/transitions/fade_page.dart';
|
|
|
|
|
import 'package:doctor_app_flutter/widgets/transitions/slide_up_page.dart';
|
|
|
|
|
@ -121,14 +124,22 @@ class OldPrescriptionsPage extends StatelessWidget {
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
)
|
|
|
|
|
: NetworkBaseView(
|
|
|
|
|
baseViewModel: model,
|
|
|
|
|
child: FractionallySizedBox(
|
|
|
|
|
widthFactor: 1.0,
|
|
|
|
|
child: ListView(
|
|
|
|
|
physics: BouncingScrollPhysics(),
|
|
|
|
|
: Center(
|
|
|
|
|
child: FractionallySizedBox(
|
|
|
|
|
widthFactor: 0.9,
|
|
|
|
|
child: SingleChildScrollView(
|
|
|
|
|
child: Column(
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 12,
|
|
|
|
|
),
|
|
|
|
|
ServiceTitle(
|
|
|
|
|
title: TranslationBase.of(context).orders,
|
|
|
|
|
subTitle: TranslationBase.of(context)
|
|
|
|
|
.prescriptions + "(${TranslationBase.of(context)
|
|
|
|
|
.old }) ",
|
|
|
|
|
),
|
|
|
|
|
model.medicationForInPatient.length == 0?
|
|
|
|
|
Center(
|
|
|
|
|
child: ErrorMessage(
|
|
|
|
|
@ -142,23 +153,52 @@ class OldPrescriptionsPage extends StatelessWidget {
|
|
|
|
|
itemBuilder: (context, index) {
|
|
|
|
|
//model.medicationForInPatient.length,
|
|
|
|
|
return InkWell(
|
|
|
|
|
child: InPatientDoctorCard(
|
|
|
|
|
doctorName: Helpers.convertToTitleCase(model
|
|
|
|
|
.medicationForInPatient[index]
|
|
|
|
|
.pHRItemDescription),
|
|
|
|
|
profileUrl: 'sss',
|
|
|
|
|
branch: 'hamza',
|
|
|
|
|
clinic: 'basheer',
|
|
|
|
|
isPrescriptions: true,
|
|
|
|
|
appointmentDate: AppDateUtils
|
|
|
|
|
.getDateTimeFromServerFormat(
|
|
|
|
|
model.medicationForInPatient[index]
|
|
|
|
|
.prescriptionDatetime,
|
|
|
|
|
child: CardWithBgWidget(
|
|
|
|
|
bgColor: Colors.transparent,
|
|
|
|
|
widget: Column(
|
|
|
|
|
children: [
|
|
|
|
|
CustomRow(
|
|
|
|
|
label: "",
|
|
|
|
|
value: Helpers.convertToTitleCase(model
|
|
|
|
|
.medicationForInPatient[index]
|
|
|
|
|
.pHRItemDescription),
|
|
|
|
|
valueSize: SizeConfig
|
|
|
|
|
.getTextMultiplierBasedOnWidth() *
|
|
|
|
|
3.5,
|
|
|
|
|
),
|
|
|
|
|
SizedBox(
|
|
|
|
|
height: 10,
|
|
|
|
|
),
|
|
|
|
|
CustomRow(
|
|
|
|
|
label: "Doctor Name :",
|
|
|
|
|
value: Helpers.convertToTitleCase(model
|
|
|
|
|
.medicationForInPatient[index]
|
|
|
|
|
.doctorName
|
|
|
|
|
.toString()),
|
|
|
|
|
),
|
|
|
|
|
CustomRow(
|
|
|
|
|
label: "Status :",
|
|
|
|
|
value: Helpers.convertToTitleCase(model
|
|
|
|
|
.medicationForInPatient[index]
|
|
|
|
|
.statusDescription
|
|
|
|
|
.toString()),
|
|
|
|
|
),
|
|
|
|
|
CustomRow(
|
|
|
|
|
label: "dose :",
|
|
|
|
|
value: Helpers.convertToTitleCase(model
|
|
|
|
|
.medicationForInPatient[index]
|
|
|
|
|
.dose
|
|
|
|
|
.toString()),
|
|
|
|
|
), CustomRow(
|
|
|
|
|
label: "comments :",
|
|
|
|
|
value: Helpers.convertToTitleCase(model
|
|
|
|
|
.medicationForInPatient[index]
|
|
|
|
|
.comments
|
|
|
|
|
.toString()),
|
|
|
|
|
),
|
|
|
|
|
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
createdBy: Helpers.convertToTitleCase(model
|
|
|
|
|
.medicationForInPatient[index]
|
|
|
|
|
.doctorName
|
|
|
|
|
.toString()),
|
|
|
|
|
),
|
|
|
|
|
onTap: () => Navigator.push(
|
|
|
|
|
context,
|
|
|
|
|
@ -188,6 +228,7 @@ class OldPrescriptionsPage extends StatelessWidget {
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
)));
|
|
|
|
|
),
|
|
|
|
|
)));
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|