fix(web): harden route transitions and monitor memory

This commit is contained in:
lingniu
2026-07-15 23:54:21 +08:00
parent 3fabcf181a
commit c29ccdf2da
17 changed files with 332 additions and 36 deletions

View File

@@ -192,7 +192,7 @@ export function Mileage({
const summaryItems = [
{ label: '区间总里程', value: `${formatKm(statistics?.periodMileageKm)} km`, note: '按车辆和自然日归并' },
{ label: '统计车辆', value: statistics ? `${statistics.vehicleCount.toLocaleString()}` : '—', note: `${statistics?.recordCount ?? 0} 个有效车辆日` },
{ label: '统计车辆', value: statistics ? `${(statistics.vehicleCount ?? 0).toLocaleString()}` : '—', note: `${statistics?.recordCount ?? 0} 个有效车辆日` },
{ label: '单车平均', value: `${formatKm(statistics?.averageMileagePerVin)} km`, note: '区间总里程 / 车辆数' },
{ label: '车日均里程', value: `${formatKm(statistics?.averageDailyMileageKm)} km`, note: '有效车辆日平均' }
];
@@ -262,7 +262,7 @@ export function Mileage({
title={(
<div className="vp-mileage-report-card-title">
<div><strong></strong><span>{filters.dateFrom} {filters.dateTo}</span></div>
<Tag color="blue">{statistics?.trend.length ?? 0} </Tag>
<Tag color="blue">{statistics?.trend?.length ?? 0} </Tag>
</div>
)}
>