feat(platform): expose multi-source vehicle evidence

This commit is contained in:
lingniu
2026-07-16 16:35:04 +08:00
parent 196cfa018f
commit 17c4591040
21 changed files with 1129 additions and 11 deletions

View File

@@ -903,6 +903,69 @@ type VehicleSourceConsistency struct {
Detail string `json:"detail"`
}
type VehicleSourceEvidence struct {
VIN string `json:"vin"`
Plate string `json:"plate"`
MileageDate string `json:"mileageDate"`
RecommendedLocationProtocol string `json:"recommendedLocationProtocol"`
RecommendedLocationLabel string `json:"recommendedLocationLabel"`
LocationConflict bool `json:"locationConflict"`
ConflictDistanceM *float64 `json:"conflictDistanceM,omitempty"`
LocationSources []VehicleLocationSourceEvidence `json:"locationSources"`
MileageSources []VehicleMileageSourceEvidence `json:"mileageSources"`
Comparison VehicleSourceEvidenceComparison `json:"comparison"`
AsOf string `json:"asOf"`
}
type VehicleLocationSourceEvidence struct {
Protocol string `json:"protocol"`
SourceLabel string `json:"sourceLabel"`
TerminalLabel string `json:"terminalLabel"`
SourceKind string `json:"sourceKind"`
SelectedWithinProtocol bool `json:"selectedWithinProtocol"`
Recommended bool `json:"recommended"`
Enabled bool `json:"enabled"`
Priority int `json:"priority"`
Online bool `json:"online"`
QualityStatus string `json:"qualityStatus"`
QualityReason string `json:"qualityReason"`
Longitude *float64 `json:"longitude,omitempty"`
Latitude *float64 `json:"latitude,omitempty"`
SpeedKmh *float64 `json:"speedKmh,omitempty"`
TotalMileageKm *float64 `json:"totalMileageKm,omitempty"`
SOCPercent *float64 `json:"socPercent,omitempty"`
EventTime string `json:"eventTime"`
ReceivedAt string `json:"receivedAt"`
sourceKey string
}
type VehicleMileageSourceEvidence struct {
Protocol string `json:"protocol"`
SourceLabel string `json:"sourceLabel"`
TerminalLabel string `json:"terminalLabel"`
SourceKind string `json:"sourceKind"`
SelectedWithinProtocol bool `json:"selectedWithinProtocol"`
Recommended bool `json:"recommended"`
Enabled bool `json:"enabled"`
Priority int `json:"priority"`
QualityStatus string `json:"qualityStatus"`
QualityReason string `json:"qualityReason"`
FirstTotalMileageKm *float64 `json:"firstTotalMileageKm,omitempty"`
LatestTotalMileageKm *float64 `json:"latestTotalMileageKm,omitempty"`
DailyMileageKm *float64 `json:"dailyMileageKm,omitempty"`
SampleCount int64 `json:"sampleCount"`
FirstEventTime string `json:"firstEventTime"`
LatestEventTime string `json:"latestEventTime"`
sourceKey string
}
type VehicleSourceEvidenceComparison struct {
LocationMaxDistanceM float64 `json:"locationMaxDistanceM"`
TotalMileageDeltaKm float64 `json:"totalMileageDeltaKm"`
DailyMileageDeltaKm float64 `json:"dailyMileageDeltaKm"`
ReportTimeDeltaSeconds float64 `json:"reportTimeDeltaSeconds"`
}
type VehicleServiceOverview struct {
VIN string `json:"vin"`
Plate string `json:"plate"`