Skip to content

fix: the asset link picker searches like the catalog and only offers the types the field accepts - #88

Merged
mjanez merged 1 commit into
dgufrom
fix/asset-link-search
Oct 9, 2026
Merged

mjanez merged 1 commit into
dgufrom
fix/asset-link-search

Conversation

@mjanez

@mjanez mjanez commented Oct 9, 2026

Copy link
Copy Markdown
Member

Picking the target of a link field (control: asset) used GET /assets/search, a different search from the one in the header: typing «área de gobierno 2» returned anything with «gobierno» in it and not the area, because it neither folds accents nor ranks by name, and it ignored the field's targetAssetTypes.

  • findAssets now asks GET /search?types=asset, the catalog search, and resolves the hits through /assets/refs.
  • The picker passes the field's targetAssetTypes as governed.asset_type, so «Parent area» only offers lines of business.

Prettier and ESLint pass. Not exercised in a browser against a real catalog.

@mjanez
mjanez merged commit a0880ef into dgu Oct 9, 2026
5 checks passed
@mjanez
mjanez deleted the fix/asset-link-search branch October 9, 2026 07:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant