Codegen Add WT Entity

Table of Contents

When to use this skill

When you need to add a Wt web UI for a new entity in ores.wt.service. Prerequisites: the domain type must exist (domain-type-creator) and the service layer for the entity must be implemented. See Entity lifecycle for the full layer ordering.

How to use this skill

  1. Gather requirements: entity name, service class, display fields, editable fields, primary key.
  2. Phase 1 — list widget (PR: [wt] Add {Entity} list widget): create {entity}_row struct and {entity}_list_widget class with toolbar, table, and signals.
  3. Phase 2 — detail dialog (PR: [wt] Add {Entity} dialog): create {entity}_dialog with form editors and save_requested signal.
  4. Phase 3 — application integration (PR: [wt] Integrate {Entity} into application): add page/controller, connect signals, register in navigation.

Use feature-branch-manager between phases and pr-manager to open each PR. Build after every step: cmake --build --preset linux-clang-debug-ninja --target ores.wt.service.lib.

Recipes

Reference

Codegen gap

❌ No codegen profile exists for ores.wt.service. Do not hand-code this layer. When entity-creator reaches this layer:

  1. Raise a sprint story: "Implement codegen profile for Wt UI."
  2. Reference Entity lifecycle§"Codegen gaps" for what the profile must cover.
  3. Link the story to the entity task before marking this layer done.
  4. Once the profile is merged, regenerate and discard any hand-written code.

Until the gap is resolved, this layer is incomplete.

Emacs 29.1 (Org mode 9.6.6)