Skip to content

Commit 37785ed

Browse files
os-zhuangclaude
andauthored
docs: fix BU subtree attribution in two docstrings (#8098) (#8168)
* docs: fix BU subtree attribution in two docstrings (#8098) #7807 (PR #8097, 9b51981) narrowed the business_unit sharing-rule recipient to expand exactly one unit's members; unit_and_subordinates kept the subtree walk. These two docstrings never got the memo and still attributed the subtree expansion to business_unit. Correct the Drives: attribution in both. Fixes #8098 * chore: add changeset for BU subtree docstring fix (#8098) Measured: IBusinessUnitGraphService (packages/spec) and SysBusinessUnit (packages/platform-objects) docstrings both reach built dist/**/*.d.ts hover surfaces, so patch changesets are needed for both packages. --------- Co-authored-by: Claude <noreply@anthropic.com>
1 parent 2473cd2 commit 37785ed

3 files changed

Lines changed: 26 additions & 2 deletions

File tree

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
---
2+
"@objectstack/spec": patch
3+
"@objectstack/platform-objects": patch
4+
---
5+
6+
docs: fix `business_unit` sharing-rule docstrings that still attributed the BU subtree expansion to the narrow recipient (#8098)
7+
8+
#7807 (PR #8097, `9b519815`) narrowed the `business_unit` sharing-rule
9+
recipient to expand exactly one unit's members, moving the subtree walk onto
10+
`unit_and_subordinates`. Two docstrings never got the memo:
11+
`IBusinessUnitGraphService` in `packages/spec/src/contracts/sharing-service.ts`
12+
and the `sys_business_unit` object definition in
13+
`packages/platform-objects/src/identity/sys-business-unit.object.ts`. Both
14+
still said `recipient_type='business_unit'` sharing rules were driven by the
15+
subtree walk. Both now name `unit_and_subordinates` as the subtree consumer,
16+
with `business_unit` as the narrow (single-unit) one.
17+
18+
These are comment-only corrections — the `IBusinessUnitGraphService`
19+
docstring surfaces in `@objectstack/spec`'s built `dist/**/*.d.ts` hover, and
20+
the `sys_business_unit` docstring surfaces in
21+
`@objectstack/platform-objects`'s built `dist/**/*.d.ts` hover; no runtime or
22+
authoring behaviour changes.

packages/platform-objects/src/identity/sys-business-unit.object.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,8 @@ import { ObjectSchema, Field } from '@objectstack/spec/data';
1414
* structure works identically regardless of value.
1515
*
1616
* Drives:
17-
* - `recipient_type='business_unit'` sharing rules
17+
* - `recipient_type='unit_and_subordinates'` sharing rules (subtree walk);
18+
* `business_unit` expands only the one named unit's members
1819
* - `bu:` approver prefix in the approval engine
1920
* - Report rollups and manager chains in CRM/PM apps
2021
*

packages/spec/src/contracts/sharing-service.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -562,7 +562,8 @@ export interface ITeamGraphService {
562562
*
563563
* Walks `parent_business_unit_id` to expand a department into the union of
564564
* its members and all descendant members. Drives:
565-
* - `recipient_type='business_unit'` sharing rules
565+
* - `recipient_type='unit_and_subordinates'` sharing rules (this subtree
566+
* walk); `business_unit` expands only the one named unit's members
566567
* - `bu:` approver prefix in the approval engine
567568
* - report rollups, manager chains, and similar org-aware logic
568569
*/

0 commit comments

Comments
 (0)