Fix add medication button

merge-requests/967/head
RoaaGhali98 4 years ago
parent d5e3a79f85
commit ce978db2dd

@ -229,19 +229,6 @@ class MedicineViewModel extends BaseViewModel {
} }
Future getPrescription({int mrn}) async {
//hasError = false;
//_insuranceCardService.clearInsuranceCard();
setState(ViewState.Busy);
await _prescriptionService.getPrescription(mrn: mrn);
if (_prescriptionService.hasError) {
error = _prescriptionService.error;
setState(ViewState.ErrorLocal);
} else
setState(ViewState.Idle);
}
Future getMedicineItem(String itemName) async { Future getMedicineItem(String itemName) async {
setState(ViewState.Busy); setState(ViewState.Busy);
await _medicineService.getMedicineItem(itemName); await _medicineService.getMedicineItem(itemName);

@ -11,6 +11,7 @@ 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/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/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/app_scaffold_widget.dart';
import 'package:doctor_app_flutter/widgets/shared/app_texts_widget.dart';
import 'package:doctor_app_flutter/widgets/shared/doctor_card.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/network_base_view.dart';
import 'package:doctor_app_flutter/widgets/shared/user-guid/in_patient_doctor_card.dart'; import 'package:doctor_app_flutter/widgets/shared/user-guid/in_patient_doctor_card.dart';
@ -117,19 +118,28 @@ class PrescriptionsPage extends StatelessWidget {
), ),
), ),
), ),
child: DoctorCard( child: Container(
doctorName: child: Column(
model.prescriptionsList[index].doctorName, children: [
profileUrl: model AppText(
.prescriptionsList[index].doctorImageURL, model.prescriptionsList[index].despensedStatus,
branch: model.prescriptionsList[index].name, ),
clinic: model.prescriptionsList[index] DoctorCard(
.clinicDescription, doctorName:
isPrescriptions: true, model.prescriptionsList[index].doctorName,
appointmentDate: profileUrl: model
AppDateUtils.getDateTimeFromServerFormat( .prescriptionsList[index].doctorImageURL,
model.prescriptionsList[index] branch: model.prescriptionsList[index].name,
.appointmentDate, clinic: model.prescriptionsList[index]
.clinicDescription,
isPrescriptions: true,
appointmentDate:
AppDateUtils.getDateTimeFromServerFormat(
model.prescriptionsList[index]
.appointmentDate,
),
),
],
), ),
))), ))),
if (model.prescriptionsList.isEmpty && if (model.prescriptionsList.isEmpty &&

Loading…
Cancel
Save