Skip to content
ERP Expert

Station 5 of 10

The sales cycle in ERPNext

Ahmed Hassan Algammal6 min read

What you leave this station with

A full sales cycle run by your own hand, and a working grasp of when quantity is reserved, when revenue is recognised, and where the cost of goods sold figure comes from.

In shape, the sales cycle mirrors the purchase cycle. It differs in two places, and those two carry all the weight: revenue is recognised here, and cost of goods sold is calculated here. Get either one wrong and you have a wrong margin that surfaces only after the close.

Six documents and what each one does

# Document Stock ledger General ledger
1 Lead and opportunity Nothing Nothing
2 Quotation Nothing Nothing
3 Sales order Reserves quantity — no movement Nothing
4 Delivery note An outbound line at its value The cost of goods sold entry
5 Sales invoice Nothing Revenue, tax and receivables
6 Payment entry Nothing An entry, always

The substantive difference from purchasing sits in row three: the sales order touches inventory without moving it. No inbound line and no outbound line, but the quantity is now reserved — and reserved quantity leaves the pool available to sell.

The four quantities

Quantity What it means Who uses it
Actual What is in the warehouse right now The storekeeper
Reserved What you promised customers and have not shipped Sales
Available Actual minus reserved Whoever decides to sell today
Projected Available plus what is on order to buy Purchasing and planning

The quantity that governs a selling decision is the available one, not the actual one. Read the actual figure and you sell goods already promised to somebody else, and you finish the month with two angry customers and a salesperson complaining about “system errors”.

So when the system tells you quantity is insufficient while a report shows a balance, this table is the answer: the balance is actual, and the objection is about available. Half the support calls at this station close on that one sentence.

The entry generated at delivery that nobody opens

Submitting a delivery note under perpetual inventory produces a two-sided entry:

  • Debit: cost of goods sold.
  • Credit: the warehouse stock account.

Three observations on it are worth stopping for.

Its value is not the selling price. It is the valuation of the goods, computed by the costing method you chose on the item card — first in first out, or moving average. That is the direct link between this station and station six.

It is generated at delivery, not at invoicing. Deliver in March and invoice in April and the cost sits in March while the revenue sits in April — so March shows a loss and April shows a fictitious profit. This is the commonest cause of “why did the month’s margin collapse?”, and there is no technical fault anywhere in it.

Nobody opens it. The user passes over the delivery screen, presses submit, and never looks behind it. That is precisely the screen every profitability number in the company is built on.

When revenue is recognised

At submission of the sales invoice, and not before:

  • Debit: receivables, at the gross.
  • Credit: revenue, at the net.
  • Credit: tax payable, at its amount.

Revenue is not at delivery and not at collection. Collection neither increases nor decreases revenue; it converts a receivable into cash.

Read that twice, because more than half of the people who learn these systems without an accounting foundation believe a sale is recorded when the money arrives — and then cannot explain why the income statement shows a profit while the bank account is empty.

The four cases that make the difference

Partial invoicing. An order for a hundred, a delivery of forty, an invoice for forty. Read what stays open on the order, and take the point: the order carries three numbers, not one — ordered, delivered, and invoiced.

A customer advance. Cash arrives before anything is delivered. It is a liability, not revenue, until something ships. Read the account it landed in and confirm it sits on the liabilities side of the balance sheet rather than in the income statement.

A credit note. The only route to correcting a submitted invoice. It links to the original, reverses its effect wholly or partly, and both stay in the record. That is the same mechanism e-invoicing imposes at station eight — master it here and you arrive there with the requirement already met.

A sale with no stock. A service, or a non-stock item. No delivery note, no cost of goods sold entry, and the invoice alone is the event. Comparing that case against the ordinary one shows you exactly where margin lives.

The three commonest errors

Invoicing without delivering, as a habit. It works, and it produces revenue with no cost in the same month, so the margin looks excellent — until the delivery lands in a later month and inverts it.

Reading the actual balance instead of the available one. Described above, and it is the single most widespread misunderstanding among sales users.

Correcting an invoice by cancelling it and reissuing under a new number with no credit note. It works inside the system, and it becomes a real problem once that invoice number has been transmitted to a tax authority. The reason is at station eight.

The acceptance test for this station

  1. Run the full cycle: quotation, sales order, delivery, invoice, collection.
  2. Read the four quantities on the item after the sales order and before the delivery, and explain each one in a sentence.
  3. Open the cost of goods sold entry produced by the delivery and compare its value against the item’s valuation. If they do not match you are looking at a lesson, not a bug.
  4. Post a customer advance and confirm it landed in liabilities rather than revenue.
  5. Issue a credit note against a submitted invoice, read its entry, and confirm the original invoice was not touched.

The same cycle with its accounting logic independent of any product is set out in order to cash, quote to collection. What this product ships for the sales cycle, and where it needs additional implementation work, is detailed in the ERPNext guide.

What comes next

Two full cycles executed, and their entries read. The next station answers the question left hanging twice: where exactly the cost of goods sold figure came from — and why changing one line on an item card changes your margin, numerically rather than descriptively.