cabloy 5.1.65 → 5.1.66
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +44 -0
- package/cabloy-docs/.vitepress/config.mjs +1 -1
- package/cabloy-docs/backend/crud-workflow.md +33 -0
- package/cabloy-docs/backend/master-detail-workflow.md +149 -0
- package/cabloy-docs/frontend/bean-scene-authoring.md +1 -1
- package/cabloy-docs/frontend/cli.md +12 -1
- package/cabloy-docs/frontend/command-scene-authoring.md +12 -1
- package/cabloy-docs/frontend/component-guide.md +10 -0
- package/cabloy-docs/frontend/permission-formscene-action-visibility-guide.md +69 -7
- package/cabloy-docs/frontend/table-cell-cookbook.md +10 -0
- package/cabloy-docs/fullstack/backend-metadata-to-frontend-table-actions.md +83 -2
- package/cabloy-docs/reference/bean-scene-boilerplates.md +9 -4
- package/package.json +1 -1
- package/vona/packages-cli/cabloy-cli/package.json +1 -1
- package/vona/packages-cli/cabloy-cli/src/lib/local.helper.ts +38 -0
- package/vona/packages-cli/cli/package.json +1 -1
- package/vona/packages-cli/cli-set-api/cli/templates/tools/masterDetail/boilerplate/dto/<%=argv.detailDtoBaseName%>.tsx_ +18 -0
- package/vona/packages-cli/cli-set-api/cli/templates/tools/masterDetail/boilerplate/dto/<%=argv.detailDtoMutateName%>.tsx_ +17 -0
- package/vona/packages-cli/cli-set-api/cli/templates/tools/masterDetail/boilerplate/dto/<%=argv.detailDtoResItemName%>.tsx_ +60 -0
- package/vona/packages-cli/cli-set-api/cli/templates/tools/masterDetail/boilerplate/dto/<%=argv.detailDtoViewName%>.tsx_ +17 -0
- package/vona/packages-cli/cli-set-api/package.json +1 -1
- package/vona/packages-cli/cli-set-api/src/lib/bean/cli.create.bean.ts +2 -6
- package/vona/packages-cli/cli-set-api/src/lib/bean/cli.create.module.ts +3 -6
- package/vona/packages-cli/cli-set-api/src/lib/bean/cli.create.suite.ts +1 -1
- package/vona/packages-cli/cli-set-api/src/lib/bean/cli.create.test.ts +2 -6
- package/vona/packages-cli/cli-set-api/src/lib/bean/cli.init.asset.ts +2 -6
- package/vona/packages-cli/cli-set-api/src/lib/bean/cli.init.config.ts +2 -6
- package/vona/packages-cli/cli-set-api/src/lib/bean/cli.init.constant.ts +2 -6
- package/vona/packages-cli/cli-set-api/src/lib/bean/cli.init.error.ts +2 -6
- package/vona/packages-cli/cli-set-api/src/lib/bean/cli.init.lib.ts +2 -6
- package/vona/packages-cli/cli-set-api/src/lib/bean/cli.init.locale.ts +2 -6
- package/vona/packages-cli/cli-set-api/src/lib/bean/cli.init.main.ts +2 -6
- package/vona/packages-cli/cli-set-api/src/lib/bean/cli.init.monkey.ts +2 -6
- package/vona/packages-cli/cli-set-api/src/lib/bean/cli.init.static.ts +2 -6
- package/vona/packages-cli/cli-set-api/src/lib/bean/cli.init.types.ts +2 -6
- package/vona/packages-cli/cli-set-api/src/lib/bean/cli.tools.crud.ts +2 -6
- package/vona/packages-cli/cli-set-api/src/lib/bean/cli.tools.crudBasic.ts +2 -6
- package/vona/packages-cli/cli-set-api/src/lib/bean/cli.tools.crudStart.ts +2 -6
- package/vona/packages-cli/cli-set-api/src/lib/bean/cli.tools.masterDetail.ts +699 -0
- package/vona/packages-cli/cli-set-api/src/lib/bean/cli.tools.metadata.ts +1 -2
- package/vona/packages-cli/cli-set-api/src/lib/beans.ts +2 -0
- package/vona/packages-cli/cli-set-api/src/lib/command/tools.masterDetail.ts +78 -0
- package/vona/packages-cli/cli-set-api/src/lib/commands.ts +2 -0
- package/vona/packages-vona/vona/package.json +1 -1
- package/vona/packages-vona/vona-core/package.json +1 -1
- package/vona/packages-vona/vona-core/src/lib/mappedClass/type.ts +1 -0
- package/vona/packages-vona/vona-core/src/lib/mappedClass/utils.ts +36 -14
- package/vona/packages-vona/vona-mock/package.json +1 -1
- package/vona/pnpm-lock.yaml +20 -11
- package/vona/src/suite/a-training/modules/training-student/src/config/locale/en-us.ts +3 -0
- package/vona/src/suite/a-training/modules/training-student/src/config/locale/zh-cn.ts +3 -0
- package/vona/src/suite/a-training/modules/training-student/src/dto/detailRecordBase.tsx +8 -2
- package/vona/src/suite/a-training/modules/training-student/src/dto/detailRecordMutate.tsx +1 -15
- package/vona/src/suite/a-training/modules/training-student/src/dto/detailRecordResItem.tsx +25 -5
- package/vona/src/suite/a-training/modules/training-student/src/dto/detailRecordView.tsx +1 -12
- package/vona/src/suite/a-training/modules/training-student/src/dto/studentCreate.tsx +6 -4
- package/vona/src/suite/a-training/modules/training-student/src/dto/studentSelectReq.tsx +3 -6
- package/vona/src/suite/a-training/modules/training-student/src/dto/studentSummary.tsx +1 -1
- package/vona/src/suite/a-training/modules/training-student/src/dto/studentUpdate.tsx +14 -1
- package/vona/src/suite/a-training/modules/training-student/src/dto/studentView.tsx +14 -1
- package/vona/src/suite/a-training/modules/training-student/src/entity/student.tsx +1 -5
- package/vona/src/suite/a-training/modules/training-student/src/service/student.ts +9 -4
- package/vona/src/suite-vendor/a-vona/modules/a-core/package.json +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-openapiutils/package.json +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-openapiutils/src/lib/const/decorator.ts +3 -1
- package/vona/src/suite-vendor/a-vona/modules/a-openapiutils/src/lib/schema/makeSchemaLikes.ts +21 -17
- package/vona/src/suite-vendor/a-vona/modules/a-openapiutils/src/lib/utils.ts +44 -2
- package/vona/src/suite-vendor/a-vona/modules/a-orm/package.json +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/lib/dto/dtoGet.ts +2 -2
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/lib/dto/dtoMutate.ts +8 -1
- package/vona/src/suite-vendor/a-vona/modules/a-orm/src/service/relations_.ts +32 -16
- package/vona/src/suite-vendor/a-vona/modules/a-web/package.json +1 -1
- package/vona/src/suite-vendor/a-vona/modules/a-web/src/lib/decorator/bean.ts +26 -5
- package/vona/src/suite-vendor/a-vona/package.json +1 -1
- package/zova/packages-cli/cli/package.json +3 -3
- package/zova/packages-cli/cli-set-front/cli/templates/create/component/boilerplateDetailsActionBulk/controller.tsx_ +31 -0
- package/zova/packages-cli/cli-set-front/cli/templates/rest/component.ts +21 -0
- package/zova/packages-cli/cli-set-front/cli/templates/rest/render.ts +4 -0
- package/zova/packages-cli/cli-set-front/package.json +2 -2
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.create.bean.ts +2 -6
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.create.mock.ts +2 -6
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.create.module.ts +3 -6
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.create.suite.ts +1 -1
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.init.asset.ts +2 -6
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.init.config.ts +2 -6
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.init.constant.ts +2 -6
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.init.error.ts +2 -6
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.init.icon.ts +2 -6
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.init.lib.ts +2 -6
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.init.locale.ts +2 -6
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.init.main.ts +2 -6
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.init.mainSys.ts +2 -6
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.init.monkey.ts +2 -6
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.init.monkeySys.ts +2 -6
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.init.types.ts +2 -6
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.openapi.config.ts +1 -4
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.openapi.generate.ts +2 -2
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.refactor.anotherRender.ts +2 -6
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.refactor.anotherStyle.ts +2 -6
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.refactor.componentEmits.ts +2 -6
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.refactor.componentGeneric.ts +2 -6
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.refactor.componentModel.ts +2 -6
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.refactor.componentProps.ts +2 -6
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.refactor.componentSlots.ts +2 -6
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.refactor.firstRender.ts +2 -6
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.refactor.firstStyle.ts +2 -6
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.refactor.pageParams.ts +2 -6
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.refactor.pageQuery.ts +2 -6
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.refactor.renameComponent.ts +2 -6
- package/zova/packages-cli/cli-set-front/src/lib/bean/cli.tools.metadata.ts +1 -2
- package/zova/packages-cli/cli-set-front/src/lib/common/cliCreateComponent.ts +2 -6
- package/zova/packages-cli/cli-set-front/src/lib/common/cliCreatePage.ts +2 -6
- package/zova/packages-zova/zova/package.json +2 -2
- package/zova/pnpm-lock.yaml +744 -884
- package/zova/src/suite/a-training/modules/training-student/package.json +2 -1
- package/zova/src/suite/cabloy-basic/modules/basic-app/src/bean/behavior.appModal.tsx +131 -13
- package/zova/src/suite/cabloy-basic/modules/basic-app/src/config/config.ts +15 -0
- package/zova/src/suite/cabloy-basic/modules/basic-app/src/service/appModal.ts +23 -5
- package/zova/src/suite/cabloy-basic/modules/basic-app/src/types/appModal.ts +30 -4
- package/zova/src/suite/cabloy-basic/modules/basic-details/package.json +6 -1
- package/zova/src/suite/cabloy-basic/modules/basic-details/src/.metadata/component/blockForm.ts +31 -0
- package/zova/src/suite/cabloy-basic/modules/basic-details/src/.metadata/index.ts +149 -2
- package/zova/src/suite/cabloy-basic/modules/basic-details/src/bean/command.delete.tsx +47 -0
- package/zova/src/suite/cabloy-basic/modules/basic-details/src/bean/tableCell.actionDelete.tsx +52 -0
- package/zova/src/suite/cabloy-basic/modules/basic-details/src/bean/tableCell.actionOperationsRow.tsx +44 -6
- package/zova/src/suite/cabloy-basic/modules/basic-details/src/bean/tableCell.actionUpdate.tsx +73 -0
- package/zova/src/suite/cabloy-basic/modules/basic-details/src/bean/tableCell.actionView.tsx +64 -0
- package/zova/src/suite/cabloy-basic/modules/basic-details/src/bean/tableCell.lineNumber.tsx +30 -0
- package/zova/src/suite/cabloy-basic/modules/basic-details/src/component/actionCreate/controller.tsx +29 -5
- package/zova/src/suite/cabloy-basic/modules/basic-details/src/component/blockDetails/controller.tsx +28 -12
- package/zova/src/suite/cabloy-basic/modules/basic-details/src/component/blockForm/controller.tsx +53 -0
- package/zova/src/suite/cabloy-basic/modules/basic-details/src/component/blockTable/controller.tsx +7 -2
- package/zova/src/suite/cabloy-basic/modules/basic-details/src/component/blockToolbarBulk/controller.tsx +3 -1
- package/zova/src/suite/cabloy-basic/modules/basic-details/src/component/formFieldDetails/controller.tsx +24 -12
- package/zova/src/suite/cabloy-basic/modules/basic-details/src/config/locale/en-us.ts +4 -0
- package/zova/src/suite/cabloy-basic/modules/basic-details/src/config/locale/zh-cn.ts +4 -0
- package/zova/src/suite/cabloy-basic/modules/basic-details/src/index.ts +1 -0
- package/zova/src/suite/cabloy-basic/modules/basic-details/src/lib/index.ts +1 -0
- package/zova/src/suite/cabloy-basic/modules/basic-details/src/lib/utils.ts +12 -0
- package/zova/src/suite/cabloy-basic/modules/basic-details/src/service/detail.tsx +172 -0
- package/zova/src/suite/cabloy-basic/modules/basic-details/src/types/detail.ts +18 -0
- package/zova/src/suite/cabloy-basic/modules/basic-details/src/types/details.ts +11 -0
- package/zova/src/suite/cabloy-basic/modules/basic-details/src/types/dialogForm.ts +22 -0
- package/zova/src/suite/cabloy-basic/modules/basic-details/src/types/index.ts +2 -0
- package/zova/src/suite-vendor/a-cabloy/modules/rest-resource/package.json +1 -1
- package/zova/src/suite-vendor/a-cabloy/modules/rest-resource/src/page/entry/controller.tsx +1 -2
- package/zova/src/suite-vendor/a-cabloy/package.json +2 -2
- package/zova/src/suite-vendor/a-zova/modules/a-command/cli/command/boilerplate/{{sceneName}}.{{beanName}}.tsx_ +6 -1
- package/zova/src/suite-vendor/a-zova/modules/a-command/cli/commandBulk/boilerplate/{{sceneName}}.{{beanName}}.tsx_ +6 -1
- package/zova/src/suite-vendor/a-zova/modules/a-command/cli/commandDetailsRow/boilerplate/{{sceneName}}.{{beanName}}.tsx_ +20 -0
- package/zova/src/suite-vendor/a-zova/modules/a-command/cli/commandRow/boilerplate/{{sceneName}}.{{beanName}}.tsx_ +6 -1
- package/zova/src/suite-vendor/a-zova/modules/a-command/package.json +3 -2
- package/zova/src/suite-vendor/a-zova/modules/a-command/src/types/command.ts +2 -0
- package/zova/src/suite-vendor/a-zova/modules/a-form/package.json +1 -1
- package/zova/src/suite-vendor/a-zova/modules/a-form/src/component/form/controller.tsx +1 -0
- package/zova/src/suite-vendor/a-zova/modules/a-openapi/package.json +2 -2
- package/zova/src/suite-vendor/a-zova/modules/a-openapi/src/lib/schema.ts +20 -4
- package/zova/src/suite-vendor/a-zova/modules/a-openapi/src/types/action.ts +2 -1
- package/zova/src/suite-vendor/a-zova/modules/a-openapi/src/types/detail/detail.ts +10 -0
- package/zova/src/suite-vendor/a-zova/modules/a-openapi/src/types/detail/details.ts +4 -1
- package/zova/src/suite-vendor/a-zova/modules/a-openapi/src/types/detail/index.ts +1 -0
- package/zova/src/suite-vendor/a-zova/modules/a-openapi/src/types/rest.ts +2 -0
- package/zova/src/suite-vendor/a-zova/modules/a-table/cli/detailsActionRow/boilerplate/{{sceneName}}.{{beanName}}.tsx_ +24 -0
- package/zova/src/suite-vendor/a-zova/modules/a-table/package.json +3 -2
- package/zova/src/suite-vendor/a-zova/modules/a-table/src/component/table/controller.tsx +5 -3
- package/zova/src/suite-vendor/a-zova/modules/a-zova/package.json +2 -2
- package/zova/src/suite-vendor/a-zova/package.json +6 -6
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,49 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 5.1.66
|
|
4
|
+
|
|
5
|
+
### Features
|
|
6
|
+
|
|
7
|
+
- Add the Vona master-detail scaffold workflow.
|
|
8
|
+
- Add details action boilerplates.
|
|
9
|
+
- Add a details view action.
|
|
10
|
+
- Add dialog-based detail creation.
|
|
11
|
+
- Add a detail edit dialog.
|
|
12
|
+
- Enhance modal close controls.
|
|
13
|
+
- Improve dialog viewport sizing.
|
|
14
|
+
- Improve detail row handling.
|
|
15
|
+
- Support DTO metadata replacement.
|
|
16
|
+
|
|
17
|
+
### Bug Fixes
|
|
18
|
+
|
|
19
|
+
- Validate canonical suite names across CLI commands.
|
|
20
|
+
- Validate canonical module names across CLI commands.
|
|
21
|
+
- Validate canonical master-detail module names.
|
|
22
|
+
- Support `dtoClass` fields in DTO mutation.
|
|
23
|
+
- Normalize relation table identity comparisons.
|
|
24
|
+
|
|
25
|
+
### Improvements
|
|
26
|
+
|
|
27
|
+
- Remove Zova CLI canonical helper shims.
|
|
28
|
+
- Extract a generic file content patch helper.
|
|
29
|
+
- Unify master-detail patch runners.
|
|
30
|
+
- Extract master path helpers.
|
|
31
|
+
- Extract locale and metadata helper flow.
|
|
32
|
+
- Extract master DTO string builders.
|
|
33
|
+
- Extract detail metadata patch helper.
|
|
34
|
+
- Extract master model and service patch helpers.
|
|
35
|
+
- Extract detail entity patch helpers.
|
|
36
|
+
- Split master-detail detail mode helpers.
|
|
37
|
+
- Extract master-detail DTO patch helpers.
|
|
38
|
+
- Streamline master-detail scene and locale loops.
|
|
39
|
+
- Simplify the master-detail DTO rendering flow.
|
|
40
|
+
- Support detail render context in dialog forms.
|
|
41
|
+
- Move the detail dialog form to the detail service.
|
|
42
|
+
- Extract the details block form component.
|
|
43
|
+
- Extract the details dialog form helper.
|
|
44
|
+
- Align the `actionCreate` dialog style.
|
|
45
|
+
- Use a `Set` for relation identity lookup.
|
|
46
|
+
|
|
3
47
|
## 5.1.65
|
|
4
48
|
|
|
5
49
|
### Features
|
|
@@ -100,6 +100,39 @@ A practical rule is:
|
|
|
100
100
|
- refine the generated code when response contracts, DTO behavior, controller metadata, model behavior, or test flow need stronger domain-specific semantics
|
|
101
101
|
- avoid replacing the generated thread wholesale unless the framework shape truly does not fit the use case
|
|
102
102
|
|
|
103
|
+
## Aggregate detail scaffolding
|
|
104
|
+
|
|
105
|
+
When the business shape is not a standalone CRUD resource but a master resource that owns a nested detail collection, use the master-detail generator instead of hand-wiring the relation and DTO thread.
|
|
106
|
+
|
|
107
|
+
Example:
|
|
108
|
+
|
|
109
|
+
```bash
|
|
110
|
+
npm run vona :tools:masterDetail student -- --module=training-student --detailModule=training-record --detailResourceName=record --relationName=trainingRecords --fk=studentId --detailMode=aggregate
|
|
111
|
+
```
|
|
112
|
+
|
|
113
|
+
This command is intended to scaffold the aggregate-detail thread that the `training-student` / `training-record` specimen demonstrates:
|
|
114
|
+
|
|
115
|
+
- master model `hasMany` relation
|
|
116
|
+
- master service `include` lifecycle
|
|
117
|
+
- master-side nested detail DTOs
|
|
118
|
+
- built-in `basic-details` bulk/row actions
|
|
119
|
+
- detail FK persistence and index wiring
|
|
120
|
+
|
|
121
|
+
For `--module` and `--detailModule`, use canonical Vona module relative names such as `training-student` and `training-record`, not package names such as `vona-module-training-student`.
|
|
122
|
+
|
|
123
|
+
### Two supported detail-module modes
|
|
124
|
+
|
|
125
|
+
Use `--detailMode=aggregate` when the detail module should remain entity/model/meta-only and should not expose its own standalone controller/service resource surface.
|
|
126
|
+
|
|
127
|
+
Use `--detailMode=standalone` when the detail module should participate in the master aggregate but also keep its own standalone resource surface.
|
|
128
|
+
|
|
129
|
+
A practical rule is:
|
|
130
|
+
|
|
131
|
+
- choose `aggregate` when the detail is owned and managed primarily inside the master workflow
|
|
132
|
+
- choose `standalone` when the detail also needs independent resource entry/use cases
|
|
133
|
+
|
|
134
|
+
The generator should be the default starting point for this pattern, and manual refinement should come afterward.
|
|
135
|
+
|
|
103
136
|
## Relationship to DTO inference and OpenAPI
|
|
104
137
|
|
|
105
138
|
The generated thread is also part of the broader contract-emission path.
|
|
@@ -0,0 +1,149 @@
|
|
|
1
|
+
# Master-Detail Workflow
|
|
2
|
+
|
|
3
|
+
This guide explains how to scaffold a backend master-detail aggregate in the Cabloy monorepo.
|
|
4
|
+
|
|
5
|
+
## Why this page matters
|
|
6
|
+
|
|
7
|
+
Some business shapes are not best expressed as two unrelated CRUD resources.
|
|
8
|
+
|
|
9
|
+
A common pattern is:
|
|
10
|
+
|
|
11
|
+
- one master resource owns the aggregate lifecycle
|
|
12
|
+
- one detail resource is edited as a nested collection under the master
|
|
13
|
+
- the detail may or may not also expose its own standalone resource surface
|
|
14
|
+
|
|
15
|
+
The `training-student` + `training-record` specimen in the current repo demonstrates this pattern.
|
|
16
|
+
|
|
17
|
+
## Use the generator first
|
|
18
|
+
|
|
19
|
+
When the requirement is “add details under a master resource,” prefer the master-detail generator before hand-wiring relation, DTO, and service changes.
|
|
20
|
+
|
|
21
|
+
Example:
|
|
22
|
+
|
|
23
|
+
```bash
|
|
24
|
+
npm run vona :tools:masterDetail student -- --module=training-student --detailModule=training-record --detailResourceName=record --relationName=trainingRecords --fk=studentId --detailMode=aggregate
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
A practical reading of the arguments is:
|
|
28
|
+
|
|
29
|
+
- `student`: master resource name
|
|
30
|
+
- `--module=training-student`: master module
|
|
31
|
+
- `--detailModule=training-record`: detail module
|
|
32
|
+
- `--detailResourceName=record`: detail resource name inside the detail module
|
|
33
|
+
- `--relationName=trainingRecords`: master-side `hasMany` relation name
|
|
34
|
+
- `--fk=studentId`: detail-side FK field
|
|
35
|
+
- `--detailMode=...`: whether the detail keeps a standalone resource surface
|
|
36
|
+
|
|
37
|
+
## Module naming rule
|
|
38
|
+
|
|
39
|
+
For `--module` and `--detailModule`, use the canonical Vona module relative name such as `training-student` or `training-record`.
|
|
40
|
+
|
|
41
|
+
A practical rule is:
|
|
42
|
+
|
|
43
|
+
- use the module relative name itself
|
|
44
|
+
- do not pass the package name such as `vona-module-training-student`
|
|
45
|
+
- do not append an extra suffix that changes the canonical module identity
|
|
46
|
+
|
|
47
|
+
This matters because the CLI resolves modules by their canonical relative names.
|
|
48
|
+
|
|
49
|
+
## What the generator scaffolds
|
|
50
|
+
|
|
51
|
+
The generator is designed to create the aggregate-detail thread, including:
|
|
52
|
+
|
|
53
|
+
1. master model relation wiring
|
|
54
|
+
2. master service `include` lifecycle for create/view/update/delete
|
|
55
|
+
3. master-side nested detail DTOs
|
|
56
|
+
4. built-in `basic-details` UI metadata for row/bulk actions
|
|
57
|
+
5. detail FK persistence field in the detail entity
|
|
58
|
+
6. detail schema/index support for the FK
|
|
59
|
+
|
|
60
|
+
This keeps the structural pattern consistent before domain-specific refinement starts.
|
|
61
|
+
|
|
62
|
+
## Two supported detail-module modes
|
|
63
|
+
|
|
64
|
+
### Aggregate mode
|
|
65
|
+
|
|
66
|
+
Use:
|
|
67
|
+
|
|
68
|
+
```bash
|
|
69
|
+
--detailMode=aggregate
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
In this mode, the detail module remains:
|
|
73
|
+
|
|
74
|
+
- entity/model/meta-based
|
|
75
|
+
- owned by the master aggregate
|
|
76
|
+
- without a standalone controller/service resource surface
|
|
77
|
+
|
|
78
|
+
Choose this mode when the detail is primarily edited only through the master workflow.
|
|
79
|
+
|
|
80
|
+
### Standalone mode
|
|
81
|
+
|
|
82
|
+
Use:
|
|
83
|
+
|
|
84
|
+
```bash
|
|
85
|
+
--detailMode=standalone
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
In this mode, the detail module:
|
|
89
|
+
|
|
90
|
+
- still participates in the master aggregate
|
|
91
|
+
- keeps or creates its own standalone controller/service resource surface
|
|
92
|
+
|
|
93
|
+
Choose this mode when the detail also needs independent entry points, workflows, or resource-level access outside the master editing flow.
|
|
94
|
+
|
|
95
|
+
## Practical decision rule
|
|
96
|
+
|
|
97
|
+
Use aggregate mode when:
|
|
98
|
+
|
|
99
|
+
- the detail has no meaningful lifecycle outside the master
|
|
100
|
+
- independent detail routes would add noise rather than value
|
|
101
|
+
- the master should remain the clear aggregate root
|
|
102
|
+
|
|
103
|
+
Use standalone mode when:
|
|
104
|
+
|
|
105
|
+
- the detail also needs independent CRUD/use cases
|
|
106
|
+
- external workflows need to query or mutate detail items directly
|
|
107
|
+
- the detail has user-facing or integration-facing behavior beyond nested editing
|
|
108
|
+
|
|
109
|
+
## Specimen mapping
|
|
110
|
+
|
|
111
|
+
The current specimen maps like this:
|
|
112
|
+
|
|
113
|
+
- master relation: `vona/src/suite/a-training/modules/training-student/src/model/student.ts`
|
|
114
|
+
- master service include lifecycle: `vona/src/suite/a-training/modules/training-student/src/service/student.ts`
|
|
115
|
+
- master nested DTOs: `vona/src/suite/a-training/modules/training-student/src/dto/studentCreate.tsx`, `studentUpdate.tsx`, `studentView.tsx`
|
|
116
|
+
- detail row/bulk metadata: `vona/src/suite/a-training/modules/training-student/src/dto/detailRecordResItem.tsx`
|
|
117
|
+
- detail FK field: `vona/src/suite/a-training/modules/training-record/src/entity/record.tsx`
|
|
118
|
+
|
|
119
|
+
This is the reference shape the generator aims to standardize.
|
|
120
|
+
|
|
121
|
+
## Recommended workflow
|
|
122
|
+
|
|
123
|
+
1. run `:tools:masterDetail`
|
|
124
|
+
2. inspect the generated relation, DTO, and service thread
|
|
125
|
+
3. refine entity fields and validation rules for the domain
|
|
126
|
+
4. refine detail columns/actions when the default `basic-details` behavior is not enough
|
|
127
|
+
5. refresh and verify metadata/build outputs
|
|
128
|
+
|
|
129
|
+
## Relationship to CRUD workflow
|
|
130
|
+
|
|
131
|
+
Use [CRUD Workflow](/backend/crud-workflow) when the target is primarily a standalone resource.
|
|
132
|
+
|
|
133
|
+
Use this page when the target is a master resource with a nested detail collection.
|
|
134
|
+
|
|
135
|
+
The two workflows are complementary:
|
|
136
|
+
|
|
137
|
+
- CRUD scaffolds standalone backend threads
|
|
138
|
+
- master-detail scaffolds aggregate ownership plus nested detail editing
|
|
139
|
+
|
|
140
|
+
## Verification checklist
|
|
141
|
+
|
|
142
|
+
After generation:
|
|
143
|
+
|
|
144
|
+
1. confirm the master model contains the `hasMany` relation
|
|
145
|
+
2. confirm master service create/view/update/delete includes the detail relation
|
|
146
|
+
3. confirm master create/update/view DTOs include nested detail DTO wiring
|
|
147
|
+
4. confirm the detail entity contains the FK field
|
|
148
|
+
5. confirm detail schema/index output includes the FK support
|
|
149
|
+
6. if standalone mode was chosen, confirm the detail module still exposes its standalone resource surface
|
|
@@ -213,7 +213,7 @@ A practical rule is:
|
|
|
213
213
|
|
|
214
214
|
This is useful when one scene needs multiple scaffold shapes for distinct frontend authoring paths.
|
|
215
215
|
|
|
216
|
-
Representative built-in examples include the `command` scene, which exposes `commandBulk` and `
|
|
216
|
+
Representative built-in examples include the `command` scene, which exposes `commandBulk`, `commandRow`, and `commandDetailsRow` variants, and the `tableCell` scene, which exposes `tableActionRow` and `detailsActionRow` variants in module metadata.
|
|
217
217
|
|
|
218
218
|
For the built-in command scene’s runtime model, helper bases, metadata flow, and source-reading path, see [Command Scene Authoring](/frontend/command-scene-authoring).
|
|
219
219
|
|
|
@@ -87,9 +87,20 @@ The built-in `command` scene is the clearest current example:
|
|
|
87
87
|
npm run zova :create:bean command test -- --module=training-student
|
|
88
88
|
npm run zova :create:bean command test -- --module=training-student --boilerplate=commandBulk
|
|
89
89
|
npm run zova :create:bean command test -- --module=training-student --boilerplate=commandRow
|
|
90
|
+
npm run zova :create:bean command test -- --module=training-student --boilerplate=commandDetailsRow
|
|
90
91
|
```
|
|
91
92
|
|
|
92
|
-
Use the default template for the command shape without
|
|
93
|
+
Use the default template for the command shape without helper bases, `commandBulk` for resource-oriented bulk commands, `commandRow` for table-row commands that need `resource` and `id`, and `commandDetailsRow` for detail-row commands that run against `ICommandDetailsRowOptionsBase`.
|
|
94
|
+
|
|
95
|
+
The same naming rule also applies to `:create:component`. For example, the built-in component variants now include `detailsActionBulk`, alongside variants such as `formField`, `formActionRow`, `tableActionBulk`, `blockPage`, and `blockPageEntry`.
|
|
96
|
+
|
|
97
|
+
Representative component example:
|
|
98
|
+
|
|
99
|
+
```bash
|
|
100
|
+
npm run zova :create:component actionCreate -- --module=training-student --boilerplate=detailsActionBulk
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
Use `detailsActionBulk` when you need a detail-page bulk action controller scaffold that registers into `IResourceDetailsActionBulkRecord` and receives `IJsxRenderContextDetails` through host injection.
|
|
93
104
|
|
|
94
105
|
For the command-scene runtime model and source-reading path, see [Command Scene Authoring](/frontend/command-scene-authoring).
|
|
95
106
|
|
|
@@ -284,7 +284,7 @@ Important pieces:
|
|
|
284
284
|
- the result-type carrier used in the command option contract
|
|
285
285
|
- `IDecoratorCommandOptions`
|
|
286
286
|
- the base decorator options shape
|
|
287
|
-
- `ICommandOptionsBase`, `ICommandBulkOptionsBase`, `ICommandRowOptionsBase`
|
|
287
|
+
- `ICommandOptionsBase`, `ICommandBulkOptionsBase`, `ICommandRowOptionsBase`, `ICommandDetailsRowOptionsBase`
|
|
288
288
|
- shared option contracts for common command patterns
|
|
289
289
|
- `TypeCommandOptions<K>`
|
|
290
290
|
- typed command reference shape
|
|
@@ -336,6 +336,7 @@ The `zovaModule.onions.command` metadata confirms:
|
|
|
336
336
|
- default `boilerplate`
|
|
337
337
|
- `boilerplateCommandBulk`
|
|
338
338
|
- `boilerplateCommandRow`
|
|
339
|
+
- `boilerplateCommandDetailsRow`
|
|
339
340
|
|
|
340
341
|
The CLI command shape is currently exposed by:
|
|
341
342
|
|
|
@@ -373,6 +374,16 @@ Use the row variant when the command should resolve `resource` and `id` through
|
|
|
373
374
|
npm run zova :create:bean command test -- --module=training-student --boilerplate=commandRow
|
|
374
375
|
```
|
|
375
376
|
|
|
377
|
+
### `commandDetailsRow` boilerplate
|
|
378
|
+
|
|
379
|
+
Use the details-row variant when the command should operate in the details-row action path and type its options through `ICommandDetailsRowOptionsBase`:
|
|
380
|
+
|
|
381
|
+
```bash
|
|
382
|
+
npm run zova :create:bean command test -- --module=training-student --boilerplate=commandDetailsRow
|
|
383
|
+
```
|
|
384
|
+
|
|
385
|
+
A representative built-in consumer is `basic-details/src/bean/command.delete.tsx`, which uses the details render context and row information from the current detail table cell.
|
|
386
|
+
|
|
376
387
|
For the cross-scene lookup table, also see [Bean Scene Boilerplate Variants](/reference/bean-scene-boilerplates).
|
|
377
388
|
|
|
378
389
|
## Representative built-in examples
|
|
@@ -24,6 +24,16 @@ Example: create a component named `card` in module `training-student`.
|
|
|
24
24
|
npm run zova :create:component card -- --module=training-student
|
|
25
25
|
```
|
|
26
26
|
|
|
27
|
+
The component generator also supports named boilerplate variants through `--boilerplate=...`.
|
|
28
|
+
|
|
29
|
+
A practical current example is a detail-page bulk action controller scaffold:
|
|
30
|
+
|
|
31
|
+
```bash
|
|
32
|
+
npm run zova :create:component actionCreate -- --module=training-student --boilerplate=detailsActionBulk
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
That variant generates a controller registered in `IResourceDetailsActionBulkRecord` and injects `IJsxRenderContextDetails` from the host details runtime.
|
|
36
|
+
|
|
27
37
|
## Controller definition
|
|
28
38
|
|
|
29
39
|
Representative component controller shape:
|
|
@@ -195,6 +195,46 @@ And that bulk hint type does not have `formScene`.
|
|
|
195
195
|
|
|
196
196
|
This is the clearest public type-level explanation for the current limitation.
|
|
197
197
|
|
|
198
|
+
## 6A. Details actions have their own scene-aware visibility path
|
|
199
|
+
|
|
200
|
+
The details-table action path uses a nearby but distinct contract.
|
|
201
|
+
|
|
202
|
+
Relevant type-level surfaces are:
|
|
203
|
+
|
|
204
|
+
- `a-openapi/src/types/detail/detailsActionRow.ts`
|
|
205
|
+
- `a-openapi/src/types/detail/detailsActionBulk.ts`
|
|
206
|
+
- `a-openapi/src/types/permissions.ts`
|
|
207
|
+
|
|
208
|
+
The current source confirms:
|
|
209
|
+
|
|
210
|
+
- `IResourceDetailsActionRowOptionsBase` uses `permission?: IPermissionHintDetailsActionRow`
|
|
211
|
+
- `IResourceDetailsActionBulkOptionsBase` uses `permission?: IPermissionHintDetailsActionBulk`
|
|
212
|
+
- both details permission-hint types support `formScene`
|
|
213
|
+
|
|
214
|
+
That means the details action family is scene-aware in a different way from `tableActionBulk`.
|
|
215
|
+
|
|
216
|
+
A practical current example from backend DTO metadata is:
|
|
217
|
+
|
|
218
|
+
```tsx
|
|
219
|
+
ZovaRender.detailsActionBulk('basic-details:actionCreate', {
|
|
220
|
+
permission: { formScene: ['create', 'edit'] },
|
|
221
|
+
});
|
|
222
|
+
```
|
|
223
|
+
|
|
224
|
+
and:
|
|
225
|
+
|
|
226
|
+
```tsx
|
|
227
|
+
ZovaRender.detailsActionRow('basic-details:actionDelete', {
|
|
228
|
+
permission: { formScene: ['create', 'edit'] },
|
|
229
|
+
});
|
|
230
|
+
```
|
|
231
|
+
|
|
232
|
+
So the correct distinction is:
|
|
233
|
+
|
|
234
|
+
- `tableActionBulk` does not currently support `formScene`
|
|
235
|
+
- `detailsActionBulk` does support `formScene`
|
|
236
|
+
- `detailsActionRow` also supports `formScene`
|
|
237
|
+
|
|
198
238
|
## 7. Why bulk actions are different today
|
|
199
239
|
|
|
200
240
|
Bulk actions are typed around bulk permission hints, not row/form-scene hints.
|
|
@@ -203,9 +243,9 @@ So in current Basic source, you should not claim that bulk actions support scene
|
|
|
203
243
|
|
|
204
244
|
This is not only a docs distinction. It is a source-confirmed contract distinction.
|
|
205
245
|
|
|
206
|
-
## 8. Comparison with table row actions
|
|
246
|
+
## 8. Comparison with table row actions and details actions
|
|
207
247
|
|
|
208
|
-
A useful comparison file is:
|
|
248
|
+
A useful table-row comparison file is:
|
|
209
249
|
|
|
210
250
|
```text
|
|
211
251
|
zova/src/suite/cabloy-basic/modules/basic-table/src/bean/tableCell.actionOperationsRow.tsx
|
|
@@ -213,10 +253,25 @@ zova/src/suite/cabloy-basic/modules/basic-table/src/bean/tableCell.actionOperati
|
|
|
213
253
|
|
|
214
254
|
This table-row action surface uses permission checks, but it does not add the same local page-entry `formScene` prefilter path as `blockToolbarRow`.
|
|
215
255
|
|
|
216
|
-
|
|
256
|
+
A useful details comparison set is:
|
|
257
|
+
|
|
258
|
+
```text
|
|
259
|
+
zova/src/suite/cabloy-basic/modules/basic-details/src/component/blockToolbarBulk/controller.tsx
|
|
260
|
+
zova/src/suite/cabloy-basic/modules/basic-details/src/bean/tableCell.actionOperationsRow.tsx
|
|
261
|
+
zova/src/suite/cabloy-basic/modules/basic-details/src/lib/utils.ts
|
|
262
|
+
```
|
|
263
|
+
|
|
264
|
+
Those files show that the details action path also performs a scene-prefilter, but the authority is different:
|
|
265
|
+
|
|
266
|
+
- `blockToolbarRow` reads `$$pageEntry.formMeta.formScene`
|
|
267
|
+
- `basic-details` reads `$$details.formScene` or `$celScope.formMeta.formScene`
|
|
268
|
+
- the shared helper in `basic-details/src/lib/utils.ts` performs the actual `formScene` match
|
|
269
|
+
|
|
270
|
+
That makes the current frontend split more precise:
|
|
217
271
|
|
|
218
|
-
-
|
|
219
|
-
-
|
|
272
|
+
- entry-page row/form actions are scene-filtered by page-entry runtime context
|
|
273
|
+
- details bulk and details row actions are scene-filtered by details runtime context
|
|
274
|
+
- the two paths are similar in behavior, but they are not the same runtime surface
|
|
220
275
|
|
|
221
276
|
## 9. Boundary with page meta
|
|
222
277
|
|
|
@@ -233,10 +288,17 @@ So for action visibility, the local page-entry context is the authority.
|
|
|
233
288
|
|
|
234
289
|
## 10. Bulk-action limitation
|
|
235
290
|
|
|
236
|
-
The current public Basic source supports this rule clearly:
|
|
291
|
+
The current public Basic source supports this rule clearly for the table-action family:
|
|
237
292
|
|
|
238
293
|
- row/form action hints can be scene-aware
|
|
239
|
-
- bulk action hints are not scene-aware today
|
|
294
|
+
- table bulk action hints are not scene-aware today
|
|
295
|
+
|
|
296
|
+
But the details-action family is different:
|
|
297
|
+
|
|
298
|
+
- details row action hints can be scene-aware
|
|
299
|
+
- details bulk action hints can also be scene-aware
|
|
300
|
+
|
|
301
|
+
So do not compress these two families into one blanket rule about “bulk actions”.
|
|
240
302
|
|
|
241
303
|
If a contributor needs scene-aware bulk visibility, they should first verify whether the type and runtime contracts are being extended, rather than assuming the row-action rule applies automatically.
|
|
242
304
|
|
|
@@ -78,6 +78,14 @@ Create a row-action variant:
|
|
|
78
78
|
npm run zova :create:bean tableCell actionOperationsRow -- --module=training-student --boilerplate=tableActionRow
|
|
79
79
|
```
|
|
80
80
|
|
|
81
|
+
Create a details-row-action variant:
|
|
82
|
+
|
|
83
|
+
```bash
|
|
84
|
+
npm run zova :create:bean tableCell actionDelete -- --module=training-student --boilerplate=detailsActionRow
|
|
85
|
+
```
|
|
86
|
+
|
|
87
|
+
Use `tableActionRow` when one table cell should compose several table-row actions together. Use `detailsActionRow` when the render resource belongs to the details-row action contract under `IResourceDetailsActionRowRecord`.
|
|
88
|
+
|
|
81
89
|
The default scaffold shape is intentionally small:
|
|
82
90
|
|
|
83
91
|
```tsx
|
|
@@ -352,6 +360,8 @@ This pattern is different from a normal single-action cell because the bean ofte
|
|
|
352
360
|
|
|
353
361
|
That is why the `tableActionRow` boilerplate exists.
|
|
354
362
|
|
|
363
|
+
By contrast, the newer `detailsActionRow` boilerplate is for one detail-row action resource at a time. Its scaffold declaration-merges into `IResourceDetailsActionRowRecord` and types the options through `IResourceDetailsActionRowOptionsBase`, so it fits the details-table action path instead of the standard table-operations composition path.
|
|
364
|
+
|
|
355
365
|
Representative runtime shape:
|
|
356
366
|
|
|
357
367
|
```tsx
|
|
@@ -300,6 +300,85 @@ This is the same contract idea at a different UI level:
|
|
|
300
300
|
- backend or shared page metadata chooses the action resource identity
|
|
301
301
|
- frontend runtime resolves that identity to a visible action implementation
|
|
302
302
|
|
|
303
|
+
## Step 7A: Detail actions follow the same contract idea inside details blocks
|
|
304
|
+
|
|
305
|
+
The same contract model also appears in resource details tables.
|
|
306
|
+
|
|
307
|
+
A representative backend DTO shape is:
|
|
308
|
+
|
|
309
|
+
```tsx
|
|
310
|
+
@Dto({
|
|
311
|
+
blocks: [
|
|
312
|
+
ZovaRender.block('basic-details:blockDetails', {
|
|
313
|
+
blocks: [
|
|
314
|
+
ZovaRender.block('basic-details:blockToolbarBulk', {
|
|
315
|
+
actions: [
|
|
316
|
+
ZovaRender.detailsActionBulk('basic-details:actionCreate', {
|
|
317
|
+
permission: { formScene: ['create', 'edit'] },
|
|
318
|
+
}),
|
|
319
|
+
],
|
|
320
|
+
}),
|
|
321
|
+
ZovaRender.block('basic-details:blockTable'),
|
|
322
|
+
],
|
|
323
|
+
}),
|
|
324
|
+
],
|
|
325
|
+
})
|
|
326
|
+
```
|
|
327
|
+
|
|
328
|
+
And the row-action column inside that detail table can look like this:
|
|
329
|
+
|
|
330
|
+
```tsx
|
|
331
|
+
@Api.field(
|
|
332
|
+
v.title($locale('Operations')),
|
|
333
|
+
ZovaRender.order(1, 'max'),
|
|
334
|
+
ZovaRender.cell('basic-details:actionOperationsRow', {
|
|
335
|
+
actions: [
|
|
336
|
+
ZovaRender.detailsActionRow('basic-details:actionUpdate'),
|
|
337
|
+
ZovaRender.detailsActionRow('basic-details:actionDelete'),
|
|
338
|
+
],
|
|
339
|
+
}),
|
|
340
|
+
)
|
|
341
|
+
_operationsRow?: unknown;
|
|
342
|
+
```
|
|
343
|
+
|
|
344
|
+
This shows a practical three-part scaffold relationship:
|
|
345
|
+
|
|
346
|
+
1. `detailsActionBulk`
|
|
347
|
+
- creates a detail-level bulk action controller resource
|
|
348
|
+
- declaration-merges into `IResourceDetailsActionBulkRecord`
|
|
349
|
+
- is the right fit for actions such as add/create on the whole details block
|
|
350
|
+
2. `detailsActionRow`
|
|
351
|
+
- creates one detail-row action cell resource
|
|
352
|
+
- declaration-merges into `IResourceDetailsActionRowRecord`
|
|
353
|
+
- is the right fit for update/delete style actions attached to one detail row
|
|
354
|
+
3. `commandDetailsRow`
|
|
355
|
+
- creates the command bean used when a detail-row action should delegate its semantics to the command scene
|
|
356
|
+
- types options through `ICommandDetailsRowOptionsBase`
|
|
357
|
+
- is the right fit when the visible detail-row action should call `$performCommand(...)` instead of embedding all behavior directly in the cell bean
|
|
358
|
+
|
|
359
|
+
A representative built-in flow in `basic-details` is:
|
|
360
|
+
|
|
361
|
+
- `basic-details:actionCreate`
|
|
362
|
+
- a component/controller resource for `detailsActionBulk`
|
|
363
|
+
- `basic-details:actionUpdate`
|
|
364
|
+
- a `tableCell` resource for `detailsActionRow`
|
|
365
|
+
- `basic-details:actionDelete`
|
|
366
|
+
- a `tableCell` resource for `detailsActionRow`
|
|
367
|
+
- `basic-details:delete`
|
|
368
|
+
- a command bean that matches the `commandDetailsRow` execution pattern
|
|
369
|
+
|
|
370
|
+
A practical reading takeaway is:
|
|
371
|
+
|
|
372
|
+
- **details bulk actions** usually coordinate the whole details block
|
|
373
|
+
- **details row actions** usually own the visible row-level interaction
|
|
374
|
+
- **details row commands** are the reusable semantic layer when one row action should execute through the command scene
|
|
375
|
+
|
|
376
|
+
So even though the UI surface is a detail table instead of a top-level resource list, the architecture still follows the same rule:
|
|
377
|
+
|
|
378
|
+
- backend metadata chooses resource identities
|
|
379
|
+
- frontend resources implement the interaction
|
|
380
|
+
- optional command beans keep the action semantics reusable and scene-aware
|
|
381
|
+
|
|
303
382
|
## Step 8: Where the forward chain enters for custom actions
|
|
304
383
|
|
|
305
384
|
So far, everything could still be handled by built-in commands and built-in resources.
|
|
@@ -400,6 +479,7 @@ Typical examples:
|
|
|
400
479
|
- switch one field to `basic-table:actionView`
|
|
401
480
|
- add an operations row using existing update/delete actions
|
|
402
481
|
- add a custom table-cell renderer that backend metadata points to
|
|
482
|
+
- add a details block action chain with `detailsActionBulk` and `detailsActionRow` resources
|
|
403
483
|
|
|
404
484
|
### Mostly forward-chain work
|
|
405
485
|
|
|
@@ -458,8 +538,9 @@ If you want the shortest path to a correct table-action implementation, use this
|
|
|
458
538
|
3. regenerate frontend API consumers when backend contract changes
|
|
459
539
|
4. keep frontend model follow-up thin and semantic
|
|
460
540
|
5. point backend row metadata to the intended built-in or custom table-action resources
|
|
461
|
-
6.
|
|
462
|
-
7. verify the
|
|
541
|
+
6. for details-table work, also align `detailsActionBulk`, `detailsActionRow`, and any `commandDetailsRow` delegation path
|
|
542
|
+
7. verify the resource-page block chain still feeds the right schema into `ZTable`
|
|
543
|
+
8. verify the visible row action in Admin
|
|
463
544
|
|
|
464
545
|
## Verification checklist
|
|
465
546
|
|
|
@@ -44,13 +44,18 @@ These backend entries come from the current `vonaModule.onions` metadata in `a-a
|
|
|
44
44
|
|
|
45
45
|
### Current built-in scenes with variants
|
|
46
46
|
|
|
47
|
-
| Scene | Default metadata key | Named variant keys
|
|
48
|
-
| ----------- | -------------------- |
|
|
49
|
-
| `command` | `boilerplate` | `boilerplateCommandBulk`, `boilerplateCommandRow` | `npm run zova :create:bean command test -- --module=training-student --boilerplate=
|
|
50
|
-
| `tableCell` | `boilerplate` | `boilerplateTableActionRow`
|
|
47
|
+
| Scene | Default metadata key | Named variant keys | Example command pattern | Source module |
|
|
48
|
+
| ----------- | -------------------- | --------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------ | ----------------------- |
|
|
49
|
+
| `command` | `boilerplate` | `boilerplateCommandBulk`, `boilerplateCommandRow`, `boilerplateCommandDetailsRow` | `npm run zova :create:bean command test -- --module=training-student --boilerplate=commandDetailsRow` | `zova-module-a-command` |
|
|
50
|
+
| `tableCell` | `boilerplate` | `boilerplateTableActionRow`, `boilerplateDetailsActionRow` | `npm run zova :create:bean tableCell test -- --module=training-student --boilerplate=detailsActionRow` | `zova-module-a-table` |
|
|
51
51
|
|
|
52
52
|
These frontend entries come from the current `zovaModule.onions` metadata in `a-command` and `a-table`.
|
|
53
53
|
|
|
54
|
+
In practical terms:
|
|
55
|
+
|
|
56
|
+
- `commandDetailsRow` is the built-in command-scene scaffold for detail-row command beans
|
|
57
|
+
- `detailsActionRow` is the built-in `tableCell` scaffold for detail-row action cells under `IResourceDetailsActionRowRecord`
|
|
58
|
+
|
|
54
59
|
For the built-in command scene’s runtime model and helper-base patterns, see [Command Scene Authoring](/frontend/command-scene-authoring).
|
|
55
60
|
|
|
56
61
|
## Guidance for AI-assisted development
|
package/package.json
CHANGED