cabloy 5.1.60 → 5.1.62

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.
Files changed (232) hide show
  1. package/.claude/hooks/contract-loop-gate.ts +296 -0
  2. package/.claude/settings.json +16 -0
  3. package/.claude/skills/cabloy-backend-scaffold/SKILL.md +2 -0
  4. package/.claude/skills/cabloy-backend-scaffold/references/follow-up-checklist.md +1 -0
  5. package/.claude/skills/cabloy-contract-loop/SKILL.md +89 -16
  6. package/.claude/skills/cabloy-contract-loop/references/contract-loop-map.md +102 -14
  7. package/.claude/skills/cabloy-contract-loop/references/resource-custom-state-pattern.md +4 -0
  8. package/.claude/skills/cabloy-contract-loop/references/verification-checklist.md +32 -14
  9. package/.claude/skills/cabloy-domain-planning/SKILL.md +212 -0
  10. package/.claude/skills/cabloy-frontend-scaffold/SKILL.md +13 -0
  11. package/.claude/skills/cabloy-frontend-scaffold/references/follow-up-checklist.md +2 -0
  12. package/.claude/skills/cabloy-module-removal/SKILL.md +144 -0
  13. package/.claude/skills/cabloy-resource-field-update/SKILL.md +7 -0
  14. package/.claude/skills/cabloy-zova-source-reading/SKILL.md +221 -0
  15. package/.claude/skills/cabloy-zova-source-reading/references/analysis-modes.md +91 -0
  16. package/.claude/skills/cabloy-zova-source-reading/references/core-reading-paths.md +117 -0
  17. package/CHANGELOG.md +64 -0
  18. package/CLAUDE.md +11 -0
  19. package/cabloy-docs/.vitepress/config.mjs +197 -5
  20. package/cabloy-docs/ai/cli-to-skill-map.md +7 -0
  21. package/cabloy-docs/ai/docs-skills-rules-mapping.md +22 -0
  22. package/cabloy-docs/ai/future-skill-roadmap.md +12 -7
  23. package/cabloy-docs/ai/introduction.md +1 -0
  24. package/cabloy-docs/ai/playbook-backend-module.md +6 -0
  25. package/cabloy-docs/ai/playbook-module-removal.md +164 -0
  26. package/cabloy-docs/ai/skills.md +12 -0
  27. package/cabloy-docs/backend/backend-contract-emission-output-inspection.md +189 -0
  28. package/cabloy-docs/backend/backend-contract-emission-source-reading-map.md +160 -0
  29. package/cabloy-docs/backend/backend-contract-emission-specimen.md +170 -0
  30. package/cabloy-docs/backend/backend-resource-module-contract-chain.md +323 -0
  31. package/cabloy-docs/backend/backend-source-reading-debug-checklist.md +173 -0
  32. package/cabloy-docs/backend/backend-source-reading-roadmap.md +129 -0
  33. package/cabloy-docs/backend/backend-source-reading-verify-playbook.md +166 -0
  34. package/cabloy-docs/backend/bean-scene-authoring.md +4 -4
  35. package/cabloy-docs/backend/broadcast-guide.md +3 -3
  36. package/cabloy-docs/backend/cli.md +20 -11
  37. package/cabloy-docs/backend/config-guide.md +4 -4
  38. package/cabloy-docs/backend/controller-aop-guide.md +10 -10
  39. package/cabloy-docs/backend/controller-guide.md +12 -2
  40. package/cabloy-docs/backend/crud-workflow.md +7 -3
  41. package/cabloy-docs/backend/dto-guide.md +18 -2
  42. package/cabloy-docs/backend/dto-infer-generation.md +201 -25
  43. package/cabloy-docs/backend/election-guide.md +2 -2
  44. package/cabloy-docs/backend/entity-guide.md +30 -3
  45. package/cabloy-docs/backend/error-guide.md +3 -3
  46. package/cabloy-docs/backend/event-guide.md +4 -4
  47. package/cabloy-docs/backend/external-aop-guide.md +2 -2
  48. package/cabloy-docs/backend/field-indexes.md +9 -3
  49. package/cabloy-docs/backend/foundation.md +8 -8
  50. package/cabloy-docs/backend/i18n-guide.md +6 -6
  51. package/cabloy-docs/backend/internal-aop-guide.md +2 -2
  52. package/cabloy-docs/backend/introduction.md +15 -0
  53. package/cabloy-docs/backend/migration-and-changes.md +3 -3
  54. package/cabloy-docs/backend/model-guide.md +16 -6
  55. package/cabloy-docs/backend/openapi-guide.md +3 -0
  56. package/cabloy-docs/backend/queue-guide.md +3 -3
  57. package/cabloy-docs/backend/redlock-guide.md +2 -2
  58. package/cabloy-docs/backend/schedule-guide.md +2 -2
  59. package/cabloy-docs/backend/scripts.md +8 -0
  60. package/cabloy-docs/backend/serialization-guide.md +12 -2
  61. package/cabloy-docs/backend/service-guide.md +18 -9
  62. package/cabloy-docs/backend/startup-guide.md +5 -5
  63. package/cabloy-docs/backend/status-guide.md +271 -0
  64. package/cabloy-docs/backend/unit-testing.md +3 -3
  65. package/cabloy-docs/backend/vona-source-reading-map.md +157 -0
  66. package/cabloy-docs/backend/websocket-protocol-guide.md +5 -5
  67. package/cabloy-docs/backend/websocket-usage-guide.md +15 -8
  68. package/cabloy-docs/frontend/a-model-under-the-hood.md +281 -0
  69. package/cabloy-docs/frontend/a-openapi-under-the-hood.md +248 -0
  70. package/cabloy-docs/frontend/a-router-guide.md +307 -0
  71. package/cabloy-docs/frontend/api-guide.md +6 -4
  72. package/cabloy-docs/frontend/api-schema-guide.md +1 -0
  73. package/cabloy-docs/frontend/app-startup-guide.md +7 -4
  74. package/cabloy-docs/frontend/bean-scene-authoring.md +3 -1
  75. package/cabloy-docs/frontend/behavior-guide.md +16 -16
  76. package/cabloy-docs/frontend/cli.md +14 -2
  77. package/cabloy-docs/frontend/command-scene-authoring.md +504 -0
  78. package/cabloy-docs/frontend/component-guide.md +5 -5
  79. package/cabloy-docs/frontend/component-props-guide.md +1 -1
  80. package/cabloy-docs/frontend/component-v-model-guide.md +2 -2
  81. package/cabloy-docs/frontend/design-principles.md +6 -0
  82. package/cabloy-docs/frontend/fetch-interceptor-guide.md +440 -0
  83. package/cabloy-docs/frontend/filter-query-select-data-flow-guide.md +260 -0
  84. package/cabloy-docs/frontend/form-guide.md +786 -0
  85. package/cabloy-docs/frontend/form-scene-to-page-meta-guide.md +303 -0
  86. package/cabloy-docs/frontend/foundation.md +33 -0
  87. package/cabloy-docs/frontend/frontend-source-reading-roadmap.md +249 -0
  88. package/cabloy-docs/frontend/generated-contract-consumption-debug-checklist.md +190 -0
  89. package/cabloy-docs/frontend/generated-contract-consumption-entry-branch.md +205 -0
  90. package/cabloy-docs/frontend/generated-contract-consumption-list-branch.md +157 -0
  91. package/cabloy-docs/frontend/generated-contract-consumption-specimen.md +203 -0
  92. package/cabloy-docs/frontend/generated-contract-consumption-verify-playbook.md +189 -0
  93. package/cabloy-docs/frontend/generic-component-guide.md +1 -1
  94. package/cabloy-docs/frontend/introduction.md +38 -5
  95. package/cabloy-docs/frontend/ioc-and-beans.md +6 -0
  96. package/cabloy-docs/frontend/mock-guide.md +1 -0
  97. package/cabloy-docs/frontend/model-architecture.md +288 -39
  98. package/cabloy-docs/frontend/model-resource-best-practices.md +379 -0
  99. package/cabloy-docs/frontend/model-resource-cookbook.md +508 -0
  100. package/cabloy-docs/frontend/model-resource-internals-deep-dive.md +238 -0
  101. package/cabloy-docs/frontend/model-resource-owner-pattern.md +402 -0
  102. package/cabloy-docs/frontend/model-resource-usage-guide.md +334 -0
  103. package/cabloy-docs/frontend/model-state-guide.md +371 -15
  104. package/cabloy-docs/frontend/module-scope.md +8 -8
  105. package/cabloy-docs/frontend/modules-and-suites.md +2 -1
  106. package/cabloy-docs/frontend/navigation-guards-guide.md +7 -0
  107. package/cabloy-docs/frontend/openapi-sdk-guide.md +17 -6
  108. package/cabloy-docs/frontend/page-guide.md +15 -9
  109. package/cabloy-docs/frontend/page-meta-guide.md +466 -0
  110. package/cabloy-docs/frontend/page-params-guide.md +3 -3
  111. package/cabloy-docs/frontend/page-query-guide.md +2 -2
  112. package/cabloy-docs/frontend/page-route-guide.md +6 -0
  113. package/cabloy-docs/frontend/permission-formscene-action-visibility-guide.md +263 -0
  114. package/cabloy-docs/frontend/quickstart.md +18 -2
  115. package/cabloy-docs/frontend/reading-zova-for-vue-developers.md +266 -0
  116. package/cabloy-docs/frontend/resource-entry-page-deep-dive.md +271 -0
  117. package/cabloy-docs/frontend/resource-list-page-deep-dive.md +279 -0
  118. package/cabloy-docs/frontend/rest-resource-source-reading-map.md +522 -0
  119. package/cabloy-docs/frontend/rest-resource-under-the-hood.md +622 -0
  120. package/cabloy-docs/frontend/root-behaviors-guide.md +282 -0
  121. package/cabloy-docs/frontend/route-alias-guide.md +6 -0
  122. package/cabloy-docs/frontend/router-stack-guide.md +229 -0
  123. package/cabloy-docs/frontend/router-tabs-introduction.md +26 -3
  124. package/cabloy-docs/frontend/router-tabs-layout-integration.md +367 -0
  125. package/cabloy-docs/frontend/router-tabs-mechanism.md +6 -0
  126. package/cabloy-docs/frontend/router-tabs-route-meta-cookbook.md +7 -0
  127. package/cabloy-docs/frontend/router-tabs-vs-stack.md +167 -0
  128. package/cabloy-docs/frontend/router-view-hosts-guide.md +450 -0
  129. package/cabloy-docs/frontend/server-data.md +4 -1
  130. package/cabloy-docs/frontend/system-startup-guide.md +2 -2
  131. package/cabloy-docs/frontend/table-action-visibility-permission-flow-guide.md +263 -0
  132. package/cabloy-docs/frontend/table-cell-cookbook.md +568 -0
  133. package/cabloy-docs/frontend/table-guide.md +373 -0
  134. package/cabloy-docs/frontend/table-resource-crud-cookbook.md +496 -0
  135. package/cabloy-docs/frontend/zova-app-guide.md +251 -0
  136. package/cabloy-docs/frontend/zova-form-source-reading-map.md +293 -0
  137. package/cabloy-docs/frontend/zova-form-under-the-hood.md +561 -0
  138. package/cabloy-docs/frontend/zova-reactivity-under-the-hood.md +320 -0
  139. package/cabloy-docs/frontend/zova-router-under-the-hood.md +561 -0
  140. package/cabloy-docs/frontend/zova-source-reading-map.md +421 -0
  141. package/cabloy-docs/frontend/zova-table-controller-render-supplement.md +225 -0
  142. package/cabloy-docs/frontend/zova-table-source-reading-map.md +317 -0
  143. package/cabloy-docs/frontend/zova-table-under-the-hood.md +532 -0
  144. package/cabloy-docs/frontend/zova-vs-vue3-comparison.md +308 -0
  145. package/cabloy-docs/fullstack/backend-metadata-to-frontend-table-actions-debug-checklist.md +245 -0
  146. package/cabloy-docs/fullstack/backend-metadata-to-frontend-table-actions-source-reading-map.md +139 -0
  147. package/cabloy-docs/fullstack/backend-metadata-to-frontend-table-actions-verify-playbook.md +248 -0
  148. package/cabloy-docs/fullstack/backend-metadata-to-frontend-table-actions.md +511 -0
  149. package/cabloy-docs/fullstack/contract-loop-playbook.md +356 -0
  150. package/cabloy-docs/fullstack/edition-collaboration-differences.md +6 -0
  151. package/cabloy-docs/fullstack/frontend-metadata-to-backend.md +199 -23
  152. package/cabloy-docs/fullstack/introduction.md +15 -1
  153. package/cabloy-docs/fullstack/openapi-to-sdk.md +135 -11
  154. package/cabloy-docs/fullstack/suites-and-modules.md +333 -0
  155. package/cabloy-docs/fullstack/tutorial-1-first-module.md +3 -0
  156. package/cabloy-docs/fullstack/tutorial-2-first-crud.md +4 -0
  157. package/cabloy-docs/fullstack/tutorial-3-frontend-metadata-sharing.md +6 -2
  158. package/cabloy-docs/fullstack/tutorial-4-custom-level-renderers.md +60 -23
  159. package/cabloy-docs/fullstack/tutorial-5-backend-contract-sharing.md +14 -7
  160. package/cabloy-docs/fullstack/tutorial-6-one-contract-four-uses.md +6 -0
  161. package/cabloy-docs/fullstack/tutorials-overview.md +17 -4
  162. package/cabloy-docs/reference/bean-scene-boilerplates.md +15 -13
  163. package/cabloy-docs/reference/package-map.md +4 -3
  164. package/package.json +2 -1
  165. package/scripts/init.ts +2 -18
  166. package/scripts/initTestData.ts +25 -0
  167. package/scripts/upgrade.ts +17 -2
  168. package/vona/pnpm-lock.yaml +48 -194
  169. package/vona/src/suite/a-training/modules/training-student/package.json +53 -0
  170. package/vona/src/suite/a-training/modules/training-student/src/.metadata/index.ts +400 -0
  171. package/vona/src/suite/a-training/modules/training-student/src/.metadata/locales.ts +18 -0
  172. package/vona/src/suite/a-training/modules/training-student/src/.metadata/this.ts +2 -0
  173. package/vona/src/suite/a-training/modules/training-student/src/bean/meta.index.ts +12 -0
  174. package/vona/src/suite/a-training/modules/training-student/src/bean/meta.version.ts +21 -0
  175. package/vona/src/suite/a-training/modules/training-student/src/bean/ssrMenu.student.ts +29 -0
  176. package/vona/src/suite/a-training/modules/training-student/src/config/locale/en-us.ts +15 -0
  177. package/vona/src/suite/a-training/modules/training-student/src/config/locale/zh-cn.ts +15 -0
  178. package/vona/src/suite/a-training/modules/training-student/src/controller/student.ts +74 -0
  179. package/vona/src/suite/a-training/modules/training-student/src/dto/studentCreate.tsx +28 -0
  180. package/vona/src/suite/a-training/modules/training-student/src/dto/studentSelectReq.tsx +44 -0
  181. package/vona/src/suite/a-training/modules/training-student/src/dto/studentSelectRes.tsx +11 -0
  182. package/vona/src/suite/a-training/modules/training-student/src/dto/studentSelectResItem.tsx +45 -0
  183. package/vona/src/suite/a-training/modules/training-student/src/dto/studentSummary.tsx +42 -0
  184. package/vona/src/suite/a-training/modules/training-student/src/dto/studentUpdate.tsx +28 -0
  185. package/vona/src/suite/a-training/modules/training-student/src/dto/studentView.tsx +25 -0
  186. package/vona/src/suite/a-training/modules/training-student/src/entity/student.tsx +84 -0
  187. package/vona/src/suite/a-training/modules/training-student/src/index.ts +2 -0
  188. package/vona/src/suite/a-training/modules/training-student/src/model/student.ts +10 -0
  189. package/vona/src/suite/a-training/modules/training-student/src/service/student.ts +57 -0
  190. package/vona/src/suite/a-training/modules/training-student/test/student.test.ts +173 -0
  191. package/vona/src/suite/a-training/modules/training-student/tsconfig.build.json +11 -0
  192. package/vona/src/suite/a-training/modules/training-student/tsconfig.json +7 -0
  193. package/vona/src/suite/a-training/package.json +12 -0
  194. package/vona/src/suite/a-training/tsconfig.base.json +4 -0
  195. package/vona/src/suite/a-training/tsconfig.json +10 -0
  196. package/zova/packages-cli/cli/package.json +2 -2
  197. package/zova/packages-cli/cli-set-front/cli/templates/openapi/config/boilerplate/module/openapi.config.ts +6 -1
  198. package/zova/packages-cli/cli-set-front/package.json +1 -1
  199. package/zova/packages-cli/cli-set-front/src/lib/bean/cli.openapi.generate.ts +34 -4
  200. package/zova/packages-zova/zova/package.json +2 -2
  201. package/zova/pnpm-lock.yaml +416 -690
  202. package/zova/src/suite/a-training/modules/training-student/cli/openapi.config.ts +9 -0
  203. package/zova/src/suite/a-training/modules/training-student/package.json +52 -0
  204. package/zova/src/suite/a-training/modules/training-student/src/.metadata/component/formFieldLevel.ts +31 -0
  205. package/zova/src/suite/a-training/modules/training-student/src/.metadata/index.ts +258 -0
  206. package/zova/src/suite/a-training/modules/training-student/src/.metadata/locales.ts +7 -0
  207. package/zova/src/suite/a-training/modules/training-student/src/.metadata/this.ts +2 -0
  208. package/zova/src/suite/a-training/modules/training-student/src/api/openapi/baseURL.ts +5 -0
  209. package/zova/src/suite/a-training/modules/training-student/src/api/openapi/index.ts +3 -0
  210. package/zova/src/suite/a-training/modules/training-student/src/api/openapi/schemas.ts +196 -0
  211. package/zova/src/suite/a-training/modules/training-student/src/api/openapi/types.ts +4146 -0
  212. package/zova/src/suite/a-training/modules/training-student/src/api/trainingStudent.ts +151 -0
  213. package/zova/src/suite/a-training/modules/training-student/src/apiSchema/trainingStudent.ts +43 -0
  214. package/zova/src/suite/a-training/modules/training-student/src/bean/tableCell.actionDeleteForce.tsx +51 -0
  215. package/zova/src/suite/a-training/modules/training-student/src/bean/tableCell.actionSummary.tsx +56 -0
  216. package/zova/src/suite/a-training/modules/training-student/src/bean/tableCell.level.tsx +63 -0
  217. package/zova/src/suite/a-training/modules/training-student/src/component/formFieldLevel/controller.tsx +117 -0
  218. package/zova/src/suite/a-training/modules/training-student/src/config/locale/en-us.ts +9 -0
  219. package/zova/src/suite/a-training/modules/training-student/src/config/locale/zh-cn.ts +9 -0
  220. package/zova/src/suite/a-training/modules/training-student/src/index.ts +2 -0
  221. package/zova/src/suite/a-training/modules/training-student/src/model/student.ts +42 -0
  222. package/zova/src/suite/a-training/modules/training-student/tsconfig.build.json +13 -0
  223. package/zova/src/suite/a-training/modules/training-student/tsconfig.json +5 -0
  224. package/zova/src/suite/a-training/package.json +12 -0
  225. package/zova/src/suite/a-training/tsconfig.base.json +4 -0
  226. package/zova/src/suite/a-training/tsconfig.json +4 -0
  227. package/zova/src/suite/cabloy-basic/modules/basic-select/src/component/formFieldSelect/controller.tsx +29 -7
  228. package/zova/src/suite/cabloy-basic/modules/basic-select/src/component/select/controller.tsx +34 -11
  229. package/zova/src/suite-vendor/a-zova/modules/a-table/package.json +1 -1
  230. package/zova/src/suite-vendor/a-zova/modules/a-table/src/component/table/controller.tsx +3 -3
  231. package/zova/src/suite-vendor/a-zova/modules/a-table/src/lib/tableCell.ts +1 -1
  232. package/zova/src/suite-vendor/a-zova/package.json +2 -2
