From 69457ca83927d6ea22e39b6c759a6e11bd61d6d4 Mon Sep 17 00:00:00 2001 From: Peter Goodhall Date: Wed, 22 May 2024 13:36:37 +0100 Subject: [PATCH] [Station Locations] Added Aland Is States --- application/views/station_profile/edit.php | 28 +++++++++++++++++++++- assets/js/sections/station_locations.js | 12 ++++++++++ 2 files changed, 39 insertions(+), 1 deletion(-) diff --git a/application/views/station_profile/edit.php b/application/views/station_profile/edit.php index fb4311ad..f10a1388 100644 --- a/application/views/station_profile/edit.php +++ b/application/views/station_profile/edit.php @@ -156,7 +156,7 @@
- @@ -175,6 +175,32 @@
+
+ + + +
+ +
diff --git a/assets/js/sections/station_locations.js b/assets/js/sections/station_locations.js index f7163725..468b9a4d 100644 --- a/assets/js/sections/station_locations.js +++ b/assets/js/sections/station_locations.js @@ -10,6 +10,7 @@ $(document).ready( function () { }); $("#canada_state").hide(); + $("#aland_state").hide(); var selectedDXCCID = $('#dxcc_select').find(":selected").val(); @@ -18,11 +19,22 @@ $(document).ready( function () { $("#us_state").hide(); } + // Show Aland States if Aland is selected + if(selectedDXCCID == '5'){ + $("#aland_state").show(); + $("#canada_state").hide(); + $("#us_state").hide(); + } + $('#dxcc_select').change(function(){ if($(this).val() == '1'){ // or this.value == 'volvo' console.log("CANADA!"); $("#canada_state").show(); $("#us_state").hide(); + } else if($(this).val() == '5') { + $("#aland_state").show(); + $("#canada_state").hide(); + $("#us_state").hide(); } else { $("#canada_state").hide(); $("#us_state").show();