Pharma Distribution Management System Batch, Expiry, Trade Price and GST — Handled on Every Invoice
Purchase from pharmaceutical companies by batch and expiry, sell to pharmacies and medical stores at trade price with the right discount, GST and advance tax, process returns both ways, and know exactly what is on the shelf, what is about to expire and who owes you what. Built by Xelent Solutions for medicine distributors in Pakistan.
Is Your Distribution Still Running on a Sales Register and a Phone Call to the Godown?
Most medicine distributors in Pakistan run on a bill book, a stock register per company, and a salesman who knows which pharmacy gets which discount. It works — until a near-expiry batch is invoiced to a hospital, the GST summary does not match the invoices, and nobody can say what the company ledger actually stands at.
A near-expiry batch gets invoiced to a hospital because the stock register only shows a total quantity per product, not which batch is going out
Every pharmacy has "its own" discount that lives in the salesman's head; when he leaves, the next invoice is wrong and the customer notices
GST and advance tax are worked out on a calculator at the bottom of the bill; the monthly GST summary never quite matches the invoices
A return comes back from a medical store and nobody can say which invoice, which batch or which price it was originally sold at
Company ledgers are reconciled once a quarter from a box of invoices; the distributor finds out about a disputed balance when the next consignment is held
The owner wants to know which area is growing and which pharmacy stopped ordering a product, and the answer is "let me check the register"
Everything hangs off the batch.
Purchase Order → Batch & Expiry into Stock → Sale Order picks the Batch → Invoice with Discount, GST & Advance Tax → Return against Invoice → Customer & Company Ledgers
Every Pack on the Shelf Knows Its Batch, Its Expiry and Which Purchase It Came From
Stock is never a single number per product. Each purchase order line creates its own batch with a batch number, expiry date, quantity and trade price, and every sale draws from a specific batch. The expiry alert report shows what is due in the next 30, 60 or 90 days, already-expired stock is flagged on the dashboard, and the batch traceability report follows one batch from the company invoice to every pharmacy it was sold to.
- Each purchase order line creates a batch with batch number, expiry, quantity and trade price
- Sale orders show available batches per product with quantity and expiry; the batch is chosen on the line
- Expiry alert report for the next 30, 60 or 90 days; expired-on-shelf count on the dashboard
- Batch traceability from the company purchase to every customer invoice and return
- Min, max and reorder level per product; reorder report lists what to order from which company
- Dead stock and slow/fast moving reports show what to stop buying and what to push
Panadol Extra 500mg · 10×10
GSK Pakistan
Augmentin 625mg · 6s
GSK Pakistan
Risek 40mg · 14s
Getz Pharma
Brufen 400mg · 250s
Abbott
Glucophage 500mg · 10×10
Martin Dow
Arinac Forte · 10×10
Abbott
Cefspan 400mg · 5s
Barrett Hodgson
Six Steps From the Company Invoice to a Settled Pharmacy Account
Each step writes to the same product, batch and ledger records. The purchase clerk never re-types the batch; the salesman never re-types the price; the accountant never re-types the invoice.
Purchase Order
Raise a PO on a pharmaceutical company with its invoice number and date. Each line records the product, batch number, expiry, quantity, trade price and the tax snapshot in force on that day.
Batches created · company ledger debited
Stock by Batch
Stock is held per batch, per product, linked back to the PO line it came from. Min, max and reorder levels per product drive the reorder report and low-stock alerts on the dashboard.
Every pack traceable to a purchase
Sale Order
Pick the customer, see their group and discount, add products, choose from available batches with expiry shown, and apply the customer's entitlement, GST and advance tax automatically.
Invoice numbered · batch quantity reduced
Invoice & Print
Print one invoice or bulk-print the day's run for the delivery van, with company name, NTN, licence, logo and warranty text from settings.
Customer ledger debited
Returns
Sale returns from pharmacies and purchase returns to companies, raised against an order or in open mode, with GST reversed and saleable stock returned to its batch.
Stock, customer and company ledgers adjusted together
Ledgers & GST
Customer ledger and company ledger with running balances; GST summary, discount analysis and profit margin reports for the month-end and the tax return.
Books match the invoices
Twelve Modules. One Batch Record.
A purchase creates batches, a sale consumes them, a return puts them back or writes them off, and every movement lands on the stock ledger, the customer ledger and the company ledger. Nothing is typed twice.
Purchase Orders
- PO number, company invoice number and purchase date
- Lines with batch, expiry, quantity, trade price and tax snapshot
- Bulk print and PO-wise purchase report
Batch Stock & Expiry
- Quantity per batch per product, linked to the purchase line
- Expiry alert, expired-on-shelf and batch traceability
- Min, max and reorder level per product with reorder report
Sale Orders & Invoices
- Batch selection with expiry on every line
- Customer discount, group price, GST and advance tax applied automatically
- Bulk print, notes and invoice-wise sales report
Sale & Purchase Returns
- Against-order mode pulls the original batch, quantity and price
- Open mode resolves stock from customer or company history
- GST reversed; saleable stock back to batch
Products & Companies
- Generic name, MRP, trade price, pack size, default discount and tax
- Item types for tablets, syrups, injections and more
- Each pharmaceutical company with its own products and ledger
Customers & Groups
- Pharmacy, medical store, hospital, clinic or wholesaler with licence and NTN
- Customer groups with their own discount; product prices per group
- Country, state, city and area on every customer
Taxes
- GST rates configured once and snapshotted on each order
- Advance tax handled per customer type
- GST summary report ready for the return
Customer & Company Ledgers
- Running balance per pharmacy and per company
- Invoices, returns and payments on one statement
- Printable ledger by date range
Profitability
- Profit margin by product and by invoice
- Customer profitability and group performance
- Discount analysis: who gets what and what it costs
Area & City Sales
- Sales by area and city over any period
- Customer sale comparison month on month
- Customer-product report for dropped SKUs
Users, Roles & 2FA
- Roles with per-module, per-action permissions
- Two-factor authentication on login
- Company, brand and return-mode settings behind a permission
Dashboard
- Today's and this month's net sales and purchases
- Low stock, expiring soon and expired counts
- Top customers and top products this month
Trade Price, the Customer's Discount, GST and Advance Tax — Computed Once, Printed Right
Every product carries MRP, trade price and a default distributor discount. A pharmacy can belong to a customer group with its own discount, and a product can have group-specific prices on top. When the salesman picks the product, the system shows the available batches with quantity and expiry, applies the discount the customer is entitled to, adds GST at the configured rate and advance tax where it applies, and prints an invoice with the company name, NTN, licence number and your branding. The sales default discount, return modes and company details are all settings, not code.
Price comes from the product and the group
MRP, trade price and the default discount live on the product; the customer's group discount and any group-specific price override them, so the salesman does not negotiate at the counter.
Batch is chosen on the line
Available batches appear with quantity and expiry; the line records which batch left the shelf, so returns and traceability work later.
Tax is snapshotted, not recalculated
The GST rate and type in force on the order date are stored with the order. A later rate change never rewrites an old invoice.
Print one or print the run
Single invoice or bulk print for the delivery van, with company name, NTN, licence, logo and footer text from settings.
Retail pharmacy · Jaranwala Road, Faisalabad · Group: Key Accounts (16%)
Panadol Extra 500mg · 10×10 × 40
TP 148.50 · disc 16% · GST 18% · exp Jul 2028
Rs 5,940
Glucophage 500mg · 10×10 × 60
TP 96.75 · disc 16% · GST 18% · exp Aug 2028
Rs 5,805
Risek 40mg · 14s × 30
TP 268.20 · disc 18% (line override) · exp Jan 2027 · short-dated
Rs 6,598
Cefspan 400mg · 5s × 24
TP 486.00 · disc 16% · GST exempt · exp Mar 2027
Rs 9,798
Brufen 400mg · 250s × 6
TP 1,120.00 · disc 16% · GST 18% · exp Sep 2028
Rs 5,645
Augmentin 625mg · 6s × 50
TP 512.00 · disc 16% · GST 18% · exp Dec 2026
Rs 21,504
Customer ledger after this invoice
Balance Rs 1,24,660 · 3 open invoices
Augmentin 625mg · 6s
AG2512C · exp Dec 2026 · TP 512.00
Panadol Extra 500mg · 10×10
PX2607A · exp Jul 2028 · TP 148.50
Risek 40mg · 14s
RK2701B · exp Jan 2027 · TP 268.20
Glucophage 500mg · 10×10
GL2608D · exp Aug 2028 · TP 96.75
Credit to customer
Rs 7,920
GST reversed
Rs 1,426
Saleable stock
Back to batch
Returns Go Back to the Batch They Came From. Ledgers Balance Themselves.
A pharmacy sends back expired or excess stock; you send near-expiry stock back to the company. Both are first-class documents. In against order mode a return is raised against a specific invoice or purchase order, with the batch, sold quantity and price pulled in automatically. In open mode the system resolves the batch from the customer's or company's purchase history. Either way the stock ledger, the customer ledger and the company ledger move together, GST on the return is reversed, and the return prints in bulk alongside invoices.
- Sale returns against an invoice: original batch, quantity sold and price pulled in; returned quantity capped at what was sold
- Purchase returns against a PO: send near-expiry or damaged stock back to the company with the batch history on screen
- Open-mode returns resolve the batch from the customer's or company's history when the original document is not to hand
- Return mode is a company setting; switch per return type without touching the data
- GST on returned lines reversed with its own tax snapshot; sale return and purchase return reports for the period
- Customer and company ledgers show invoice, return and balance on one statement
Pharmacies by Area. Areas by City. Sales by Both.
Customers are typed — retail pharmacy, medical store, hospital, clinic, wholesaler — and placed in a country, state, city and area, with licence number and NTN on file. Areas can be created from the customer form while a salesman is onboarding a new shop. On the supply side, each pharmaceutical company you buy from has its own products, purchase orders, returns and ledger. The area and city sale report tells you which territory is growing, the customer comparison report shows who bought less this month than last, and the customer-product report shows exactly which SKUs a pharmacy stopped ordering.
- Customer types: retail pharmacy, medical store, hospital, clinic, wholesaler; licence number and NTN on file
- Country, state, city and area hierarchy; new areas created from the customer form while onboarding
- Customer groups carry a discount; products can carry a price per group
- Area and city sale report, customer group performance and customer sale comparison
- Each pharmaceutical company with its own product catalogue, purchase orders, returns and ledger
- Customer and product search built for a salesman typing on the phone
14 pharmacies, 2 clinics. Al-Shifa and Madina Medical up on antibiotics; one new medical store onboarded this week.
Customer comparison flags City Pharmacy: Rs 84K last month, Rs 31K this month. Customer-product report shows Risek and Cefspan dropped.
Hospital type, group "Institutions" at 20%. Advance tax not applicable (registered). Monthly ledger statement emailed to procurement.
Three POs this month; one purchase return of 12 × Augmentin near expiry posted and awaiting credit note on the company ledger.
Group performance report compares revenue, discount given and margin per group so the owner sees what each discount tier actually costs.
Area and city sale report ranks territories for the month; the salesman roster is planned from it.
Twenty-Five Reports, Filtered by Date, Company, Customer and Area
Every report is built on the same batch, invoice and ledger data the daily work produces, so the GST summary matches the invoices and the stock report matches the shelf. Reports print and export to Excel.
Stock, Batch & Ledger
Stock report, batch-wise stock and the stock ledger per product, so the system's shelf and the godown's shelf agree.
Expiry Alert
Batches expiring within 30, 60 or 90 days with quantity, trade price and the customers who usually buy them, in time to push or return.
Sales & Purchases
Daily sales, daily purchases, sales and purchase reports by date, customer, company and product, each exportable.
Customer & Company Ledgers
Running statements per pharmacy and per pharmaceutical company covering invoices, returns and payments.
GST Summary
Output tax on sales and the reversal on returns for the period, matched to invoice numbers for the tax return.
Profit Margin & Profitability
Margin by product and invoice, customer profitability and customer group performance net of discounts.
Area & City Sales
Territory ranking, customer sale comparison month on month, and the customer-product report for SKUs a shop stopped ordering.
Return Reports
Sale returns and purchase returns by period, customer or company, with reasons and the GST reversed.
Movement & Reorder
Slow and fast moving, dead stock, reorder and discount analysis so buying follows what actually sells.
The full report list
Built for Businesses That Sit Between the Manufacturer and the Counter
The same system runs a single-company stockist with one van and a multi-company distributor with a sales team across three cities. Roles decide who sees what.
Single-Company Stockists
One or two principals, one godown, a van and a salesman. You need batch stock, correct invoices with GST and a ledger per pharmacy without hiring an accountant.
- Batch and expiry from the first PO
- Invoice with discount, GST and advance tax
- Customer ledger the owner can read
Multi-Company Distributors
Several pharmaceutical companies, hundreds of SKUs, a sales team on areas. You need group pricing, territory reports and a ledger per company that survives an audit.
- Customer groups and group prices
- Area, city and salesman-ready reports
- Company ledgers and purchase returns
Wholesale Counters
Walk-in medical stores and sub-distributors buying at trade price. You need fast order entry, bulk printing and returns that do not break the stock count.
- Fast product and customer search
- Bulk print for the day's run
- Open-mode returns when the invoice is not to hand
Roles included out of the box
Permissions are enforced on the server per module and per action — viewing a report, editing a price, raising a return or changing company settings are separate abilities. Two-factor authentication is available for every login.
Taking on a new company's distribution?
Load the product list with MRP, trade price and discounts before the first consignment lands, and invoice from a batch instead of a bill book from day one.
Frequently Asked Questions
What distributors and their accountants ask us first.
How does batch and expiry tracking actually work?
Every purchase order line creates a batch with its own batch number, expiry date, quantity and trade price. When a sale order is entered, the product line shows the available batches with quantity and expiry, and the batch chosen is stored on the invoice line. Returns reference the same batch. The expiry alert report lists batches due in the next 30, 60 or 90 days, and the dashboard shows how many are expiring soon or already expired.
Can different pharmacies get different prices and discounts?
Yes. Each product has an MRP, a trade price and a default discount. Customers can be placed in groups, each group carries its own discount, and a product can have a specific price per group. The sale order applies the right combination automatically, and a line-level override is still possible for a one-off deal. The discount analysis report then shows what each tier is costing you.
How are GST and advance tax handled?
Tax rates are configured once in the taxes module. When an order is saved, the rate and type in force are snapshotted on the order, so a later rate change never alters an old invoice. Advance tax is applied according to the customer's registration status. The GST summary report totals output tax on sales and the reversal on returns for the period, matched to invoice numbers. The invoicing layer follows the same approach Xelent uses across its products, so FBR digital invoicing can be added where a distributor needs it.
What happens when a pharmacy returns stock?
A sale return is raised against the original invoice, which pulls in the batch, quantity sold and price, and caps the returned quantity at what was sold. If the invoice is not available, open mode resolves the batch from the customer's purchase history. Saleable stock goes back to its batch, GST is reversed, and the customer ledger is credited. Purchase returns to the pharmaceutical company work the same way against the PO.
Does it handle more than one pharmaceutical company?
Yes. Each company you distribute for has its own products, purchase orders, purchase returns and ledger. Reports can be filtered by company, so you can hand each company representative a statement and a sales summary for their products alone.
Can my sales officers see only what they need?
Yes. Roles are built from per-module, per-action permissions: a sales officer can create sale orders and look up stock without seeing purchase prices or company ledgers; a store keeper can receive purchases without raising invoices; the accountant sees ledgers and GST. Two-factor authentication is available on every account, and company settings, branding and return modes sit behind their own permission.
Know What Is Expiring, What Is Owed and What Each Area Sold — Before the Company Rep Asks
Bring one company's price list, a week of invoices and your customer list. We will load them into a demo instance and walk you from a purchase order to a GST summary in under an hour.
Built and run by Xelent Solutions in Faisalabad — a PSEB-registered software house.
What Our Clients Say
Trusted by businesses across industries. Here's what they say about working with Xelent.
"I am very happy to use this Laravel Site Builder. It is very powerful and easy to use. It save a lot of time for development. Everything is organized good and work very smooth. Bilal show strong technical skill and responsible attitude. He is serious and professional developer. I trust his work quality. I feel very satisfied with this project."
"I have worked with Bilal for close to twenty years. I trusted him then, and I trust him completely now, which in this industry says everything. Xelent delivers top-quality service across the board. Even as they've grown so much, the service has never slipped. Not even once. If you want a company that is dependable, forward-thinking, and consistently delivers at the highest level, Xelent is exactly that."
"Xelent has always doing incredible work for us, at a reasonable rate! We are most impressed with the communication and understanding of updates/changes that need to be done. We are a US based company, and have tried other developers overseas, but none of them have performed as well as Xelent. Working with Bilal is a pleasure, and we will continue to send website development projects their way. I'd recommend you have them bid your next project!"
"Its been a pleasure getting my work done by Xelent Solutions team. Highly understandable, least instructions given with most amount of work out put. Looking forward to work more in future as well."
"It's always a pleasure working with this team. A true professional, fast and on budget! Hired a couple times and will do it again."
"I couldn't be any happier about my experiences with Xelent Solutions. I had a very short, tight deadline, and they worked around the clock to get the job done - perfectly. Can't wait to work with them again!"
Trusted by businesses worldwide. See what our clients say about us.
