Skip to content

DOM-ACC-TRX-001Invoice

Markdown

DOM-ACC-TRX-001

Invoice

Markdown
  • DocumentDraft
  • ImplementationObserved

Planning

Specified by
CON-ACC-TRX-001

Design

Owned by
SVC-ACC-TRX-transactions

KindDomain objectProduct areaAccountingModuleTransactionsRevision1

Read atservices-accounting f47cb263react-console baf6dae3

Relationships

ToCardinalityOwnershipCrosses a serviceOn archive or delete
DOM-ACC-TRX-003many-to-many through allocationsAllocation records belong to the payment and contribute to the invoice line's paid amount.no
DOM-ACC-TRX-004many-to-many through credit applicationsApplication records belong to the credit and also contribute to the line's paid amount.no
DOM-ACC-TRX-005many-to-oneThe account reads the invoice's financial effects without owning the bill.no
DOM-ACC-TRX-006one-to-oneThe invoice and its correction documents share the transaction-record shape for identity, batching and history.no

Invariants

InvariantProtectsEnforced atProvenance
INV-DOM-ACC-TRX-001-01
Replacing a draft requires its current version and rejects stale replacements without effects.
api, servicetest
INV-DOM-ACC-TRX-001-02
Draft replacement preserves the existing business unit and currency.
servicetest
services-accounting:modules/transactions/tests/integration/services/invoices/update-draft.integration.spec.js#it refuses a change of business unit: a draft keeps its unit (business_unit_mismatch)
INV-DOM-ACC-TRX-001-03
Each extension rounds half away from zero to minor units before the invoice sums the resulting line amounts.
api, service, databasetest
services-accounting:modules/transactions/tests/integration/services/invoices/rounding.integration.spec.js#it totals the rounded lines (3422), not a rounding of the unrounded sum (3421)
INV-DOM-ACC-TRX-001-04
A real invoice needs lines, an open period and an eligible batch, while a pro forma needs lines without a batch; failures before numbering leave the sequence unchanged.
service, databasetest
services-accounting:modules/transactions/tests/integration/services/invoices/issue.integration.spec.js#it refuses the issue when the unit has no assignment rules (batch_required), the draft unchanged
INV-DOM-ACC-TRX-001-05
The workspace invoice sequence begins at one million and permits skipped numbers without duplicates.
service, databasetest
INV-DOM-ACC-TRX-001-06
Once recognised, ordinary database writes preserve commercial content while allowing designated lifecycle, description and maintained-amount changes.
databasetest
INV-DOM-ACC-TRX-001-07
Maintained amounts determine invoice status, including paid for a newly issued zero-value invoice.
databasetest
INV-DOM-ACC-TRX-001-08
An unconverted pro forma has no batch, receivable facts or allocations and supports complete deletion.
service, databasetest
services-accounting:modules/transactions/tests/integration/services/invoices/issue.integration.spec.js#it gives it no batch, no accounting date and no recognition (FC-06)
INV-DOM-ACC-TRX-001-09
Line debt is total plus debits minus payments, credits and write-offs, bounded from zero to total plus debits, with header amounts summing the lines.
databasedocumented
INV-DOM-ACC-TRX-001-10
Amendment increments revision and preserves any line carrying an application or adjustment.
servicetest
services-accounting:modules/transactions/tests/integration/services/document-edits/reassign-and-edit.integration.spec.js#it removes a line with nothing applied at the next revision, and refuses removing or repricing the paid line
INV-DOM-ACC-TRX-001-11
A posting, posted or downloaded batch prevents amendment, document or accounting date correction and voiding, while terms, due dates and descriptions use separate edit guards.
serviceobserved
INV-DOM-ACC-TRX-001-12
Void requires a reason and an invoice without applications or adjustments, retaining amounts while cancelling a recognised receivable on the void date.
service, databasetest
INV-DOM-ACC-TRX-001-13
A credit memo is limited to outstanding debt plus releasable paid value and leaves no effects when it exceeds that limit.
service, databasetest
INV-DOM-ACC-TRX-001-14
Voiding a memo appends dated opposite lines once and retains the original document.
service, databasetest
INV-DOM-ACC-TRX-001-15
Restoring a write-off creates a separately numbered opposite document and neither member of that pair supports another reversal.
service, databasetest
services-accounting:modules/transactions/tests/integration/services/write-offs/write-offs.integration.spec.js#it answers the reversal: a second write-off, numbered next, its lines negating the first’s
INV-DOM-ACC-TRX-001-16
Issue retains tax lines by rate without posting accounts and later reductions use that recorded determination.
service, databasetest
services-accounting:modules/transactions/tests/integration/services/invoices/issue-tax.integration.spec.js#it writes one tax line per rate on the dues line, naming the zone and the rate and no account
INV-DOM-ACC-TRX-001-17
Creation selects the card-fee policy and receivable recognition protects it from ordinary changes; pro forma issue alone does not activate that freeze.
api, service, databaseobserved
INV-DOM-ACC-TRX-001-18
Billing-reversal preparation commits its financial steps together or rolls them all back.
servicetest
services-accounting:modules/transactions/tests/integration/services/reversals/reversals.integration.spec.js#it refuses a reversal dated in no open period (period_not_open), writing nothing
INV-DOM-ACC-TRX-001-19
Invoice and correction records contain no custom-field storage and the module registration supplies no custom-field capability declaration.
api, servicedocumented
services-accounting:docs/milestones/plans/ACCT-M2-plan.md#7a. Entity capabilities (R2-ARCH-001)

The Markdown files under specs/ in rhythmsoftware/rhythm-v2-docs are the canonical source of truth. This reader is a generated, read-only projection of them.