1
0
Fork 0
fahrPool/web/app
Jonny 6677679eb9 fix: use onSubmit instead of form action to prevent field reset on error, rename ActionResult type
Finding 1: React 19's native <form action={fn}> resets uncontrolled
fields once fn resolves without throwing, regardless of an app-level
{success:false} result. Since handleSubmit never throws, every failed
submit (e.g. duplicate Kennzeichen) silently wiped user edits. Switched
all four Standorte/Fahrzeuge inline-edit and create forms to a plain
onSubmit handler that calls event.preventDefault() and builds FormData
from the submitted element manually, sidestepping React's action-reset
machinery.

Finding 2: web/app/standorte/actions.ts and web/app/fahrzeuge/actions.ts
each declared their own MutationResult type shadowing the differently
shaped MutationResult exported from lib/orte-fahrzeuge/mutations.ts.
Renamed the local type to ActionResult in both files to remove the
name collision.
2026-08-17 16:08:19 +02:00
..
auftraege feat: add inline Fahrzeug quick-add to Auftrag-anlegen page 2026-07-07 09:39:38 +02:00
dashboard feat: wire Kanban board into the dashboard page 2026-07-08 08:21:13 +02:00
fahrzeuge fix: use onSubmit instead of form action to prevent field reset on error, rename ActionResult type 2026-08-17 16:08:19 +02:00
login fix: resolve nested <main> landmarks, nav touch targets, focus consistency 2026-07-06 13:17:51 +02:00
nutzerverwaltung feat: add Nutzerverwaltung page 2026-07-15 11:43:26 +02:00
standorte fix: use onSubmit instead of form action to prevent field reset on error, rename ActionResult type 2026-08-17 16:08:19 +02:00
zeiterfassung fix: unify Zeiterfassung timezone display and add DB guard against double clock-in 2026-07-14 10:27:50 +02:00
favicon.ico chore: scaffold Next.js app with Vitest 2026-07-04 10:58:26 +02:00
globals.css fix: remove unspecified .color-palette utility from globals.css 2026-07-06 11:29:03 +02:00
layout.tsx feat: add mobile drawer navigation and restyle header 2026-07-06 11:54:02 +02:00
page.tsx feat: add root layout, role-based navigation and dashboard 2026-07-04 16:14:53 +02:00