pieceReference numbering
AI-generated content
This document was generated by an AI assistant from the 'Event Matrix Accounting' Google Sheet. Verify accuracy before relying on the details.
The pieceReference is FEC field #9 — the document reference of an accounting entry. ADB uses three chrono families plus an "external" carrier for user-provided references.
At a glance
| EVENT_KEY | Type | Name | Value range | Comment |
|---|---|---|---|---|
CALL_FOR_RENT (and CALL_FOR_RENTAL_CHARGES, CALL_FOR_DEPOSIT) | chrono | call_for | CF00000001 to CF99999999 | Shared by the three call_for events when possible |
CFR_CHARGES_HOUSEHOLD_WASTE | chrono | call_for | same CF… series | Shares the call_for chrono |
| (any external doc) | external | — | — | User-provided reference (e.g. supplier invoice number) |
| (invoice events) | chrono | invoice | INV00000001 to INV99999999 | Outgoing/incoming invoice family |
| (internal events) | chrono | internal | ITN00000001 to ITN99999999 | Internal entries with no externally meaningful ref |
Per-event chronos
The sheet also documents shorter prefixes per event (e.g. RR_<chrono> for recurring rent, OPI_<chrono> for outgoing owner payments). Those are the strings used in the user-facing description column, not the FEC Doc ref. Each event's "At a glance" table lists its specific chrono.
Where chronos live in code
- The
accounting_sequenceMongoDB collection (inadb-accounting) holds the per-prefix counter. - Allocation goes through
SerialNumberService/ObjectIdController(see the service fact sheet). - The user can override the chrono for incoming-payment events (the sheet shows
if not given by endUser, automatic attribution).
Open questions
- The source has four
#REF!cells in this tab (rows for\#REF\!event keys). TheCF…,INV…andITN…chronos are still meaningful, but the events that those#REF!cells were meant to point at are unknown. If you find a clear mapping in code, file a PR to update this page and the original sheet. - The source mentions an
externalchrono type with no name/value pair. That's the path used when the user enters a supplier invoice number directly — it bypasses the chrono service. Worth documenting whether the FEC export keeps that user value verbatim or applies normalisation.