Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions .changeset/37042-skills-inline-edit-boolean.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
---
'@objectstack/skills': patch
---

docs(skills): the data and UI skills no longer teach a boolean `inlineEdit` on a master-detail relationship

Clause-②: no
Metadata-protocol: none

objectstack-data's `rules/relationships.md`, "Inline-edit form factor": the `inlineEdit: true // auto (default)` line is gone, and the smart default is now described as what an omitted key gets, with a note that a boolean is refused. The spec parse refuses `true` and `false` on a relationship field's `inlineEdit` since 18.7.0; only `'grid'` and `'form'` are accepted, and leaving the key out picks the form factor from the child's shape. `evals/objects-fields-relationships.json` case 25 drops the same `true` from its expected answer. objectstack-ui's `rules/list-views.md`, Master-Detail Forms: the pointer to that section no longer lists `true` beside `'grid'` and `'form'`; it says `'grid'` / `'form'` or left out.
Original file line number Diff line number Diff line change
Expand Up @@ -436,7 +436,7 @@
{
"id": 25,
"prompt": "`quote_line` 通过 `master_detail` 字段 `quote` 归属 `quote`。新建报价单时要在表单里直接录明细,和报价单一起保存。该怎么声明?",
"expected_output": "On the PARENT `quote` object, a field group that names the child: `fieldGroups: [..., { key: 'lines', label: '明细', relatedList: 'quote_line' }]` (such a group holds no fields). The standard create/edit form of `quote` then enters the lines at that group and saves quote + lines in one atomic transaction, and the record page draws the same table there. Without the group nothing changes: `quote_line` is a tab and the form has no lines, whatever `inlineEdit` on `quote_line.quote` says; `inlineEdit` only picks how the rows are edited (`'grid'` / `'form'`, `true` or absent picks by the child's shape). No custom page and no form view is needed. If either object declares `enable.apiMethods`, it must list `'bulk'`.",
"expected_output": "On the PARENT `quote` object, a field group that names the child: `fieldGroups: [..., { key: 'lines', label: '明细', relatedList: 'quote_line' }]` (such a group holds no fields). The standard create/edit form of `quote` then enters the lines at that group and saves quote + lines in one atomic transaction, and the record page draws the same table there. Without the group nothing changes: `quote_line` is a tab and the form has no lines, whatever `inlineEdit` on `quote_line.quote` says; `inlineEdit` only picks how the rows are edited (`'grid'` / `'form'`; absent picks by the child's shape). No custom page and no form view is needed. If either object declares `enable.apiMethods`, it must list `'bulk'`.",
"files": [],
"assertions": {
"must_contain": [
Expand Down
3 changes: 1 addition & 2 deletions skills/objectstack-data/rules/relationships.md
Original file line number Diff line number Diff line change
Expand Up @@ -285,12 +285,11 @@ The rendering side: objectstack-ui → Master-Detail Forms.
`inlineEdit` only picks how a placed child's rows are entered:

```typescript
inlineEdit: true // auto (default)
inlineEdit: 'grid' // editable line-item grid (fast bulk entry; thin children)
inlineEdit: 'form' // read-only list; "Add" / per-row edit opens the FULL form
```

**`true`** / omitted — **smart default**: picks `form` when the child has
Omitted (a boolean is refused) — **smart default**: picks `form` when the child has
rich/form-only fields (textarea, file, image, json, location…) or more than ~8
editable fields, else `grid`.

Expand Down
2 changes: 1 addition & 1 deletion skills/objectstack-ui/rules/list-views.md
Original file line number Diff line number Diff line change
Expand Up @@ -387,7 +387,7 @@ custom page. Prefer, in order:
is a tab and the form has no lines. A parent or child
declaring `enable.apiMethods` must list `'bulk'`, or that save is refused
`405 OBJECT_API_METHOD_NOT_ALLOWED`. `inlineEdit` only picks how rows are
edited, the `true` / `'grid'` / `'form'` ladder:
edited, `'grid'` / `'form'` or left out:
**objectstack-data → Relationships → Inline Editing**.

2. **`object-master-detail-form` page block (bespoke layout).** Use a page only
Expand Down
Loading