What the estimate is made of¶
Every figure Returns Portal prints comes from that order's own recorded prices, taxes and discounts, in that order's own currency at the rate it was placed at. Nothing is read from your catalogue, your coupon table or today's exchange rates. That is the whole of the claim, which is why every figure is labelled estimated refund and never refund.
For a line returned in part, the share is the stored line total divided by the quantity ordered, times the quantity coming back — the same arithmetic OpenCart uses to print that line on the order page, sliced.
Order-level rows¶
An order may carry rows that are not lines: a coupon, store credit, shipping. This is what happens to each.
| Row | Codes | Treatment | Why |
|---|---|---|---|
| Allocated across the lines | coupon, reward |
Spread evenly, in proportion to each line total | These are the two OpenCart itself applies to the goods and their tax, so a returned line has genuinely had a share of one. |
| Never allocated | credit, voucher |
Ignored | These pay for goods rather than discount them. Somebody who settled part of a 100.00 line with store credit still paid 100.00 for the goods. |
| Never in the estimate | shipping, handling, low_order_fee |
Ignored | Order-level charges, not part of what a line cost. Shipping is never added in, not even on a whole-order return. |
| Not read at all | sub_total, tax, total |
Ignored | These restate what the lines already say. The figures come from the lines themselves, so the sum and its parts cannot disagree. |
A row with a negative value and a code that is not in this table suppresses the customer's estimate for that order, and tells you on the request that it is incomplete. That is a discount from a third-party extension, which Returns Portal cannot see the shape of — so it declines to guess in front of the person who cannot check, and says so to the person who can. An unrecognised positive row is a fee, and fees were never in the estimate anyway.
Rounding¶
Components are held to 4 decimal places and rounded to 2 before anybody reads them. The total shown is the sum of the rounded parts, so a breakdown always adds up to the figure printed under it.
Whether the estimate is shown with tax follows your store's own Display Prices With Tax setting, so the returns page and the order page cannot contradict each other. You always see both components regardless.