Skip to content

Commit 6f47af8

Browse files
committed
Merge remote-tracking branch 'origin/main' into claude/project-thread-jue0uh
2 parents f4425e0 + 3c06fc5 commit 6f47af8

183 files changed

Lines changed: 7182 additions & 1301 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: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
---
2+
'@objectstack/scenarios': patch
3+
---
4+
5+
fix(scenarios): an irreversible operation the agent applied with its own `confirm: true` fails `pending_confirmation` again: the temporary relaxed grade is off, and its names are deprecated
6+
7+
Clause-②: no
8+
Metadata-protocol: none
9+
10+
The scorer carried a temporary rule: a `pending_confirmation` operation was also met when the agent applied it through a business action declaring `ai.requiresConfirmation: true`, sending `confirm: true` itself, on an ask that named the target row. It existed because the platform could not tell a person's confirmation from the caller's own. The platform now refuses the caller's own `confirm`, and hands a gated call without it to the person, so the rule is off: `AGENT_CONFIRMATION_MEETS_PENDING` is `false`, and every `pending_confirmation` operation is graded strictly again (the agent asks first and writes nothing; the person's confirmation turn grades the write after it, as before). On the runner's door the hand-off of a call without `confirm` (`ACTION_CONFIRMATION_REQUIRED` on a host with no pending-confirmation service) reads as the agent stopping with nothing applied, which meets `pending_confirmation`; a call that still carries `confirm` is refused, and an agent that stops on that refusal fails.
11+
12+
No export is removed. The rule-only names stay exported and are marked `@deprecated`, to be deleted in the next major: `AGENT_CONFIRMATION_MEETS_PENDING`, `confirmedByAgent`, `AgentConfirmedObservation`, `AgentConfirmationRule`, `OperationObservation.agentConfirmed`, `GradeOperationOptions.agentConfirmation`, `GradeOperationOptions.acceptAgentConfirmation`, `actionGatesOf` and `ConfirmationTally.confirmedByAgent`. Until then a direct `gradeOperation` call that still wants the relaxed reading passes `acceptAgentConfirmation: true`; `gradeCardOperation`, and so the runner, takes no such option. `askNamesTarget`, `AskNaming`, `askedFirst` and `OperationGrade.confirmation` are unchanged: the confirmation turn reads them.
13+
14+
The scorecard's card line no longer says the agent's own confirmation is "accepted until real human confirmation lands"; a record that still counts one says it was met only under the retired relaxed grade.
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
---
2+
'@object-ui/components': patch
3+
'@object-ui/app-shell': patch
4+
'@objectstack/plugin-approvals': patch
5+
---
6+
7+
fix(console): the approval request page is named by the record it asks a decision on, and its reject button no longer outweighs approve
8+
9+
Clause-②: yes (widening)
10+
Metadata-protocol: none
11+
12+
- **The page title.** An approval request's page used to be titled by its flow's label ("Purchase approval"), which the strip under it repeated as its Flow chip, while the business record the approver decides on had no title at all. The page header now reads the record's title the approvals get serves (`record_title`), linked to that record once the page itself has read it: a plain click opens it in the app, as the "As submitted" card's "Open record" link does, and a modifier or middle click opens it in a new tab. Where the page's read of the record is refused or finds nothing, or the platform says the record was deleted, the title is plain text with no link, as the record card on the same page draws it. The title makes no read of its own: the reads the page already makes report what they found. Where the get serves no title for the record, or serves only its id, the header keeps the flow's label, so the page never names the record by a raw id. The flow stays named once, by the strip's Flow chip; no subtitle is added, because it would repeat that chip. The request object's declared title (`nameField: 'process_label'`) is unchanged, so lists, search, recent items and the breadcrumb still name a request by its flow.
13+
- **`RecordHeaderState.title`** (`@object-ui/components`, new optional member, with its type `RecordHeaderTitle`). A host that knows a better name for the record than the object's declared title hands `{ text, node? }`; `page:header` draws `node` (or `text`) inside its H1, in the host's top bar and in its own row alike. Absent, or with an empty `text`, the header's own title stands exactly as before.
14+
- **The decision band.** In the approver's band (the request page, and the business record page's approval band), Approve stays the filled primary button and Reject is drawn as an outline button in the destructive text colour, the face the record header already gives a secondary danger lever. A host that does not ask for the band's fold keeps the declared filled danger face.
15+
- **One time format.** The approval timeline's action times use the compact datetime face the page's highlight chips and every `datetime` cell draw (`2026/11/10 下午8:25` under zh-CN), in the host's display time zone, instead of the browser's long form with seconds.
16+
- `@objectstack/plugin-approvals`: comments only, saying where the request page now names its record.
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
---
2+
'@objectstack/objectql': patch
3+
'@objectstack/service-analytics': patch
4+
---
5+
6+
feat(units): a raw total over a `record`-mode quantity is refused unless it groups by the quantity's unit field
7+
8+
Clause-②: yes (widening)
9+
Metadata-protocol: none
10+
11+
ADR-0158 U7 R1, mirroring ADR-0144 D6 and its record-currency doors. A `number` field declaring `unitConfig: { unitMode: 'record', unitField }` holds a bare quantity whose unit is each row's code in `unitField`. Before this change, `sum` over a row of 10 KGM and a row of 10 LBR answered `20`, and a `summary` roll-up over such child rows stored `20`.
12+
13+
- **The engine aggregate** (`@objectstack/objectql`, `ObjectQL.aggregate`): `sum`, `avg`, `min` or `max` over such a quantity is refused `INVALID_FIELD` / 400 before any driver is asked, unless the query's `groupBy` includes the quantity's `unitField`. The message names the quantity, its unit field and the grouping to add.
14+
- **A `summary` roll-up** (`@objectstack/objectql`, object registration): a `summary` that rolls up `sum`, `avg`, `min` or `max` of such a child quantity is refused `INVALID_METADATA` / 422, whichever object registers second. In R1 every such roll-up is refused: a child quantity cannot follow its parent's unit yet. Roll up with `function: 'count'`, or total the quantity with an aggregate grouped by its unit field.
15+
- **Analytics** (`@objectstack/service-analytics`): a dataset or cube measure of type `sum`, `avg`, `min` or `max` over such a quantity is refused `INVALID_FIELD` / 400 unless the query has a dimension over the unit field, on every cube path (declared, inferred, augmented), every `totals` grouping and the draft preview.
16+
- **The widening.** `AnalyticsServiceConfig.sourceFieldMeta` may answer one more optional key, `unitField`: a `number` field's `unitConfig.unitField`, under `unitMode: 'record'` only. `AnalyticsServicePlugin` relays it for a `number` under `unitMode: 'record'` and for nothing else. A host that does not answer it gets no record-unit judgment from the cube door; the engine aggregate door still refuses the same query on the ObjectQL strategy.
17+
18+
Not judged: `count` and `count_distinct`, a `fixed`-mode quantity, and a `number` field with no `unitConfig`. No new error code.
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
---
2+
'@objectstack/objectql': patch
3+
---
4+
5+
fix(objectql): a system-context delete of a record with no organization now keeps it in the recycle bin instead of failing on `sys_recycle_bin.organization_id`
6+
7+
Clause-②: no
8+
Metadata-protocol: none
9+
10+
A delete made under `{ isSystem: true }` (the context flows, hooks and admin tooling use) of a record that names no organization, such as a record of a `tenancy: { enabled: false }` object, wrote its recycle-bin entry with no organization. On a SQL store, where the bin's tenant column is NOT NULL, the delete failed with `NOT NULL constraint failed: sys_recycle_bin.organization_id` and the record stayed. On the memory store the delete succeeded but left an entry no organization owned.
11+
12+
The entry now takes the organization any system-context insert takes (ADR-0131 D9): the record's own, else the context's, else the organization the engine derives. Under the `single` posture that is the Default Organization, so the record lands in the bin and can be restored. Under a walled posture (`isolated`, `group`), where no owner can be derived, the delete is refused with `ERR_SYSTEM_WRITE_ORGANIZATION_REQUIRED` before the record is removed, as a system insert is. A caller that deletes there passes the organization on the context (`{ isSystem: true, tenantId: '...' }`).

