More pages
Record a journal entry. The balance is checked as you type, again in the domain layer, and a third time by Postgres at COMMIT.
What happened, and what it is denominated in.
What this entry records, e.g. “Invoice 1042 settled”.
Debits and credits must total the same amount. Nothing else is a valid entry.
An entry is only accepted when its postings sum to zero.