Skip to content

[Due for payment 2026-05-13] [Odometer] Detect and retrieve odometer draft data on expense tab mount #87819

Description

@Julesssss

Connect IOURequestStepDistanceOdometer to Onyx draft data so saved drafts are restored on return.

Design doc section: https://docs.google.com/document/d/1Z103dY4guA07UUw3sTP1o0IKvFxXZJ1HAB1EwUeEyaA/edit?tab=t.0#bookmark=id.i2bfh6sbj48y

Implementation:

  • Subscribe to ONYXKEYS.ODOMETER_DRAFT via useOnyx()
  • On mount, check for existing draft and load into transaction state via IOU.setMoneyRequestOdometerReading() and IOU.setMoneyRequestOdometerImage()
  • Web/mWeb/Desktop: Convert base64 strings back to File objects using base64ToFile() from FileUtils.ts
  • iOS/Android: Use stored file path URIs directly
  • Pre-fill start/end reading inputs and display draft images using existing display logic

Reference: Odometer tracking issue — Release 2

Issue OwnerCurrent Issue Owner: @DylanDylann

Metadata

Metadata

Labels

EngineeringImprovementItem broken or needs improvement.InternalRequires API changes or must be handled by Expensify staffReviewingHas a PR in reviewWeeklyKSv2

Type

No type

Fields

No fields configured for issues without a type.

Projects

Status
Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions