fix: Vehicle summary screen does not display maintenance records #239

Closed
opened 2026-05-13 01:28:38 +00:00 by egullickson · 0 comments
Owner

Summary

The Vehicle Records section on the vehicle summary screen renders empty — no maintenance records appear for the vehicle, even when records exist for that vehicle in the maintenance feature.

Environment

  • Environment: staging (https://staging.motovaultpro.com)
  • Affected page: https://staging.motovaultpro.com/garage/vehicles/01caf9e8-2b9a-4f24-959f-67a3e6bd91b1
  • Records confirmed to exist at: https://staging.motovaultpro.com/garage/maintenance

Steps to Reproduce

  1. Sign in to staging.
  2. Navigate to /garage/maintenance — confirm one or more maintenance records exist (some are for vehicle 01caf9e8-2b9a-4f24-959f-67a3e6bd91b1).
  3. Navigate to /garage/vehicles/01caf9e8-2b9a-4f24-959f-67a3e6bd91b1.
  4. Scroll to the Vehicle Records / Maintenance Records section on the summary screen.

Actual Behavior

  • The Vehicle Records section renders with its heading, but the body shows no records (empty state).
  • Records for this vehicle are clearly present on the standalone /garage/maintenance page.

Expected Behavior

  • All maintenance records associated with the vehicle should display under the Vehicle Records section on the vehicle summary screen.
  • Section should match the data returned by the maintenance feature when filtered by the current vehicleId.

Severity / Impact

  • Medium. The vehicle summary surface is the primary navigation context for a vehicle, but records remain accessible via /garage/maintenance as a workaround.

Likely Investigation Areas

  • Vehicle summary page component — verify the maintenance records query/hook is being called with the correct vehicleId parameter.
  • Backend maintenance endpoint — verify the by-vehicle filter (?vehicleId=... or path param) returns rows when given this vehicle's UUID.
  • Repository mapRow() — confirm snake_case → camelCase mapping is intact and not dropping records due to a field mismatch.
  • Frontend rendering — confirm the empty-state branch is not triggered by a missing/incorrect response shape (e.g. data vs data.items).
  • Network tab on the affected page: capture the actual request URL, status, and response payload.

Acceptance Criteria

  • Maintenance records for the active vehicle render in the Vehicle Records section on the summary screen on both mobile and desktop viewports.
  • Empty state only renders when the vehicle truly has zero maintenance records.
  • Section is consistent with the data shown on /garage/maintenance filtered by the same vehicle.
  • No console errors or failed network requests on page load.
  • Linting, type-check, and tests pass.

Notes

  • Repository pattern: ensure any new query uses mapRow() for case conversion per CLAUDE.md.
  • Mobile + Desktop: feature must be verified on both viewports before closing.
## Summary The Vehicle Records section on the vehicle summary screen renders empty — no maintenance records appear for the vehicle, even when records exist for that vehicle in the maintenance feature. ## Environment - Environment: staging (`https://staging.motovaultpro.com`) - Affected page: `https://staging.motovaultpro.com/garage/vehicles/01caf9e8-2b9a-4f24-959f-67a3e6bd91b1` - Records confirmed to exist at: `https://staging.motovaultpro.com/garage/maintenance` ## Steps to Reproduce 1. Sign in to staging. 2. Navigate to `/garage/maintenance` — confirm one or more maintenance records exist (some are for vehicle `01caf9e8-2b9a-4f24-959f-67a3e6bd91b1`). 3. Navigate to `/garage/vehicles/01caf9e8-2b9a-4f24-959f-67a3e6bd91b1`. 4. Scroll to the Vehicle Records / Maintenance Records section on the summary screen. ## Actual Behavior - The Vehicle Records section renders with its heading, but the body shows no records (empty state). - Records for this vehicle are clearly present on the standalone `/garage/maintenance` page. ## Expected Behavior - All maintenance records associated with the vehicle should display under the Vehicle Records section on the vehicle summary screen. - Section should match the data returned by the maintenance feature when filtered by the current `vehicleId`. ## Severity / Impact - Medium. The vehicle summary surface is the primary navigation context for a vehicle, but records remain accessible via `/garage/maintenance` as a workaround. ## Likely Investigation Areas - Vehicle summary page component — verify the maintenance records query/hook is being called with the correct `vehicleId` parameter. - Backend maintenance endpoint — verify the by-vehicle filter (`?vehicleId=...` or path param) returns rows when given this vehicle's UUID. - Repository `mapRow()` — confirm snake_case → camelCase mapping is intact and not dropping records due to a field mismatch. - Frontend rendering — confirm the empty-state branch is not triggered by a missing/incorrect response shape (e.g. `data` vs `data.items`). - Network tab on the affected page: capture the actual request URL, status, and response payload. ## Acceptance Criteria - [ ] Maintenance records for the active vehicle render in the Vehicle Records section on the summary screen on both mobile and desktop viewports. - [ ] Empty state only renders when the vehicle truly has zero maintenance records. - [ ] Section is consistent with the data shown on `/garage/maintenance` filtered by the same vehicle. - [ ] No console errors or failed network requests on page load. - [ ] Linting, type-check, and tests pass. ## Notes - Repository pattern: ensure any new query uses `mapRow()` for case conversion per `CLAUDE.md`. - Mobile + Desktop: feature must be verified on both viewports before closing.
egullickson added the
status
in-progress
type
bug
labels 2026-05-13 01:28:41 +00:00
egullickson added this to the Sprint 2026-02-02 milestone 2026-05-13 01:28:42 +00:00
egullickson removed this from the Sprint 2026-02-02 milestone 2026-05-13 01:30:01 +00:00
egullickson added
status
review
and removed
status
in-progress
labels 2026-05-16 01:46:11 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: egullickson/motovaultpro#239