From bca4087f69d96df82eea4e149727f8888d910b3f Mon Sep 17 00:00:00 2001 From: phl0 Date: Tue, 17 Jun 2025 16:06:03 +0200 Subject: [PATCH] Show error message in case ant el is (too) negative --- application/views/qso/index.php | 3 ++- assets/js/sections/qso.js | 9 +++++++++ 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/application/views/qso/index.php b/application/views/qso/index.php index a823e10fa..2e6a4c794 100644 --- a/application/views/qso/index.php +++ b/application/views/qso/index.php @@ -10,6 +10,7 @@ var lang_dxccsummary_for = ""; var lang_lotw_upload_day_ago = ""; var lang_lotw_upload_days_ago = ""; // due to the way the string is built (PHP to JS), %x is replaced with the number of days + var lang_invalid_ant_el = ""; var latlng=[]; @@ -604,7 +605,7 @@
- +
diff --git a/assets/js/sections/qso.js b/assets/js/sections/qso.js index da669ad75..e2a438171 100644 --- a/assets/js/sections/qso.js +++ b/assets/js/sections/qso.js @@ -97,6 +97,15 @@ function set_timers() { }, 100); } +function invalidAntEl() { + var saveQsoButtonText = $("#saveQso").html(); + $("#noticer").removeClass(""); + $("#noticer").addClass("alert alert-warning"); + $("#noticer").html(lang_invalid_ant_el+" "+parseFloat($("#ant_el").val()).toFixed(1)); + $("#noticer").show(); + $("#saveQso").html(saveQsoButtonText).prop("disabled", false); +} + $("#qso_input").off('submit').on('submit', function (e) { var _submit = true; if ((typeof qso_manual !== "undefined") && (qso_manual == "1")) {