[M1] Trip Form Workflow & Minimal Draft Ergonomics #3

Closed
opened 2026-09-04 14:59:11 +02:00 by JackPrince · 0 comments
Owner

Part of Epic #2

Description

Streamline the trip entry form by removing premature confirmation constraints and enabling minimal drafts as supported by the backend.

Tasks

  • Change default trip status in tripFormModel.ts and TripsPage.tsx from 'confirmed' to 'draft'.
  • Remove automatic plusOneHourInput() end-time injection in TripFormCard.tsx.
  • Relax HTML5 required attribute on odometer_end (allow empty end-km when saving a draft).
  • Split action buttons into "Save Draft" (active with minimal fields) and "Check & Confirm" (active only when complete).
  • Correct info dialog copy: confirmed trips remain editable with an audit reason until the period is locked.
  • Update Vitest unit tests in tripFormModel.test.ts.

Acceptance Criteria

  • A driver can save a draft providing only vehicle, start time, and start odometer.
  • The form no longer guesses an end time (+1 hour).
Part of Epic #2 ## Description Streamline the trip entry form by removing premature confirmation constraints and enabling minimal drafts as supported by the backend. ## Tasks - [x] Change default trip status in `tripFormModel.ts` and `TripsPage.tsx` from `'confirmed'` to `'draft'`. - [x] Remove automatic `plusOneHourInput()` end-time injection in `TripFormCard.tsx`. - [x] Relax HTML5 `required` attribute on `odometer_end` (allow empty end-km when saving a draft). - [x] Split action buttons into *"Save Draft"* (active with minimal fields) and *"Check & Confirm"* (active only when complete). - [x] Correct info dialog copy: confirmed trips remain editable with an audit reason until the period is locked. - [x] Update Vitest unit tests in `tripFormModel.test.ts`. ## Acceptance Criteria - A driver can save a draft providing only vehicle, start time, and start odometer. - The form no longer guesses an end time (`+1 hour`).
Sign in to join this conversation.
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
JackPrince/GoBDLogBook#3
No description provided.