Billing/Pharmacy App

Purpose and Benefits

We can use the Billing App widget for the pharmacist to directly dispense medicines to the patient.


Configuration

Step1: Add a new privilege app:billing as in Screenshot below

Step2: Add a new Role Billing-App and assign the new privilege and others if any as in screenshot below

Step 3: Modify the user and assign the newly created role

Step 4: To make the widget appear on the home screen\dashboard

Edit the file at the path /openmrs/apps/home/extension.json to include the block below:

The name of the widget/app is the value given to the field label. For e.g. in this instance, the widget/app will be named "Prescription".


"bahmniBilling": {
       "id": "bahmni.billing",
       "extensionPointId": "org.bahmni.home.dashboard",
       "type": "link",
       "label": "Prescription",
       "url": "../clinical/#/default/patient/search",
       "icon": "fa-inr",
       "order": 8,
       "requiredPrivilege": "app:billing"
   },

Step 5: We define the action or URL to navigate to on clicking the widget using the BLOCK1 below.

Additionally we also provide a button on Medication TAB to direct the user to Quotations using the BLOCK2 below

Edit the file at the path /openmrs/apps/clinical/extension.json to include the two blocks below:

Block 1: Navigation URL
"bahmniBillingPatientsSearchActivePatients": {
    "id": "bahmni.billing.patients.search.activePatients",
    "extensionPointId": "org.bahmni.patient.search",
    "type": "config",
    "extensionParams": {
      "searchHandler": "emrapi.sqlSearch.activePatients",
      "display": "Active",
      "forwardUrl": "#/default/patient/{{patientUuid}}/dashboard/treatment?tabConfigName=allMedicationTabConfig"
    },
    "label": "Active",
    "order": 1,
    "requiredPrivilege": "app:billing"
  },

Block 2: To add the button on Medication Tab
"bahmniClinicalTreatmentLinks": {
	    "id": "bahmni.clinical.treatment.links",
	    "extensionPointId": "org.bahmni.clinical.treatment.links",
	    "type": "link",
	    "label": "Open <u>Q</u>uotation",
	    "url": "http://192.168.33.14:8069/quotations/latest?patient_ref={{patient_ref}}&dispensed=false&location_ref={{location_ref}}",
	    "shortcutKey": "q",
	    "requiredPrivilege": "app:billing"
	  },


Step 6: Login using the newly created user credentials assigned with the Billing App privilege.

The homepage display widgets assigned to the logged in user based on the access rights or privileges available to the user.

On clicking on the “Prescription” widget on the home screen, we are presented with a patient search queue as defined in the block above.

Selecting a patient from the queue enables us to view the Patient’s prescription directly.

Step 7: Click on button “Open Quotation”. If you are already logged into ERP it will automatically direct you to the Quotations else the login screen of ERP will be presented.


The Bahmni documentation is licensed under Creative Commons Attribution-ShareAlike 4.0 International (CC BY-SA 4.0)