Editing an order after posting
Once an order has been invoiced, the invoice has been sent. Editing the order cannot un-send it.
So Yessort does not rewrite the original. It posts a further document for the difference, and links it to what came before.
What gets posted
More is owed — a supplementary invoice for the increase.
Less is owed — a credit note for the reduction.
Either way the original stands, and the pair together state the true position. That is also what your customer needs: they already have the first document, and reissuing it silently changed would be worse than useless.
The chain
Each further document points back at the one it follows, so an order edited three times has a chain rather than four unrelated documents. The chain is what makes "what have we actually invoiced for this order?" answerable — it is the sum of the chain, not the latest document.
Why the detail per rate matters
This is the part that is easy to get wrong and is worth understanding.
A post records its composition per account and tax code pair, not just as a total. So an invoice is not stored as "£500" but as its constituent parts, each with the account and tax code it belongs to.
Consider an edit that swaps a standard-rated item for a zero-rated one of similar value. The order total barely moves. If Yessort reconciled on totals alone it would post roughly nothing — and your tax would be wrong, quietly, in a way that nets out and looks fine.
Because composition is held per rate and account, the edit books faithfully: one rate down, another up, each recognised. The totals happening to be close is irrelevant.
Working out the difference
The already-invoiced position is the sum across the chain, per account and tax code. The new document covers the gap between that and what the order now says — which is why an edit after several previous edits still books correctly rather than double-counting.
The edit itself
How to edit an order, and what can be edited when, is Orders' — see editing orders. This page covers only what the accounting side does about it.
Returns and refunds
Value going back to the customer through a return or a refund also produces a credit note, by the same principle: the original stands and the reversal is posted alongside it.