Skip to content

Commit 28973d3

Browse files
committed
Merge origin/main into claude/issue-36188-checklist-rail-retired
Resolves the records-forms.json conflict with d953558 in related-list-server-pagination steps[1]: the rail-retired wording of this branch stays, and the field.zod.ts quote is main's quote of the relatedList describe kept verbatim, with the 'primary' clause beside it. One revision bump (15) on top of main's 14; this branch's history row says so. Claude-Session: https://claude.ai/code/session_01FEkQ5kDGa1ViantgrfH797 Co-Authored-By: Claude <noreply@anthropic.com>
2 parents 3039436 + 1cd4762 commit 28973d3

252 files changed

Lines changed: 11657 additions & 1591 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
---
2+
'@objectstack/plugin-approvals': patch
3+
---
4+
5+
fix(approvals): the approval e-mail's link and the action-link page's inbox link open the Console under its mount
6+
7+
Clause-②: yes (widening)
8+
Metadata-protocol: none
9+
10+
The approval e-mail's "Open the approval" link was `BASE/system/approvals?request=ID`. `os serve` serves the Console at `/_console/` and nothing at `/system/*`, so the link answered `404 ENDPOINT_NOT_FOUND` and the request never opened. The "Open the Approvals Inbox" link on the action-link result page (`/api/v1/approvals/act`) had the same defect.
11+
12+
Both links now carry the Console's mount. The mount is read from the auth service's Console page composer (`getConsoleUrl`, which reads `AuthConfig.uiBasePath`, default `/_console`), the same composer the auth e-mails and the mention e-mail use.
13+
14+
- The e-mail link goes from `BASE/system/approvals?request=ID` to `BASE/_console/system/approvals?request=ID` on a default deployment. A deployment that sets `uiBasePath` to `/` keeps `BASE/system/approvals?request=ID`. Its base is still the approval links' own (`publicBaseUrl`, else `OS_AUTH_URL` / `OS_BASE_URL`). A kernel with no auth service has no mount to read, and the e-mail link stays as it was.
15+
- The inbox link goes from the origin-relative `/system/approvals` to `BASE/_console/system/approvals`. It is now absolute under the approval links' base when one resolves, and relative (`/_console/system/approvals`) when none does. With no mount to read (no auth service, or `uiBasePath` set to `/`) it is `BASE/system/approvals`.
16+
17+
The widening: the exported `ApprovalServiceOptions` gains the optional `getConsoleUrl` that carries the composer; the in-app `actionUrl` is unchanged.
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
---
2+
'@objectstack/metadata-protocol': patch
3+
---
4+
5+
fix(metadata-protocol): a seed resolves a lookup that another package adds through `objectExtensions` to the target's id
6+
7+
Clause-②: no
8+
Metadata-protocol: none
9+
10+
A package can add a lookup to another package's object through `objectExtensions`. A seed that set that lookup by the target's natural key (`externalId`) used to store the raw key in the foreign-key column on a boot that loads a compiled artifact (`os dev`, `os serve`, the cloud runtime). The record then linked to nothing, and the console showed "Restricted record". The same seed resolved correctly under the in-process test harness.
11+
12+
The cause was the seed loader's object read. It took the metadata service's copy of the object, which on an artifact boot is the object as its own package wrote it, without the fields an extension adds. Now the loader reads the object as the engine serves it, with its extensions included. It falls back to the metadata service's copy only when the engine has no schema for the object. So a lookup an extension adds is treated exactly like one the owner wrote, in every mode (`upsert`, `ignore`, `update`):
13+
14+
- it adds a dependency, so the target dataset loads first;
15+
- its natural key is resolved to the target's id;
16+
- it waits for the second pass when the target loads later in the same load;
17+
- an unknown key is refused with the same error.
18+
19+
The same read now drives the loader's other per-field decisions for such a field: the required-on-insert check, the tenant column, the replay compare and the undeclared-column warning.
20+
21+
Rows an earlier load stored with the raw key are not rewritten. Run the seed again (in `update` or `upsert` mode) to store the target's id in place of the key.

