Originator/transaction-first schema — LO assignment, WORM freeze, deal-scoped docs

Featurekamo-shared-library
Shipped
July 9, 2026 at 3:01 AM UTC
Author
Kamo
Commit
286e611

Backbone for the system-managed-originator + transaction-first refactor (spec 2026-07-08): - LoanTransaction: transactionNumber (org-unique) + assignedLoanOfficerMemberId (+ audit) — the transaction-level LO assignment that drives the originator projection, inherited by all child loans. - LoanOriginator: frozenAt/frozenState + @PreUpdate WORM guard — the originator is a LIVE projection of the assigned member/org until the initial Loan Estimate issues (Reg Z/TRID), then an immutable as-originated snapshot. LoanOriginatorDTO exposes frozenAt/frozenState/source (LIVE|SNAPSHOT). - MemberDocument: loanTransactionId deal-binding — a time-sensitive vault doc (credit report, bank statement) is transaction-scoped; NULL = account-timeless. Time-validity stays governed by the existing FreshnessPolicy (NOT duplicated). Projection/freeze/assignment logic lives in SecurityService (which depends on both donotmodify and mlos), not here — the locked core stays mlos-decoupled.

All changes

Like what you see shipping?

Every one of these updates lands in your workspace automatically. Start free and watch it grow week after week.

Start Free ForeverView Pricing