fix: resolve jt808 phone without leading zero
This commit is contained in:
@@ -105,6 +105,9 @@ func CandidateKeys(env envelope.FrameEnvelope) []CandidateKey {
|
||||
out = append(out, CandidateKey{Column: column, Value: value})
|
||||
}
|
||||
add("phone", env.Phone)
|
||||
if trimmed := strings.TrimLeft(strings.TrimSpace(env.Phone), "0"); trimmed != "" {
|
||||
add("phone", trimmed)
|
||||
}
|
||||
add("device_id", env.DeviceID)
|
||||
add("plate", env.Plate)
|
||||
add("vin", env.VehicleKeyHint)
|
||||
|
||||
Reference in New Issue
Block a user