‎.changeset/35280-about-version.md‎

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
---
2+
'@object-ui/app-shell': patch
3+
'@object-ui/i18n': patch
4+
---
5+
6+
fix(console): the About dialog names the ObjectStack version first, then the console build
7+
8+
Clause-②: no
9+
Metadata-protocol: none
10+
11+
Help → About showed one row, the console build (a git short sha), and nowhere the ObjectStack version. The dialog now opens on an **ObjectStack version** row filled with exactly the `version` the server's discovery document answers (an operator's `OS_RUNTIME_VERSION` stamp where one is set), read through the shell's adapter from the discovery document the console already holds, so opening it sends no new request. **Console build** stays as the second row, so a deployment can still be traced to a commit. While the read is in flight the version row says it is loading; when discovery cannot be read or names no version, it says so in words ("Unknown version (the server did not report one)"), never an empty field.
12+
13+
New locale keys `help.aboutVersion` and `help.aboutVersionUnknown` in all eleven packs, and `help.aboutDescription` now names both rows. No props or exports change.
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
---
2+
'@object-ui/plugin-detail': patch
3+
---
4+
5+
fix(plugin-detail): a laid-out record page whose first details block draws no body still shows the approval band
6+
7+
Clause-②: no
8+
Metadata-protocol: none
9+
10+
The laid-out record page draws the record's approval band ("Locked for approval" / "In approval · editable", with its recall lever and tally) once per page. It used to give the band to the first `record:details` node of the details column and tell every later one not to draw it, so on a slotted page whose `details` slot puts first a `record:details` the reader may not see (its `requiredPermissions` withheld) or one that draws its own header (`showHeader: true`), a locked record showed no band at all. The details column now draws the band by the first details body that reaches its place, the rule a page drawn as written already follows: the next part draws it. Every other page reads as before, the band stays above a body table, and whether the band reads locked or editable (a `lockRecord: false` approval node) is unchanged.
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
---
2+
'@objectstack/spec': minor
3+
---
4+
5+
docs(spec): two upgrade-guide entries state the record page rules as merged
6+
7+
Clause-②: no
8+
Metadata-protocol: semantic
9+
10+
`field-group-related-list-side-card-refused` no longer lists a plain `master_detail` with no `inlineEdit` among the shapes a field group may not name: a group may place a `master_detail` FK that declares no `relatedList`, `inlineEdit` or not, and makes it a body table. Its remedy and reason name that rule. `page-slots-tabs-retired` says a `kind: 'full'` page is drawn as authored on the desktop full record page; a phone and the side preview draw the standard record page. No rule, refusal, schema or entry `id` changes, and `os migrate meta` lists the same entries for the same stacks.
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
---
2+
'@objectstack/skills': patch
3+
---
4+
5+
Clause-②: no
6+
Metadata-protocol: none
7+
8+
The `objectstack-ui` skill teaches how an object's list opens a record after `navigation.mode` was deprecated there:
9+
10+
- Record-page rule, step 5: on an object's list the record's name opens the full page and the hover icon beside it opens the drawer. `navigation.mode` is deprecated there: `drawer`, `page` and `new_window` change nothing, so the key is omitted; `none` still means rows open nothing (prefer `preventNavigation: true`); a page block's `navigation` still honours every value. The step no longer teaches `navigation: { mode: 'page' }` as the way to open the full page.
11+
- Step 6 no longer lists the Display menu's Open records choice or the drawer's full-width state among the reader's own choices: both were removed.
12+
- The navigation rule's Surface bullet states the same rule in place of "`page` only by declaration".
13+
- `SKILL.md` principle 5 says how a record opens from an object's list is not authored, in place of "one list-view key"; its Where-to-go row for the record page no longer reads "drawer or page".
14+
- Eval `record-page` case 2 ("open contracts as a full page, and beside the list") now expects nothing to be authored: it requires the answer to name the icon and forbids a `mode: 'page'` declaration. The case has a new hash, so `skill-evals --regrade` sets it apart from a round recorded before this change.
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
---
2+
'@object-ui/app-shell': patch
3+
---
4+
5+
fix(console): the bare data page opens a record the way an object's list does
6+
7+
Clause-②: no
8+
Metadata-protocol: none
9+
10+
On the bare data page (`/apps/APP/OBJECT/data`) a click on a record's name used to open the record in the side drawer. It now follows the list's one rule: the name opens the record's full page, and the 「Open in side panel」 icon that appears in the name cell while the row is hovered opens the side drawer over the list (`?recordId=`). The full page carries the data page as its origin, with its URL conditions, its name, the rows it shows and the count it matched: the page's top bar counts the record among them, ↑ ↓ step through them, and its ✕ returns to the data page with its conditions. A click on any other cell still selects it and opens nothing; a touch tap on a row opens the full page; a phone draws no icon; a list-only object's rows still open nothing. `?recordId=` links keep opening the drawer.
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
---
2+
'@objectstack/spec': minor
3+
'@objectstack/objectql': minor
4+
'@objectstack/lint': minor
5+
'@object-ui/app-shell': minor
6+
'@object-ui/plugin-detail': minor
7+
'@object-ui/i18n': minor
8+
---
9+
10+
feat(spec): an object extension says where the fields, groups and child lists it brings go (`place`), and a child list another package brings is no longer hidden by the parent's `relatedLists`
11+
12+
Clause-②: yes (widening)
13+
Metadata-protocol: semantic
14+
15+
An `objectExtensions` entry can now place what it brings on the object it extends:
16+
17+
```ts
18+
objectExtensions: [{
19+
extend: 'account',
20+
fields: { tax_id: { type: 'text', label: 'Tax ID' } },
21+
place: [
22+
{ field: 'tax_id', group: 'basic', after: 'industry' },
23+
{ group: { key: 'tax', label: 'Tax' }, after: 'basic' },
24+
{ list: 'contract', after: 'opportunity', label: 'Contracts', columns: ['name', 'amount'] },
25+
],
26+
}],
27+
```
28+
29+
- **No `place`: nothing moves.** Fields still arrive after the object's own, and an extension that writes no `place` serves exactly what it served before.
30+
- **One merge, every reader.** The registry fold applies the placements once, after every contributor's fields are merged, so the record page, the forms and Studio show one arrangement. Uninstalling or disabling the package takes its items off and leaves the object's own order as it was.
31+
- **Placement arranges what the parent declares.** A list placement applies when the extended object declares `relatedLists`; a group or field placement when it declares `fieldGroups`. On a parent that declares neither, its automatic arrangement stays and nothing is dropped: the list shows in the automatic tab order, and its entry's `label` / `columns` are not applied either (write `relatedListTitle` / `relatedListColumns` on your child object's lookup field to title it on every parent); the field shows among the fields, its `after` / `before` not applied. The boot log names each placement that did not apply, with the object and the package. It is the main channel: `os validate` names it too (`extension-placement-not-applied`, warning) only when the extended object is in the same stack.
32+
- **Anchors and order.** `after` or `before`, not both; neither means the end. An anchor may be an item another placement brings, whatever order the two are written or registered in. An anchor nobody has puts the item at the end of its group, of the groups, or of the tabs (before a trailing approvals / activity-stream run), and `os validate` warns (`extension-placement-anchor-missing`). A list placement's `columns` are fields of the child, checked by `os validate` as a `relatedLists` entry's are (`related-list-column-unknown`). Several packages at one anchor follow ascending `priority`, then package name, so every build gives the same order. When the object itself already names the list or lists the field, its own position wins.
33+
- **An extension places only its own items.** A field outside its own `fields`, a field the extended object declares (also one the extension redeclares to relabel it), a group key the extended object already declares, or a list (placed as a tab or by a group's `relatedList`) that is not a child object of its package pointing at the extended object is refused at parse or at `defineStack`, and skipped by the merge with a warning naming whose item it is, whichever door registered the extension. The extension keys `fieldGroups` and `relatedLists` are refused with a prescription naming `place`.
34+
- **Shipped behaviour change (flips #35897's hiding):** a child list another package brings is no longer hidden by the parent's declared `relatedLists`. Placed, it sits where its package puts it; unplaced, it shows at the end of the tabs. "Another package" means the child and the parent both belong to a package and the two differ; a child of the parent's own package, or one no package owns, is still hidden until an entry names it. This narrows the #35897 note "A child list another package adds is hidden too until the parent names it … letting a package place its own list is a later change": that change is this one.
35+
- **Studio** (object settings, Record page tabs) shows such a list read-only among the unlisted rows with a "from <package>" badge, and the preview draws it where the record page does.
36+
37+
What to check in an app: on an object that declares `relatedLists`, every installed package's child lists of it now show, at the end of the tabs unless placed; name one in the parent's `relatedLists` to put it elsewhere, or set `relatedList: false` on that package's FK to hide it. Nothing in HotCRM changes meaning today: no module writes `place`, and no object declares `relatedLists`. Most HotCRM objects already declare `fieldGroups`, so a field or group placement there applies as soon as a module writes one; a list placement waits until the parent declares its `relatedLists` (follow-up #35902). ADR-0087 semantic entry `object-extension-place-and-cross-package-lists`; ADR-0146 D10 and ADR-0085 notes.
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
---
2+
'@object-ui/app-shell': patch
3+
'@object-ui/console': patch
4+
'@object-ui/i18n': patch
5+
---
6+
7+
fix(console): Studio's kanban card "Click to open" offers only Default and "Don't open"
8+
9+
Clause-②: no
10+
Metadata-protocol: none
11+
12+
On an object's list the record name opens the full page and the hover icon opens the side panel, so `navigation.mode` `drawer`, `page` and `new_window` parse there and change nothing; only `none` still counts. The kanban card section of Studio's list-view inspector offered all four. It now offers Default (no key) and "Don't open" (`none`). A view that already stores `drawer`, `page` or `new_window` shows that value flagged "(deprecated)" in the select, and picking Default removes the key. Opening such a view writes nothing. The spec is unchanged, and page blocks that carry `navigation` keep every mode.
13+
14+
The studio catalogue drops the three labels nothing reads any more: `engine.studio.inspector.listView.kanbanCard.mode.drawer`, `.mode.page` and `.mode.newWindow`.
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
---
2+
'@object-ui/plugin-detail': patch
3+
---
4+
5+
fix(plugin-detail): the record drawer's per-field save asks for the fields a change makes required
6+
7+
Clause-②: no
8+
Metadata-protocol: none
9+
10+
In the record overlay (`RecordDetailPanel`, and `RecordDetailDrawer` around it), a change that made another field required (`requiredWhen`) while that field was empty went straight to the host's `onFieldSave` and came back refused by the server. The overlay now asks first, in the same fill-in dialog the record page, the list cell and the kanban open: Save writes the change and the typed values in one update guarded with `If-Match` at the version the edit began on, Cancel writes nothing and keeps the edit. A change that makes nothing required still saves at once through `onFieldSave`.
11+
12+
The ask needs one write to put the values in, so `InlineEditSaveBar` asks in its callback mode only when it is also given `dataSource`, `objectName`, `recordId` and `data`; `RecordDetailPanel` now passes them, with a record context naming the object's fields. That one write goes through the data source, not through `onFieldSave`; a host that patches its own list in `onFieldSave` sees it through the data source's mutation event. Without a data source the overlay saves field by field as before.

0 commit comments

Comments
 (0)