@@ -0,0 +1,373 @@
1
+ # Table Guide
2
+
3
+ This guide explains how to build tables in Zova with a practical path from the public authoring surface to the most common extension points.
4
+
5
+ Zova Table is not only a thin JSX wrapper around TanStack Table. It is a Zova-native table layer built around:
6
+
7
+ - controller-oriented frontend architecture
8
+ - schema-driven column metadata
9
+ - TanStack Table as the row-model engine under a controller-owned runtime
10
+ - `tableCell` bean-scene render resources
11
+ - resource-page integration through `basic-page:blockPage` and `basic-page:blockTable`
12
+
13
+ Use this page together with:
14
+
15
+ - [Component Guide](/frontend/component-guide)
16
+ - [API Schema Guide](/frontend/api-schema-guide)
17
+ - [Bean Scene Authoring](/frontend/bean-scene-authoring)
18
+ - [Model Resource Owner Pattern](/frontend/model-resource-owner-pattern)
19
+ - [TableCell Authoring Cookbook](/frontend/table-cell-cookbook)
20
+ - [Table + Resource CRUD Cookbook](/frontend/table-resource-crud-cookbook)
21
+ - [Zova Table Under the Hood](/frontend/zova-table-under-the-hood)
22
+ - [Zova Table Source Reading Map](/frontend/zova-table-source-reading-map)
23
+
24
+ > [!TIP]
25
+ > **Zova Table docs path**
26
+ >
27
+ > 1. **[Table Guide](/frontend/table-guide)** — learn the public authoring surface
28
+ > 2. **[Zova Table Under the Hood](/frontend/zova-table-under-the-hood)** — learn how the runtime pieces cooperate
29
+ > 3. **[Zova Table Source Reading Map](/frontend/zova-table-source-reading-map)** — learn which files to read next
30
+ >
31
+ > **Companion cookbooks**
32
+ >
33
+ > - **[TableCell Authoring Cookbook](/frontend/table-cell-cookbook)** — concrete custom-cell and row-action patterns
34
+ > - **[Table + Resource CRUD Cookbook](/frontend/table-resource-crud-cookbook)** — standard resource-page integration for filter, bulk actions, table, and pager
35
+ >
36
+ > **You are here:** step 1.
37
+ > **Next recommended page:** [Zova Table Under the Hood](/frontend/zova-table-under-the-hood).
38
+
39
+ If your next question is how these public APIs cooperate internally at runtime, continue with [Zova Table Under the Hood](/frontend/zova-table-under-the-hood).
40
+
41
+ ## What you should learn first
42
+
43
+ If you only remember one idea, remember this one:
44
+
45
+ > In Zova, a table is centered on a table controller bean, while schema metadata and `tableCell` render resources decide which columns exist, which cells are visible, and how each cell is rendered.
46
+
47
+ That leads to three common authoring surfaces:
48
+
49
+ - `ZTable` — the root table component
50
+ - schema `rest.table` metadata — the default source of visibility, order, and render decisions
51
+ - `tableCell` beans — the main extension surface for reusable cell rendering
52
+
53
+ ## One running example through this guide: Student list page
54
+
55
+ To keep the guide concrete, the examples below all use the same teaching resource:
56
+
57
+ - resource: `training-student:student`
58
+ - representative columns: `name`, `level`, `mobile`, and row operations
59
+ - common page shape: resource page with filter, table, and pager blocks
60
+
61
+ That Student thread is a good specimen because it grows through the same path most real business tables follow:
62
+
63
+ 1. resource-driven list page
64
+ 2. schema-driven default columns
65
+ 3. field metadata pointing to built-in table-cell renderers
66
+ 4. custom row-actions or business-specific cell beans only where needed
67
+
68
+ ## Step 1: Choose the right table style
69
+
70
+ Before writing code, choose which of these three styles matches your page.
71
+
72
+ ### Style A: schema-driven table
73
+
74
+ Use this when:
75
+
76
+ - the backend row schema already describes the list page well
77
+ - you want visible columns, order, and render metadata to come from schema-driven truth
78
+ - you want the shortest path to a working resource list page
79
+
80
+ ### Style B: mixed table with custom columns
81
+
82
+ Use this when:
83
+
84
+ - most columns can come from schema metadata
85
+ - one or two columns need page-local structure such as operations or combined display
86
+ - you want to keep the built-in table runtime but customize the column list through `getColumns(...)`
87
+
88
+ ### Style C: resource-driven page blocks
89
+
90
+ Use this when:
91
+
92
+ - the page is a standard resource list page
93
+ - filter, table, bulk toolbar, and pager should cooperate through the existing `basic-page` runtime
94
+ - permissions and schema refresh should be owned by the resource-page layer
95
+
96
+ A practical rule is:
97
+
98
+ - start with **resource-driven** for standard CRUD list pages
99
+ - use **schema-driven** when you want the smallest direct `ZTable` usage
100
+ - use **mixed** when one page needs custom columns without abandoning the built-in table runtime
101
+
102
+ ## Step 2: Start with the smallest useful table
103
+
104
+ The smallest useful Zova table is usually a direct `ZTable` with row data and a row schema:
105
+
106
+ ```tsx
107
+ <ZTable data={this.students} schema={this.schemaRow}></ZTable>
108
+ ```
109
+
110
+ That already gives you the default runtime shape:
111
+
112
+ - the wrapper creates a table controller bean
113
+ - the controller loads table-scene schema properties
114
+ - the controller converts those properties into TanStack columns
115
+ - each visible column renders through either text fallback or a `tableCell` render resource
116
+
117
+ A practical reading takeaway is:
118
+
119
+ - **the visible wrapper component is thin**
120
+ - **the controller bean is the real runtime owner**
121
+
122
+ ## Step 3: Let schema metadata drive the default columns
123
+
124
+ In the default path, `ZTable` reads table-scene metadata from the row schema.
125
+
126
+ The key table-facing metadata surface is the schema field `rest.table`, especially values such as:
127
+
128
+ - `order`
129
+ - `visible`
130
+ - `render`
131
+ - `columnProps`
132
+
133
+ A simplified mental model is:
134
+
135
+ ```text
136
+ schema row -> load table properties -> sort by order -> filter by visible -> build columns -> render cells
137
+ ```
138
+
139
+ That means the default list-page question becomes less:
140
+
141
+ - “which local column array should I hand-write first?”
142
+
143
+ and more:
144
+
145
+ - “which backend field metadata should own this column?”
146
+
147
+ This is why table work often belongs in the broader contract loop when the real source of truth is backend field metadata.
148
+
149
+ For the schema side of that contract, also see [API Schema Guide](/frontend/api-schema-guide).
150
+
151
+ ## Step 4: Use built-in or custom `tableCell` render resources
152
+
153
+ A column render is usually chosen through schema metadata such as:
154
+
155
+ ```typescript
156
+ render: 'basic-text:text';
157
+ ```
158
+
159
+ or another `tableCell` resource such as:
160
+
161
+ - `basic-date:date`
162
+ - `basic-select:select`
163
+ - `basic-table:actionOperationsRow`
164
+
165
+ These render resources are not ordinary page-local callbacks. They are Zova bean-scene resources registered under the `tableCell` scene.
166
+
167
+ That matters because the table runtime can then:
168
+
169
+ - resolve the render resource through the bean system
170
+ - merge decorator options with column props
171
+ - ask the bean whether the cell should be visible
172
+ - run render-time JSX/CEL evaluation in the correct table and cell scope
173
+
174
+ A practical rule is:
175
+
176
+ - use built-in `tableCell` resources first
177
+ - add a custom `tableCell` bean only when the business UI really needs module-owned rendering behavior
178
+
179
+ ## Step 5: Create a custom `tableCell` bean
180
+
181
+ When a built-in renderer is not enough, use the existing CLI-backed scene workflow.
182
+
183
+ Inspect the command first:
184
+
185
+ ```bash
186
+ npm run zova :create:bean --help
187
+ ```
188
+
189
+ Create a normal table-cell bean:
190
+
191
+ ```bash
192
+ npm run zova :create:bean tableCell level -- --module=training-student
193
+ ```
194
+
195
+ Create a row-actions variant:
196
+
197
+ ```bash
198
+ npm run zova :create:bean tableCell actionOperationsRow -- --module=training-student --boilerplate=tableActionRow
199
+ ```
200
+
201
+ The default generated shape is intentionally small:
202
+
203
+ ```tsx
204
+ @TableCell<ITableCellOptionsLevel>()
205
+ export class TableCellLevel extends BeanBase implements ITableCellRender {
206
+ render(
207
+ _options: ITableCellOptionsLevel,
208
+ _renderContext: IJsxRenderContextTableCell,
209
+ next: NextTableCellRender,
210
+ ) {
211
+ return next();
212
+ }
213
+ }
214
+ ```
215
+
216
+ That scaffold is useful because it starts from the correct Zova scene contract:
217
+
218
+ - the bean is marked with `@TableCell(...)`
219
+ - the bean participates in the `tableCell` scene
220
+ - the bean receives controller-prepared render context
221
+ - `next()` already represents the cell’s underlying value or children path
222
+
223
+ For the broader scene system behind this decorator, see [Bean Scene Authoring](/frontend/bean-scene-authoring).
224
+
225
+ ## Step 6: Add page-local custom columns with `getColumns(...)`
226
+
227
+ When most columns should stay schema-driven but one column should be page-local, use `getColumns(...)`.
228
+
229
+ A representative pattern is:
230
+
231
+ ```tsx
232
+ <ZTable
233
+ data={this.students}
234
+ schema={this.schemaRow}
235
+ getColumns={async (next, createColumnRender) => {
236
+ const columns = await next();
237
+ const operationsRender = await createColumnRender(
238
+ 'operations',
239
+ 'basic-table:actionOperationsRow',
240
+ );
241
+ if (operationsRender) {
242
+ columns.push({
243
+ id: 'operations',
244
+ header: () => 'Operations',
245
+ cell: props => operationsRender(props),
246
+ });
247
+ }
248
+ return columns;
249
+ }}
250
+ ></ZTable>
251
+ ```
252
+
253
+ The important design point is that `createColumnRender(...)` still routes through the table runtime.
254
+
255
+ That means your page-local column can still reuse:
256
+
257
+ - `tableCell` resource resolution
258
+ - column scope creation
259
+ - cell scope creation
260
+ - JSX/CEL evaluation
261
+ - `checkVisible(...)` handling
262
+
263
+ A practical caveat is:
264
+
265
+ - if the custom column key is not a real schema property, the render pipeline still works, but schema-derived property metadata for that key will be absent
266
+ - prefer a real schema-backed key when you want property-driven metadata such as `rest.table` behavior for that column
267
+
268
+ So a mixed table does **not** mean bypassing Zova. It means extending the existing runtime through its own hooks.
269
+
270
+ ## Step 7: Use resource-driven page blocks for CRUD list pages
271
+
272
+ For standard resource pages, the more common public surface is not direct `ZTable` usage. It is the block-based page runtime:
273
+
274
+ - `basic-page:blockPage`
275
+ - `basic-page:blockFilter`
276
+ - `basic-page:blockTable`
277
+ - `basic-page:blockPager`
278
+
279
+ In that path:
280
+
281
+ 1. the page block owns the resource model
282
+ 2. the page block loads row schema, permissions, and paged data
283
+ 3. the table block renders `ZTable`
284
+ 4. the table controller derives columns from the same row schema
285
+
286
+ This gives you a cohesive CRUD path where:
287
+
288
+ - filter and pager reuse the same page state
289
+ - table refresh can react to permission changes
290
+ - the page can keep a `tableRef` to the controller instance through `controllerRef`
291
+
292
+ For the resource ownership side of that page shape, see [Model Resource Owner Pattern](/frontend/model-resource-owner-pattern).
293
+
294
+ ## Step 8: Know when to use `BeanControllerPageTableBase`
295
+
296
+ If your table belongs directly to a page controller rather than a reusable component controller, the page-oriented base class already exists:
297
+
298
+ - `BeanControllerPageTableBase`
299
+
300
+ It provides the same `$useTable(...)` TanStack bridge as the component-oriented base while staying aligned with page-controller architecture.
301
+
302
+ A practical rule is:
303
+
304
+ - use `ZTable` and its built-in controller when you only need the reusable component surface
305
+ - evaluate `BeanControllerPageTableBase` when the table runtime truly belongs inside a page-controller-owned workflow
306
+
307
+ ## Common mistakes to avoid
308
+
309
+ ### Mistake 1: Treating `ZTable` as only a Vue wrapper around TanStack Table
310
+
311
+ TanStack Table is still important, but the business-facing runtime is controller-owned and schema-aware.
312
+
313
+ ### Mistake 2: Hand-writing every column before checking schema metadata
314
+
315
+ For many resource pages, the faster path is to let `rest.table` metadata describe the default columns first.
316
+
317
+ ### Mistake 3: Bypassing `tableCell` beans for reusable cell behavior
318
+
319
+ If a renderer should be shared across pages or modules, prefer a `tableCell` resource over repeated page-local callbacks.
320
+
321
+ ### Mistake 4: Treating `controllerRef` like a generic Vue DOM ref
322
+
323
+ `controllerRef` gives you the table controller instance, not a plain DOM element.
324
+
325
+ ### Mistake 5: Rebuilding CRUD list wiring manually when `basic-page` already owns it
326
+
327
+ For standard resource pages, prefer the existing block/page runtime before hand-building a custom table flow.
328
+
329
+ ## A practical authoring order
330
+
331
+ If you want the shortest accurate path to a real business table, use this order:
332
+
333
+ 1. make sure the backend row schema is already the right contract truth
334
+ 2. start with a resource page or direct `ZTable`
335
+ 3. let schema metadata drive the default columns
336
+ 4. reuse built-in `tableCell` renderers first
337
+ 5. add page-local `getColumns(...)` only where needed
338
+ 6. create custom `tableCell` beans only where the UI becomes business-specific
339
+ 7. continue with [TableCell Authoring Cookbook](/frontend/table-cell-cookbook) when you want concrete patterns for custom cell beans and row actions
340
+ 8. continue with [Table + Resource CRUD Cookbook](/frontend/table-resource-crud-cookbook) when you want the standard resource-page integration path for filter, bulk actions, table, and pager
341
+ 9. continue with [Zova Table Under the Hood](/frontend/zova-table-under-the-hood) when you want the runtime explanation behind the public authoring surface
342
+ 10. continue with [Zova Table Source Reading Map](/frontend/zova-table-source-reading-map) when you need framework-level source details and targeted file-order guidance
343
+
344
+ ## Verification checklist
345
+
346
+ When documenting or changing a table workflow, verify in this order:
347
+
348
+ 1. confirm the CLI command shape still exists:
349
+
350
+ ```bash
351
+ npm run zova :create:bean --help
352
+ ```
353
+
354
+ 2. confirm the `tableCell` scene metadata still exists in the current `a-table` module
355
+ 3. confirm the runtime claims against the current `a-table`, `basic-table`, and `basic-page` source
356
+ 4. if you changed docs, build the docs site:
357
+
358
+ ```bash
359
+ npm run docs:build
360
+ ```
361
+
362
+ ## Final takeaway
363
+
364
+ Zova Table is not only a column array plus JSX.
365
+
366
+ It moves table ownership into:
367
+
368
+ - table controller beans
369
+ - schema-driven column metadata
370
+ - `tableCell` bean-scene render resources
371
+ - resource-page integration
372
+
373
+ TanStack Table is still the underlying row-model engine, but the business-facing runtime model is Zova-native.