Skip to content

fix: route procest API calls through generateUrl() (work without mod_rewrite)#425

Merged
rubenvdlinde merged 1 commit into
developmentfrom
chore/procest-api-url-fix
May 12, 2026
Merged

fix: route procest API calls through generateUrl() (work without mod_rewrite)#425
rubenvdlinde merged 1 commit into
developmentfrom
chore/procest-api-url-fix

Conversation

@rubenvdlinde
Copy link
Copy Markdown
Contributor

Several frontend fetch() calls hardcode /apps/procest/api/.... That works behind Apache + mod_rewrite, but in a bare php -S environment (including the CI E2E job) those paths aren't routable and 404.

Most visibly: the settings store's /api/settings fetch 404s in CI, so the dashboard widgets never get configured (all 11 render "Widget not available", and the dashboard header <h2> + action buttons don't render), and CnFormDialog opens with an empty form on the Cases page. Confirmed from the Playwright trace (404 GET http://localhost:8080/apps/procest/api/settings).

Fix: wrap the URLs in generateUrl(), matching the other API services (aiApi.js, parafeerRouteApi.js, etc.):

  • store/modules/settings.js/api/settings
  • store/modules/zgwMapping.js/api/zgw-mappings[...]
  • views/settings/AdminRoot.vue/api/settings/load
  • views/voorstellen/VoorstelList.vue/api/notifications/parafering-reminder

Should fix the 2 remaining E2E failures (Dashboard › shows heading and action buttons, Cases page › new case modal has correct fields).

…ut mod_rewrite

Several frontend fetches hardcoded /apps/procest/api/... — fine behind
Apache+rewrite, but in a bare 'php -S' env (incl. the CI E2E job) that path
isn't routable and 404s. Most visibly: the settings store's /api/settings
fetch fails in CI, so the dashboard widgets never get configured (all show
'Widget not available') and CnFormDialog opens with an empty form. Wrap the
URLs in generateUrl() like the other API services already do:
- store/modules/settings.js  (/api/settings)
- store/modules/zgwMapping.js (/api/zgw-mappings[...])
- views/settings/AdminRoot.vue (/api/settings/load)
- views/voorstellen/VoorstelList.vue (/api/notifications/parafering-reminder)
@rubenvdlinde rubenvdlinde merged commit a911aa3 into development May 12, 2026
15 checks passed
@rubenvdlinde rubenvdlinde deleted the chore/procest-api-url-fix branch May 12, 2026 17:07
@github-actions
Copy link
Copy Markdown
Contributor

Quality Report — ConductionNL/procest @ a4501f8

Check PHP Vue Security License Tests
lint
phpcs
phpmd
psalm
phpstan
phpmetrics
eslint
stylelint
composer ✅ 100/100
npm ✅ 419/419
PHPUnit
Newman ⏭️
Playwright

Coverage: 0% (0/81 statements)

Spec coverage: 5% (21 tests / 456 specs)


Quality workflow — 2026-05-12 17:15 UTC

Download the full PDF report from the workflow artifacts.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant