Submit a Mileage Reimbursement Claim for a Peer Support Visit
Peer mentors frequently travel to meet contacts and need a quick, frictionless way to log mileage claims. The form should pre-fill today's date, allow entry of from/to route or direct distance in kilometers, and instantly display the calculated reimbursement amount based on the organization's current rate. The workflow must minimize cognitive load — defaulting to the most common scenario (single-leg trip, no receipt required under 50 km) — while still supporting more complex cases. Auto-approval must trigger silently when the claim is below the configured threshold.
User Story
Acceptance Criteria
- Given I open the mileage entry form, When the form loads, Then today's date is pre-filled and the distance field is focused
- Given I enter a from-address and a to-address in the route input fields, When both fields are populated, Then the system attempts to prefill the distance using the distance prefill service and displays an estimated km value
- Given I have entered or confirmed a distance in kilometers, When I view the reimbursement display, Then the calculated reimbursement amount updates in real time based on the organization's configured rate per km
- Given my claim is below the organization's auto-approval threshold (e.g., under 50 km with no additional expenses), When I submit the claim, Then the claim is automatically approved without requiring coordinator review and I receive a confirmation
- Given my claim exceeds the auto-approval threshold, When I submit the claim, Then the claim is placed in the coordinator's attestation queue and I am informed that it is pending review
- Given I submit the form, When the submission succeeds, Then the claim is persisted to the mileage claim repository and the claim status badge reflects the correct state (auto-approved or pending)
- Given I am offline when submitting, When connectivity is restored, Then the claim is synced via the Supabase mileage adapter without data loss
Business Value
Mileage reimbursement is a primary financial touchpoint for peer mentors — uncompensated travel is a leading reason volunteers disengage. Automating calculation and approval for common low-value claims removes the single largest friction point in the reimbursement cycle, reduces coordinator workload, and directly supports volunteer retention across all participating organizations (HLF and Blindeforbundet explicitly prioritize this in Phase 2).
Components
- Mileage Entry Form ui
- Real-Time Reimbursement Display Widget ui
- Route Input Fields Widget ui
- Distance Input Field Widget ui
- Mileage Claim Service service
- Auto-Approval Threshold Evaluator service
- Mileage Reimbursement Calculation Service service
- Distance Prefill Service service
- Mileage Claim Repository data
- Organisation Rate Configuration Repository data
- Supabase Mileage Adapter infrastructure
- Local Distance Cache infrastructure
- Expense Registration Screen ui
- Expense Form BLoC service
- Expense Validation Service service
- Expense Submission Service service