Dinar POS · reference
Every row of the spec is an assumption until a comptable or a stamped facture confirms it. What the code enforces today, and what still waits on an answer.
| Rule | What the code does | State |
|---|---|---|
| TVA rounding | once per rate group on the group's HT subtotal, half away from zero, rates at most 10 000 bps | comptable |
| Discount spread | proportional to HT, floored, leftover to the largest HT, ties to the lower rate | comptable Q7 |
| Droit de timbre | cash only, zero at or under 300 DA, ceil per 100 DA at 1 / 1,5 / 2 DA by band, minimum 5 DA, base total TTC | comptable |
| Amount in words | computed on net_to_pay; décret 05-468 says the TTC total | comptable Q8 |
| Arabic wording | hand-written generator, 01/02 group pattern first to check | native review |
| Cancelled facture | keeps its number; the décret only requires the diagonal mention | comptable Q4 |
| Régime IFU | dated setting read by the core; no TVA line on documents | pinned, fixture in M1 |
| Money storage | STRICT tables, CHECK on every centimes and rate column, 2^53 bound at the API | enforced |