fix(stats): enforce latest source endpoint only for projected daily mileage

This commit is contained in:
lingniu
2026-07-08 14:41:53 +08:00
parent 5f79df3fe2
commit bc2071ef42
3 changed files with 22 additions and 2 deletions

View File

@@ -192,7 +192,7 @@ SELECT
s.latest_total_mileage_km,
s.source_key,
s.phone,
COALESCE(NULLIF(ds.latest_source_endpoint, ''), s.source_endpoint),
ds.latest_source_endpoint,
s.sample_count
FROM vehicle_daily_mileage_source s
LEFT JOIN vehicle_data_source ds