invoices: accountant confirms the numbering scheme #52
Etiketter
Inga etiketter
area/backups
area/ci
area/control-panel
area/identity
area/infra
area/observability
area/payments
area/security
area/storage
area/web
blocked
needs-info
needs-triage
priority
high
priority
low
priority
medium
ready-for-implementation
type
bug
type
chore
type
docs
type
epic
type
feature
type
task
wontfix
Ingen milstolpe
Inget projekt
Inga tilldelade
1 deltagare
Notiser
Förfallodatum
Inget förfallodatum satt.
Beroenden
Inga beroenden satta
Referens
bitborg/bitborg-payment#52
Läser in…
Hänvisa till i nytt ärende
Ingen beskrivning angiven.
Ta bort grenen "%!s()"
Borttagning av en gren är permanent. Även om den borttagna grenen kan fortsätta existera en kort tid innan den faktiskt tas bort, kan det INTE ångras i de flesta fall. Vill du fortsätta?
Problem
Bokföringslagen (1999:1078) requires verifikationer in an unbroken series, so invoices need a gapless, ordered number. The accountant must confirm the scheme.
Done already
The allocator is built (#59): a counter row updated in the invoicing transaction, as the last statement before commit. Tests prove no gap on rollback and no collision under 40 concurrent issuers.
Left
Get the accountant's confirmation of:
paidAt(#65). The withdrawal window then runs from payment. A late repair leaves the customer fewer of the 14 days, and those days count as used in a proportional refund.Done when
paidAtstart is confirmed.Close by hand after that.
Accountant sign-off is tracked separately.
Allocator merged in #59: a counter row updated in the invoicing transaction, as the last statement before commit. Tests prove no gap on rollback and no collision under 40 concurrent issuers (DB tests, run locally; #61 brings them into CI). Left: the accountant confirms a single series from 1, allocated at payment. Close by hand after that.
One more item for the accountant, from PR #65 (reconciliation, #62): the first subscription period now starts at the Mollie payment's
paidAt, not at the time the local record is written. So the withdrawal window runs from payment. A late repair leaves the customer fewer of the 14 days, and those days count as used in a proportional refund. Confirm this is right before closing this issue.invoices: gapless invoice number allocator (Bokföringslagen)till invoices: accountant confirms the numbering schemeInvoicing is manual at launch: invoices are made by hand in the bookkeeping software. The per-charge number billing allocates stays as an internal reference for the sales export and is not shown to customers. Moved to Backlog until invoices are generated in code.
Answered 2026-10-24.
paidAtstart. Not a bookkeeping problem, as long as refunds are booked and sales and VAT are adjusted by the right amount. Whether the shortened window and the pro-rata amount are right is a consumer-law question. It moves to counsel on #150.Both boxes resolved for the accounting side. Closing.