From 161638c20913c337ac758f5e2adfdc1210d2cbd0 Mon Sep 17 00:00:00 2001 From: int2001 Date: Fri, 7 Mar 2025 17:03:51 +0000 Subject: [PATCH] Don't show SAT-Col for IOTAs when SAT wasn't chosen --- application/controllers/Awards.php | 1 + application/models/Iota.php | 3 +++ application/views/awards/iota/index.php | 3 +++ 3 files changed, 7 insertions(+) diff --git a/application/controllers/Awards.php b/application/controllers/Awards.php index 3baafcd2a..ce7b0007b 100644 --- a/application/controllers/Awards.php +++ b/application/controllers/Awards.php @@ -858,6 +858,7 @@ class Awards extends CI_Controller { $iotalist = $this->iota->fetchIota($postdata, $location_list); $data['iota_array'] = $this->iota->get_iota_array($iotalist, $bands, $postdata, $location_list); $data['iota_summary'] = $this->iota->get_iota_summary($bands, $postdata, $location_list); + $data['posted_band']=$postdata['band']; // Render Page $data['page_title'] = sprintf(__("Awards - %s"), __("IOTA (Island On The Air)")); diff --git a/application/models/Iota.php b/application/models/Iota.php index 32822fc68..899b05eb2 100644 --- a/application/models/Iota.php +++ b/application/models/Iota.php @@ -7,6 +7,9 @@ class IOTA extends CI_Model { function get_iota_array($iotaArray, $bands, $postdata, $location_list) { foreach ($bands as $band) { // Looping through bands and iota to generate the array needed for display + if (($postdata['band'] != 'SAT') && ($band == 'SAT')) { + continue; + } foreach ($iotaArray as $iota) { $iotaMatrix[$iota->tag]['prefix'] = $iota->prefix; $iotaMatrix[$iota->tag]['name'] = $iota->name; diff --git a/application/views/awards/iota/index.php b/application/views/awards/iota/index.php index 7d9dfd847..b1720c48f 100644 --- a/application/views/awards/iota/index.php +++ b/application/views/awards/iota/index.php @@ -199,6 +199,9 @@ echo ' ' . __("Deleted") . ''; foreach($bands as $band) { + if (($posted_band != 'SAT') && ($band == 'SAT')) { + continue; + } echo '' . $band . ''; } echo '