Expense Rules Riverpod Provider
Component Detail
Service Layer
low complexity
mobile
0
Dependencies
0
Dependents
1
Entities
0
Integrations
Description
Riverpod provider that exposes organisation-specific reimbursement rules including per-kilometre rates, auto-approval distance thresholds, receipt requirement thresholds, and available expense types. Fetches rules from Supabase and caches them for the session.
expense-rules-provider
Responsibilities
- Fetch and cache organisation-specific reimbursement rules from Supabase
- Expose per-kilometre rate for mileage calculation
- Provide auto-approval threshold (distance and amount) for validation logic
- Supply receipt requirement threshold and available expense type configurations
Interfaces
watchOrgRules(orgId)
getPerKmRate(orgId)
getAutoApprovalThreshold(orgId)
getReceiptRequiredThreshold(orgId)
refreshRules(orgId)
getExpenseTypes(orgId)