From d099ac9b57691573e5704fe841fb041bc63fca5e Mon Sep 17 00:00:00 2001 From: hussam al-habibeh Date: Sun, 7 Mar 2021 18:33:47 +0200 Subject: [PATCH] hussam --- .../prescription/add_prescription_form.dart | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/lib/screens/prescription/add_prescription_form.dart b/lib/screens/prescription/add_prescription_form.dart index e5c9f712..92c11f62 100644 --- a/lib/screens/prescription/add_prescription_form.dart +++ b/lib/screens/prescription/add_prescription_form.dart @@ -937,14 +937,6 @@ class _PrescriptionFormWidgetState extends State { // formKey.currentState.save(); // Navigator.pop(context); // openDrugToDrug(); - if (_selectedMedication - .isNarcotic == - true) { - DrAppToastMsg.showErrorToast( - "Narcotic medicine can only be prescribed from VIDA"); - Navigator.pop(context); - return; - } if (route == null || frequency == null || doseTime == null || @@ -955,6 +947,15 @@ class _PrescriptionFormWidgetState extends State { "Please Fill All Fields"); return; } + if (_selectedMedication + .isNarcotic == + true) { + DrAppToastMsg.showErrorToast( + "Narcotic medicine can only be prescribed from VIDA"); + Navigator.pop(context); + return; + } + if (double.parse( strengthController.text) > 1000.0) {