I have added 3 columns in drug_order table according to that I have changed HBM.xml and DrugOrder POJO in OpenMrs-core https://github.com/openmrs/openmrs-coreso how can I deploy this. I have to get new data in Bahmni core API module .not able to fetch data.
What fields are these? If these are generic, then I would suggest to start a discussion here so that we may discuss whether they should be included into the core model.
- Dispense date
- ARV drug dispense - true/false
- First ARV drug dispense date
Wouldn’t it be better to store them in a different model altogether, with FK ref to the drug_order? You can then expose a different api (get / update etc) in your custom module, and have them displayed appropriately in the UI?
Maybe if the drug dispense date can be made generic i.e. sans ARV, it might make a case for inclusion in OpenMRS. But anything specific to ARVs, I agree that these are better stored in a separate module.
I think the entire dispense functionality can be outside the core model. OpenMRS orders don’t have anything specific to dispensing. Also I don’t want to assume that drug dispensing correlation to just openmrs order/prescribed drugs. Imagine, if a patient is already taking meds, then irrespective of whether they are prescribed by a provider (at a specific clinic where she is admitted), you may still want to have some dispensing recorded. In FHIR medicationDispense resource, notice authorizingPrescription reference is not mandatory.
Dispense information more significant to reporting and M&E activities. In that case I believe that dispensing has to be related to a medication order since I want to know if the patient received the drug that was prescribed.
If the patient has medicines that were prescribed somewhere else, the doctor only wants to know if the drugs are active (i.e. the patient is consuming them) so that they can cross check their orders for any interactions / contraindications. Dispense status would not matter to them.
Regarding FHIR, I understand that it is not necessary that the prescription is dispensed in the same clinic where it was prescribed. Patients can purchase medicines at independent pharmacies as well. In that case we cannot ascertain the dispensing status hence it is not a mandatory resource in FHIR.
For an admitted patient, multiple dispensing activities will be against the same drug order. So its not an one time activity! Even in OPD, its not to say that all the prescribed quantities were dispensed, the pharmacy might dispense lesser (for example, if the patient can not pay for all the meds at a point). Marking it dispensed against the drug order makes it look like all the prescribed quantities were dispensed. More reasons not to have this in drug_order or order table! to be related to a medication order, it is not needed that you have to modify the drug_order or order table!