You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Page renderer: rows of an index page without register and schema link to an unrelated detail page #2192
On an index page that has no register and schema of its own (a named source such as search or endpoint), every row links to the first detail page that also has no register and schema, whatever the rows are. In Dossiq that is the task page, so clicking a result on the search page opens /tasks/cases:<id> and shows "Not found". Found while comparing Dossiq's search page with the design board DqZoekresultaten, where a result opens the case, object or document it names.
The case opens: the search source gives each result its own address (href, here /apps/dossiq/cases/{id} from the page's kinds config) and rowTarget returns it.
Actual behaviour
The browser goes to /index.php/apps/dossiq/tasks/cases:cb15428e-fd19-4638-9042-76683ef4f89a?_from=SearchResults&q=Kerkstraat, the task page asks GET /apps/openregister/api/flow-tasks/cases%3A… (404) and shows "Not found. This item does not exist or has been deleted." The row's link (a.cn-table-row__link) carries that same address, so opening it in a new tab fails the same way.
Dossiq's Postvak page shows the same thing: its row links to /apps/dossiq/tasks/<id>, and that id is no task either (the flow-task endpoint answers 404).
Cause
src/components/CnPageRenderer/CnPageRenderer.vue:
:1050-1066detailPageByRegisterSchema indexes detail pages by `${cfg.register} ${cfg.schema}`. A detail page without either (Dossiq's TaskDetail, entitySource: "tasks") is stored under "undefined undefined".
:1391 an index page without register and schema builds the same key, finds that page, and so sets rowClickToView and viewTo.
:2083rowOpenTarget then takes that detail page as the row's target, before the named source's own rowTarget / openRow get a say.
Every named-source index page in an app that also has a schema-less detail page is affected. A fix could skip the lookup when the index page has no register or schema, so the source's own rowTarget / openRow / detailRoute decide.
Acceptance criteria
On Dossiq's search page, a case result's title link and row click open /apps/dossiq/cases/{id}
Dossiq's Postvak rows no longer link to the task page
An index page with register and schema still opens its matching detail page
A test covers an index page without register and schema next to a schema-less detail page
Activity