@@ -7,7 +7,7 @@ import { allEmailTemplates } from './src/email-templates/index.js';
77import * as profiles from './src/profiles/index.js' ;
88import { CLM_POSITION , ClmPositions , ClmSharingRules } from './src/sharing/index.js' ;
99import { clmSeeds , demoSeedRequested } from './src/data/index.js' ;
10- import { CONTRACT_OWNERS , LEGAL_OWNERS } from './src/data/keys.js' ;
10+ import { CONTRACT_OWNERS , FINANCE_CONTROLLER , LEGAL_HEAD , LEGAL_OWNERS } from './src/data/keys.js' ;
1111import * as apps from './src/apps/index.js' ;
1212import * as datasets from './src/datasets/index.js' ;
1313import * as dashboards from './src/dashboards/index.js' ;
@@ -272,15 +272,19 @@ export default defineStack({
272272 // password (`os dev --admin-password`, default `admin123`) — the platform
273273 // refuses a `password` key, so no credential is committed here.
274274 //
275- // - The business requesters and the two counsel are named by the SAME
276- // constants the fixture deals rows by (`src/data/keys.ts`), so a name here
275+ // - Every account the fixture deals rows to BY NAME is named here by the
276+ // SAME constant the fixture uses (`src/data/keys.ts`), so a name here
277277 // cannot drift from the `owner_id` / `legal_owner` / `owner` /
278- // `decided_by` values that resolve against it. A requester holds no
279- // position: `clm_requester` is every member's default set (`isDefault`).
280- // - The other six positions are staffed once each, so every rung of the
278+ // `decided_by` / `reviewer` values that resolve against it: the business
279+ // requesters, the two counsel, the head of legal and the finance
280+ // controller. `reviewer` is `required`, so a drift there would not land
281+ // NULL — the loader would drop every review dealt to the account and the
282+ // seed would still report success. A requester holds no position:
283+ // `clm_requester` is every member's default set (`isDefault`).
284+ // - The other positions are staffed once each, so every rung of the
281285 // approval ladder and every audience group of §05 has someone to sign in
282- // as. The fixture names none of them ; they are reached through the
283- // position, not by name.
286+ // as. The fixture names none of the remaining four ; they are reached
287+ // through the position, not by name.
284288 //
285289 // ⚠️ A line manager cannot be declared: a `demoStaff` entry carries a
286290 // `position` and `permissionSets` and nothing else, and `sys_user.manager_id`
@@ -290,8 +294,8 @@ export default defineStack({
290294 ? [
291295 ...CONTRACT_OWNERS . map ( ( name , i ) => ( { name, email : `requester${ i + 1 } @example.com` } ) ) ,
292296 ...LEGAL_OWNERS . map ( ( name , i ) => ( { name, email : `counsel${ i + 1 } @example.com` , position : CLM_POSITION . legalCounsel } ) ) ,
293- { name : 'Head of Legal' , email : 'legal.head@example.com' , position : CLM_POSITION . legalHead } ,
294- { name : 'Finance Controller' , email : 'finance@example.com' , position : CLM_POSITION . financeController } ,
297+ { name : LEGAL_HEAD , email : 'legal.head@example.com' , position : CLM_POSITION . legalHead } ,
298+ { name : FINANCE_CONTROLLER , email : 'finance@example.com' , position : CLM_POSITION . financeController } ,
295299 { name : 'Executive' , email : 'executive@example.com' , position : CLM_POSITION . executive } ,
296300 { name : 'General Manager' , email : 'gm@example.com' , position : CLM_POSITION . generalManager } ,
297301 { name : 'Records Manager' , email : 'records@example.com' , position : CLM_POSITION . recordsManager } ,
0 commit comments