‎.changeset/35684-35687-list-cells-select-first.md‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@ Skills-docs: none — `skills/objectstack-ui/rules/list-views.md` already teache
1818
**The select-first cell model** (`data-table`, behind the new `GridCellSelectionProvider` in `@object-ui/components`; `ObjectGrid` mounts it when its host passes the new `cellSelection` prop, and `ListView` passes it for every `object-grid` view it draws, on the hosts listed below):
1919

2020
- A click selects a cell (a ring around it) and neither edits it nor opens the record. A link the cell draws (the name, a lookup, a phone or an email) keeps its own click. A touch tap opens the record and never edits in place.
21-
- Double-click, Enter or F2 edits, keeping the value with the caret at its end; typing a character replaces the value with it (a picker or a date opens instead); Backspace or Delete opens an empty editor and saves nothing.
22-
- While editing, Enter commits and moves down, Tab and Shift+Tab commit and move right and left, Escape cancels and keeps the cell selected; in a multi-line editor Enter is a new line and Ctrl/Cmd+Enter commits. Commits are the grid's staged edits, saved by the row's Save and Save All as before.
21+
- Double-click, Enter or F2 edits, keeping the value with the caret at its end; typing a character replaces the value with it (a picker or a date opens instead); Backspace or Delete clears the cell and saves at once, and a required field keeps its value and says it is required (objectstack#36023).
22+
- While editing, Enter commits and stays on the cell (objectstack#36023), Tab and Shift+Tab commit and move right and left, Escape cancels and keeps the cell selected; in a multi-line editor Enter is a new line and Ctrl/Cmd+Enter commits. Commits are the grid's staged edits, saved by the row's Save and Save All as before.
2323
- On the selected cell the arrows and Tab move the selection, Space opens the record (a checkbox cell flips and commits instead, as a second click on it does), Ctrl/Cmd+C copies, Ctrl/Cmd+V converts the text to the field's type and commits it, and Escape clears the selection.
2424
- An input method's composition is kept whole: keys pressed while composing, and the 229 Enter Safari raises after it, never commit, cancel or move, and a composition started on a selected cell opens the editor with the composed text. This guard applies to every `data-table` editor.
2525
- A cell that opens no editor says why on the cell: the field is read-only, calculated or not editable in a list, the reader may not edit the field, these records or this record, the view turned editing off, or the record is locked by an approval. The approval lock is read from the approvals service's per-record lock when a cell of the row is selected, through the record page's rule (`resolveApprovalLock`); until it answers, the row's `approval_status` stands in only where the view fetches that column, which a view that authors its columns does only when a column, a row predicate or a grouping names it.
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
---
2+
'@objectstack/metadata-protocol': patch
3+
---
4+
5+
fix(metadata-protocol): cloning a record whose file fields are set answers 201
6+
7+
Clause-②: no
8+
Metadata-protocol: none
9+
10+
`POST /data/:object/:id/clone` with no `overrides` answered `400 VALIDATION_FAILED` ("… has an invalid file value: … expected string, received object") for any record holding a file in a `file`, `image`, `avatar`, `video` or `audio` field, single or `multiple`. The clone read the source the way the caller reads it, with each file expanded to its `{ id, name, size, mimeType, url }` object, and inserted that object back; the insert takes a file field's stored value, the `sys_file` id, only.
11+
12+
The clone now reads the source's file fields in their stored form (the bare id, or the list of ids for a `multiple` field). Each one then follows the same rule a clone naming the id in `overrides` already followed: the file's bytes are copied into a new `sys_file` that the clone's field owns, and the source record keeps its own file. A file field named in `overrides` still takes the override. Because a clone with no body now reaches that same copy step, it also gets that path's answer when a source file's `sys_file` row exists but its stored bytes are missing: `500 FileReferenceCopyError`, the error the `overrides` path already returned in that case.
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
---
2+
'@object-ui/app-shell': patch
3+
'@object-ui/i18n': patch
4+
'@object-ui/plugin-list': patch
5+
---
6+
7+
feat(console): a change on a list is a draft, with Discard and Save
8+
9+
Clause-②: yes (widening) — new `console.objectView.draft.*` keys in every `@object-ui/i18n` locale pack (`discard`, `discardTitle`, `save`, `heading`, `partSeparator`, `saveToView`, `saveAsMyView`, `copyName`, `saved`); nothing removed or renamed
10+
Metadata-protocol: none
11+
12+
On a Console object list, a header sort, a filter change, grouping, the search, Hide Fields, an added field and a column drag apply at once and are now a draft: they are kept nowhere. They used to be saved at once into the reader's own list preference (`sys_user_preference`, key `ui.list.<object>`) and followed them to every device.
13+
14+
- While the list holds a draft, **Discard** and **Save** sit at the end of the condition row, where the 「Personalized · Reset to view」 marker was. On a narrow list or a phone they fold into one **Save** whose menu also holds Discard.
15+
- **Save** names what is unsaved and offers **Save to this view** (on a view of the reader's own) and **Save as my view**, which asks a name first (the view's name with "copy"), saves the draft as a new view of the reader's own and opens it. Either says "Saved", and the buttons go while the conditions stay.
16+
- **Discard** puts the list back as its view declares it and removes the list's `uf_*` parameters from the address bar.
17+
- Where the reader may not save (no personal view can be created or updated), both faces are Discard alone.
18+
- The draft survives opening a record (as a page or in the side panel) and coming back. Opening another view or object, or reloading the list's page, drops it. A reload of another page does not drop the state an in-app link to a list carries.
19+
- Column widths, the row height and the views' order are not a draft. They are still remembered for the reader in the same `ui.list.<object>` row.
20+
21+
Upgrade note: a sort, filter, search, column order, hidden column or added column that an earlier Console stored in a reader's `ui.list.<object>` row no longer applies; the list opens as its view declares it. Nothing stored is deleted by this change; a later column-width change rewrites that row's column state with the widths alone. A reader who wants such a list kept saves it as a view of their own.
22+
23+
Saving into a shared view, and saving the Display panel's layout and row colour, are not offered yet. `@object-ui/plugin-list` changes only its README, which now describes added fields as part of the draft. No metadata key, value or default changes.
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
---
2+
'@objectstack/driver-sql': patch
3+
---
4+
5+
fix(driver-sql): on Oracle, a read scoped by a parent with a RAW(16) uuid key answers its rows on a driver that has not read the parent yet
6+
7+
Clause-②: no
8+
Metadata-protocol: none
9+
10+
A child read whose composed `ReadableIds` scope names a federated parent with a `RAW(16)` uuid key, such as the read plugin-security derives for a `controlled_by_parent` object, answered no row on Oracle, and its negation answered every row, with no error. It recovered only once something had read the parent on that driver. The driver reads a federated table's `RAW(16)` columns from the Oracle catalog before it binds a comparand, and it read them for the door's own object only, so the parent's ids bound as text and Oracle compared them with the column's upper-case hex.
11+
12+
Each door that compiles a filter (`find`, `findOne`, `count`, `distinct`, `aggregate`, its measure filters and its joined parents, `updateMany`, `deleteMany`, `findWithWindowFunctions` and `analyzeQuery`) now also reads the `RAW(16)` columns of every object a composed `ReadableIds` scope in that filter names, at any depth. The parent's ids bind through `HEXTORAW`, for a list of ids and for the share-grant subquery alike. Nothing changes for any other dialect.
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
---
2+
'@object-ui/components': patch
3+
'@object-ui/fields': patch
4+
'@object-ui/plugin-grid': patch
5+
---
6+
7+
fix(grid): in a list cell a single click only selects, and the email and phone cells draw no copy button
8+
9+
Clause-②: no
10+
Metadata-protocol: none
11+
12+
On a grid with the select-first cell model (the console's list page), a plain click on a link a cell draws used to follow it: an email opened the mail program, a phone number the dialler, a URL a new tab, a lookup or user chip that record's page, and an image thumbnail its lightbox. The cell was not selected, so a reader who meant to select or edit the cell left the list instead. The email and phone cells also drew a copy button beside the value, easy to hit while selecting.
13+
14+
A plain click on any of these now selects the cell and opens nothing. To open one: Ctrl/Cmd-click it (as before), press the open button the selected cell shows on hover (only on the selected cell, never on the row hover), or press Ctrl/Cmd+Enter on the selected cell. A cell of several chips opens the first one that way. A double-click on the link edits the cell, as on any other cell. The name link is the one exception and opens the record on a single click, as before. The copy buttons are not drawn inside such a grid; Ctrl/Cmd+C copies the selected cell.
15+
16+
Outside the select-first model nothing changes: the record page, related lists, phone cards, kanban cards and every grid whose host does not turn on `cellSelection` keep their links and copy buttons.
17+
18+
For renderer authors: a link (`a[href]`) inside a select-first cell is now treated as part of the cell's value. Mark the one link a single click must still follow with `data-opens-on-click`, a non-link control that opens what the value points at with `data-cell-opener`, and a copy control the grid should not draw with `data-cell-copy`.
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
---
2+
'@object-ui/plugin-form': patch
3+
'@object-ui/components': patch
4+
---
5+
6+
fix(ui): a placed line table's row editor is a form of its own, and a refused line marks its tab
7+
8+
Clause-②: no
9+
Metadata-protocol: none
10+
11+
Two fixes to a master-detail entry form whose field group places the line table:
12+
13+
- Opening a line's row editor no longer draws the editor's form inside the placed table's wrapper form. The markup is valid again, and React no longer logs "form cannot be a descendant of form" in development. The editor's inputs still belong to the editor's own form.
14+
- In a tabbed form, a save the server refuses on a line marks the tab that holds the lines, the way a refused header field marks its own tab. A refusal is on the lines when the server names a line's operation as the failed one, or names a field that only the lines write. The mark clears when the next save gets past validation.

0 commit comments

Comments
 (0)