Auto-include FK columns in lists
Auto-generated from the source archive. Do not edit by hand — rerun
catalyst-changelog-syncinstead.
What changed
Section titled “What changed”- For every many-to-one relationship,
<mod>.columns.tsnow emits a column withaccessorKey: '<rel>.name',relation: { association: '<rel>' }, and the standardsortable/searchable/filterable/exportableflags. Position follows the FK’s declaration order in the YAML. - The list-component imports
getRelationIncludesfrom@aurora, declares arelationIncludesfield, and passesincludein bothqueryandconstraintof thepaginate()call. The list resolver wires the same include for the first-page pre-load so the table renders without a flicker. - Search and filter on FK columns work without any extra codegen — the existing
buildSearchWhere/buildFilterWherehelpers translateboundedContext.nameto Sequelize$boundedContext.name$. Aggregates with no many-to-one FKs regenerate byte-identical.
Why it matters
Section titled “Why it matters”Before this, the list of an aggregate with FKs showed the local fields but hid the <rel>Id UUIDs — a permissions list did not display the bounded-context each row belonged to, which made it useless as an exploration tool. Devs wrote the FK column by hand and every regen produced a .origin to merge. The codegen now owns it end to end: column emission, resolver include for the first-page pre-load, list-component include for runtime paginate, and dot-path translation in search/filter. The label is hardcoded to the target’s name field; aggregates with composite labels ({code} - {name}) or without name are deferred to a follow-up.