-
Notifications
You must be signed in to change notification settings - Fork 137
Retail Sale Alternatives (Substitute Medicines)
buddhika edited this page Jul 16, 2026
·
1 revision
When a specific brand requested for a retail sale is out of stock, the pharmacy sale pages let the cashier look up in-stock alternatives — other brands of the same generic medicine — directly from the bill without leaving the sale screen, and swap one in with a single click.
This is the OPD counterpart to Ward Pharmacy BHT Substitute Functionality, which covers the same idea for inpatient (ward) issuing.
The Alternatives button and dialog appear on every bill-item row on these pages (all Pharmacy > Sale menu items except "Sale (Legacy)"):
| Menu Item | Page | Controller |
|---|---|---|
| Sale | pharmacy_bill_retail_sale_native.xhtml |
retailSaleNativeSqlController |
| Sale by Item | pharmacy_fast_retail_sale.xhtml |
pharmacyFastRetailSaleController |
| Sale for Cashier - By Item | pharmacy_fast_retail_sale_for_cashier.xhtml |
pharmacyFastRetailSaleForCashierController |
The older "Sale (Legacy)" page (pharmacy_bill_retail_sale.xhtml, pharmacySaleController) also has the same button and dialog.
- Add items to the bill as usual
- If a requested brand is out of stock (or a better-priced/longer-expiry alternative is preferred), click the 🔄 (Show Alternatives) button next to that bill-item row
- The Alternatives dialog opens, listing in-stock, non-expired alternatives for the same generic medicine (other brands of the same VMP), earliest-expiry-first (FEFO), with Item, Code, Rate, Stock, and Expiry columns
- Click Replace next to the desired alternative
- The dialog closes and the bill row, bill totals, and payment panel refresh to reflect the new item, batch, and rates
- For a specific brand (AMP/AMPP), alternatives are every other AMP that shares the same generic (VMP) — i.e. other brands of the same drug
- For a generic-level item (VMP/VMPP/VTM/ATM), alternatives are every brand under that generic
- Only stock that is in the current department, not expired, not retired, and has enough quantity to cover the existing line quantity is offered
- Only same-unit/pack substitutions are offered (the underlying lookup is AMP-to-AMP; it does not cross pack levels)
-
Show alternative medicines available during retail sale(Boolean, defaulttrue) - gates the Alternatives button and dialog on the Retail Sale, Fast Sale, and Sale for Cashier - By Item pages. When set tofalse, no button appears and no alternatives lookup runs.
- Ward Pharmacy BHT Substitute Functionality - the equivalent stock-based substitute feature for inpatient (ward) issuing
- Ward Medicine Request, Issue, and Return Workflow - covers the generic-level substitute available when a ward requests medicines, before pharmacy issues them
- Pharmacy Retail Sale