From ace587ac2f19271e6628f0f84d558f48914998e5 Mon Sep 17 00:00:00 2001 From: phl0 Date: Tue, 16 Sep 2025 20:49:11 +0200 Subject: [PATCH] Basics for LoTW confirmations of CNTY --- application/controllers/Lotw.php | 17 +++++ .../lotw_views/adif_views/adif_export.php | 63 +++++++++++++++++-- 2 files changed, 75 insertions(+), 5 deletions(-) diff --git a/application/controllers/Lotw.php b/application/controllers/Lotw.php index cb1155f19..774643827 100644 --- a/application/controllers/Lotw.php +++ b/application/controllers/Lotw.php @@ -1121,6 +1121,23 @@ class Lotw extends CI_Controller { endswitch; } + /* + | Function: lotw_ru_oblast_map + | Requires: russian oblast map $ru_oblast + */ + function lotw_ru_oblast_map($ru_oblast) { + switch ($ru_oblast): + case "YR": + return "JA"; + break; + case "YN": + return "JN"; + break; + default: + return $ru_oblast; + endswitch; + } + /* | Function: mode_map | Requires: mode as $mode, submode as $submode diff --git a/application/views/lotw_views/adif_views/adif_export.php b/application/views/lotw_views/adif_views/adif_export.php index 7be4e772e..179f1cd16 100644 --- a/application/views/lotw_views/adif_views/adif_export.php +++ b/application/views/lotw_views/adif_views/adif_export.php @@ -4,7 +4,7 @@ $clean_cert = trim($lotw_cert_info->cert); $cert1 = str_replace("-----BEGIN CERTIFICATE-----", "", $clean_cert); $cert2 = str_replace("-----END CERTIFICATE-----", "", $cert1); ?> -TQSL V2.5.4 Lib: V2.5 Config: V11.12 AllowDupes: false +TQSL V2.8.1 Lib: V2.6 Config: V11.34 AllowDupes: false tCERT 1 @@ -27,13 +27,66 @@ $cert2 = str_replace("-----END CERTIFICATE-----", "", $cert1); station_iota) { ?>station_iota); ?>>station_iota; } ?> -state != "" && $station_profile->station_country == "CANADA") { ?>lotw_ca_province_map($station_profile->state)); ?>>lotw_ca_province_map($station_profile->state); } ?> +cert_dxcc_id) { + case 6: // Alaska + case 110: // Hawaii + case 291: // Cont US + if($station_profile->state != "") { ?> +state); ?>>state; ?> -state != "" && $station_profile->station_country == "UNITED STATES OF AMERICA") { ?>state); ?>>state; } ?> +station_cnty != "") { ?> +station_cnty); ?>>station_cnty; ?> -state != "" && $station_profile->station_country == "CHINA") { ?>state); ?>>state; } ?> +state != "") { ?> +lotw_ca_province_map($station_profile->state)); ?>>lotw_ca_province_map($station_profile->state); ?> -station_cnty != "" && $station_profile->station_country == "UNITED STATES OF AMERICA") { ?>station_cnty); ?>>station_cnty; } ?> + state != "") { ?> +lotw_ru_oblast_map($station_profile->state)); ?>>lotw_ru_oblast_map($station_profile->state); ?> + + state != "") { ?> +state); ?>>state; ?> + + state != "") { ?> +state); ?>>state; ?> + + state != "") { ?> +state); ?>>state; ?> + +station_cnty != "") { ?> +station_cnty); ?>>station_cnty; ?> + +state != "") { ?> +state); ?>>state; ?> + +