Skip to content

CAP-ACC-BAT-019Plan deferred revenue and adjust its remaining releases

Markdown

CAP-ACC-BAT-019

Plan deferred revenue and adjust its remaining releases

Markdown
  • DocumentDraft
  • Product intentProposed
  • ImplementationObserved

KindCapabilityProduct areaAccountingModuleBatch ManagementRevision1

Read atservices-accounting f47cb263react-console baf6dae3

The Formal Contract

The narrative above explains; the sections below are authoritative — the rules, scenarios and tests this document binds.

Outcomes
Deferred and correction plans expose dated amounts and current revenue balances.
Surfaces
consoleapijob
Constraints
Fiscal close performs recognition through the system-batch workflow.
Intent sources
services-accounting:docs/milestones/ACCT-M1-books-and-invoices.md#D12services-accounting:docs/milestones/ACCT-M3-batch-posting-and-ledger.md#Status history (2026-10-21 09:36, Andrew ruled the credit memo on a partly recognised line splits by schedule)

Controls

27 controls apply, from the corpus control catalogue.

TC-IAM-001 TC-IAM-002 TC-IAM-004 TC-IAM-005 TC-IAM-006 TC-AZ-001 TC-AZ-002 TC-AZ-003 TC-AZ-004 TC-AZ-006 TC-TEN-001 TC-TEN-002 TC-TEN-003 TC-CRY-001 TC-LOG-002 TC-LOG-003 TC-LOG-004 TC-LOG-005 TC-AVL-001 TC-AVL-004 TC-MON-001 TC-MON-002 TC-MON-004 TC-PI-001 TC-PI-002 TC-PI-004 TC-PI-005

Permissions

KeyChecked atScope
accounting.subledger-entries.readapitenant
accounting.revenue-schedule-entries.queryservicetenant

Business Rules

14 rules, 14 to be proved before approval. A rule's product intent is derived from its origin: 0 confirmed by a product decision, the rest inheriting this capability's proposed.

IdRuleKindEnforced atProvenance
01must prove
Proposed
An originating deferred line credits deferred revenue and receives dated releases over its recognition period, assigning the final entry any rounding remainder.
calculationservicetest
services-accounting:modules/batches/tests/integration/services/posting/rebuilt-deferral.integration.spec.js#writes H a schedule of three monthly entries on the firsts of October, November and December, summing to 300.00
02must prove
Proposed
Fixed and matching relative-date strategies choose their own dates; period-based calculation prefers the line service period, then product-type period logic, with a year from the batch as fallback.
calculationserviceobserved
03must prove
Proposed
A period-based service schedule divides the amount across every calendar month touched, including partial months, without changing its entries for the memo truncation setting.
calculationservicetest
services-accounting:modules/batches/tests/unit/rules/service-period-schedule.spec.js#gives a service period starting mid-month the calendar months it touches: thirteen entries from March 2026 to March 2027
04must prove
Proposed
Period calculation refuses a recognition period exceeding sixty months.
validationservicetest
05must prove
Proposed
Deferred splits release their shares through schedule entries, while non-deferred splits credit their destinations at posting.
calculationservicetest
services-accounting:modules/batches/tests/unit/rules/deferred-revenue-splits.spec.js#releases each period’s 10% to the percentage split’s account, by the split
06must prove
Proposed
Any generated recognition date before the posting batch date is moved forward to the batch date.
calculationserviceobserved
07must prove
Proposed
An effective-date memo applies the workspace’s posting-time truncation choice, weighting eligible entries by period or by days.
calculationservicetest
services-accounting:modules/batches/tests/integration/services/posting/rebuilt-service-periods.integration.spec.js#writes the memo's schedule on A's entries after the effective date alone: the 20 September primary and its split, −54.00 and −6.00
08must prove
Proposed
Corrections invert the applicable unrecognised share on its original schedule dates and leave already recognised entries unchanged.
calculationservicetest
services-accounting:modules/batches/tests/unit/rules/schedule-truncation.spec.js#inverts the nine unrecognised months at half each on their own dates and nothing for the recognised three
09must prove
Proposed
An added deferred debit-memo line gets its own schedule unless the invoice schedule already covers it, and a non-deferred line receives none.
calculationservicetest
services-accounting:modules/batches/tests/unit/rules/memo-split-by-schedule.spec.js#is written a schedule of its own under the memo’s id, summing to 30.00, which the invoice’s schedule does not cover
10must prove
Proposed
Cash-basis invoices create no schedules, but allocated payments can originate schedules for deferred products.
policyserviceobserved
11must prove
Proposed
Invoice schedule generation uses the line’s tax-inclusive total although the deferred credit excludes tax, allowing over-recognition on a taxed deferred line.
calculationserviceobserved
12must prove
Proposed
Entry-read permission allows inspection of an invoice line’s current schedules, entries and currency-bearing deferred and recognised totals.
calculationapi, servicetest
services-accounting:modules/batches/tests/integration/services/posting/rebuilt-service-periods.integration.spec.js#answers A’s line with 240.00 still deferred across the invoice’s and the memo’s schedules, on the view and on the read
13must prove
Proposed
The schedule-entry dataset reports signed currency amounts, account and customer references and current-posting flags, with its own query permission declared.
calculationdatabasetest
services-accounting:modules/batches/tests/integration/db/revenue-schedule-entries-view.integration.spec.js#sums the waterfall the recipe asks for: what is still deferred, by month and revenue account, the memo netted and V left out
14must prove
Proposed
If effective-date truncation finds no eligible weights, it falls back to inverting the original schedule’s unrecognised entries.
calculationserviceobserved

Scenarios

IdGivenWhenThenProvenance
01An annual membership is invoiced for one hundred twenty dollars.Accounting completes for the containing batch.The deferred line receives twelve monthly releases of ten dollars.test
02Three monthly releases have already been recognised.A half credit memo posts against the line.Its adjustment schedule reverses half of each remaining month without adjusting the recognised months.test
03A service period begins in mid-March and ends the following March.Its schedule is calculated under each memo truncation setting.Both schedules span thirteen calendar months, with truncation affecting corrections rather than those originating entries.test

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.