fix: normalization of city name address
This commit is contained in:
@@ -788,10 +788,30 @@ func (a *App) applyStationDefaults(q *qso.QSO) {
|
||||
v := *p.TxPower
|
||||
q.TXPower = &v
|
||||
}
|
||||
// Resolve my zones / lat / lon via cty.dat using the profile's
|
||||
// callsign. The profile only stores the human-friendly fields
|
||||
// (callsign, grid, country name); cty.dat fills the structured
|
||||
// DXCC metadata that the ADIF spec wants for every QSO.
|
||||
// Profile-stored MY_* DXCC metadata wins (the user can override the
|
||||
// auto-filled values in Station Information).
|
||||
if q.MyDXCC == nil && p.MyDXCC != nil {
|
||||
v := *p.MyDXCC
|
||||
q.MyDXCC = &v
|
||||
}
|
||||
if q.MyCQZone == nil && p.MyCQZone != nil {
|
||||
v := *p.MyCQZone
|
||||
q.MyCQZone = &v
|
||||
}
|
||||
if q.MyITUZone == nil && p.MyITUZone != nil {
|
||||
v := *p.MyITUZone
|
||||
q.MyITUZone = &v
|
||||
}
|
||||
if q.MyLat == nil && p.MyLat != nil {
|
||||
v := *p.MyLat
|
||||
q.MyLat = &v
|
||||
}
|
||||
if q.MyLon == nil && p.MyLon != nil {
|
||||
v := *p.MyLon
|
||||
q.MyLon = &v
|
||||
}
|
||||
// Resolve any still-missing my zones / lat / lon via cty.dat using the
|
||||
// profile's callsign — the fallback when the profile didn't store them.
|
||||
if a.dxcc != nil && p.Callsign != "" {
|
||||
if m, ok := a.dxcc.Lookup(p.Callsign); ok && m.Entity != nil {
|
||||
if q.MyCQZone == nil && m.CQZone != 0 {
|
||||
|
||||
Reference in New Issue
Block a user