From 1e21493c93d795022c76be4357ef4559ce6a9441 Mon Sep 17 00:00:00 2001 From: Peter Goodhall Date: Tue, 28 May 2024 17:15:54 +0100 Subject: [PATCH 01/15] [Hamsat] when checking grid only use first 4 characters. --- application/models/Logbook_model.php | 31 +++++++++++++++++++ application/views/components/hamsat/table.php | 2 +- 2 files changed, 32 insertions(+), 1 deletion(-) diff --git a/application/models/Logbook_model.php b/application/models/Logbook_model.php index 40a81acf..f0a9cce3 100755 --- a/application/models/Logbook_model.php +++ b/application/models/Logbook_model.php @@ -2057,6 +2057,37 @@ class Logbook_model extends CI_Model return $query->num_rows(); } + function check_if_grid_4char_worked_in_logbook($grid, $StationLocationsArray = null, $band = null) + { + if ($StationLocationsArray == null) { + $CI = &get_instance(); + $CI->load->model('logbooks_model'); + $logbooks_locations_array = $CI->logbooks_model->list_logbook_relationships($this->session->userdata('active_station_logbook')); + } else { + $logbooks_locations_array = $StationLocationsArray; + } + + $this->db->select('COL_GRIDSQUARE'); + $this->db->where_in('station_id', $logbooks_locations_array); + $this->db->group_start(); + $this->db->like('SUBSTRING(COL_GRIDSQUARE, 1, 4)', substr($grid, 0, 4)); + $this->db->or_like('SUBSTRING(COL_VUCC_GRIDS, 1, 4)', substr($grid, 0, 4)); + $this->db->group_end(); + + if ($band != null && $band != 'SAT') { + $this->db->where('COL_BAND', $band); + } else if ($band == 'SAT') { + // Where col_sat_name is not empty + $this->db->where('COL_SAT_NAME !=', ''); + } + $this->db->limit('2'); + + $query = $this->db->get($this->config->item('table_name')); + + return $query->num_rows(); + } + + /* Get all QSOs with a valid grid for use in the KML export */ function kml_get_all_qsos($band, $mode, $dxcc, $cqz, $propagation, $fromdate, $todate) { diff --git a/application/views/components/hamsat/table.php b/application/views/components/hamsat/table.php index 8238d644..2efd23c2 100644 --- a/application/views/components/hamsat/table.php +++ b/application/views/components/hamsat/table.php @@ -106,7 +106,7 @@ logbook_model->check_if_grid_worked_in_logbook($grid, null, "SAT"); + $worked = $CI->logbook_model->check_if_grid_4char_worked_in_logbook($grid, null, "SAT"); if ($worked != 0) { echo " " . $grid . ""; } else { From d9d1b428fa04a8092e4574229d42925eeefcdc62 Mon Sep 17 00:00:00 2001 From: Peter Goodhall Date: Tue, 28 May 2024 17:16:57 +0100 Subject: [PATCH 02/15] formatted code better --- application/models/Logbook_model.php | 70 ++--- application/views/components/hamsat/table.php | 295 +++++++++--------- 2 files changed, 184 insertions(+), 181 deletions(-) diff --git a/application/models/Logbook_model.php b/application/models/Logbook_model.php index f0a9cce3..570f5063 100755 --- a/application/models/Logbook_model.php +++ b/application/models/Logbook_model.php @@ -165,7 +165,7 @@ class Logbook_model extends CI_Model $qso_rx_power = null; if ($this->input->post('copyexchangeto')) { - switch($this->input->post('copyexchangeto')) { + switch ($this->input->post('copyexchangeto')) { case 'dok': $darc_dok = $srx_string; break; @@ -184,13 +184,13 @@ class Logbook_model extends CI_Model case 'power': $qso_rx_power = $srx_string; break; - // Example for more sophisticated exchanges and their split into the db: - //case 'name/power': - // if (strlen($srx_string) == 0) break; - // $exch_pt = explode(" ",$srx_string); - // $qso_name = $exch_pt[0]; - // if (count($exch_pt)>1) $qso_power = $exch_pt[1]; - // break; + // Example for more sophisticated exchanges and their split into the db: + //case 'name/power': + // if (strlen($srx_string) == 0) break; + // $exch_pt = explode(" ",$srx_string); + // $qso_name = $exch_pt[0]; + // if (count($exch_pt)>1) $qso_power = $exch_pt[1]; + // break; default: } } @@ -2059,32 +2059,32 @@ class Logbook_model extends CI_Model function check_if_grid_4char_worked_in_logbook($grid, $StationLocationsArray = null, $band = null) { - if ($StationLocationsArray == null) { - $CI = &get_instance(); - $CI->load->model('logbooks_model'); - $logbooks_locations_array = $CI->logbooks_model->list_logbook_relationships($this->session->userdata('active_station_logbook')); - } else { - $logbooks_locations_array = $StationLocationsArray; - } - - $this->db->select('COL_GRIDSQUARE'); - $this->db->where_in('station_id', $logbooks_locations_array); - $this->db->group_start(); - $this->db->like('SUBSTRING(COL_GRIDSQUARE, 1, 4)', substr($grid, 0, 4)); - $this->db->or_like('SUBSTRING(COL_VUCC_GRIDS, 1, 4)', substr($grid, 0, 4)); - $this->db->group_end(); - - if ($band != null && $band != 'SAT') { - $this->db->where('COL_BAND', $band); - } else if ($band == 'SAT') { - // Where col_sat_name is not empty - $this->db->where('COL_SAT_NAME !=', ''); - } - $this->db->limit('2'); - - $query = $this->db->get($this->config->item('table_name')); - - return $query->num_rows(); + if ($StationLocationsArray == null) { + $CI = &get_instance(); + $CI->load->model('logbooks_model'); + $logbooks_locations_array = $CI->logbooks_model->list_logbook_relationships($this->session->userdata('active_station_logbook')); + } else { + $logbooks_locations_array = $StationLocationsArray; + } + + $this->db->select('COL_GRIDSQUARE'); + $this->db->where_in('station_id', $logbooks_locations_array); + $this->db->group_start(); + $this->db->like('SUBSTRING(COL_GRIDSQUARE, 1, 4)', substr($grid, 0, 4)); + $this->db->or_like('SUBSTRING(COL_VUCC_GRIDS, 1, 4)', substr($grid, 0, 4)); + $this->db->group_end(); + + if ($band != null && $band != 'SAT') { + $this->db->where('COL_BAND', $band); + } else if ($band == 'SAT') { + // Where col_sat_name is not empty + $this->db->where('COL_SAT_NAME !=', ''); + } + $this->db->limit('2'); + + $query = $this->db->get($this->config->item('table_name')); + + return $query->num_rows(); } @@ -3489,7 +3489,7 @@ class Logbook_model extends CI_Model $rx_pwr = $record['rx_pwr']; } else { $rx_pwr = null; - $my_error .= "Error QSO: Date: " . $time_on . " Callsign: " . $record['call'] . " RX_PWR (".$record['rx_pwr'].") is not a number
"; + $my_error .= "Error QSO: Date: " . $time_on . " Callsign: " . $record['call'] . " RX_PWR (" . $record['rx_pwr'] . ") is not a number
"; } } } else { diff --git a/application/views/components/hamsat/table.php b/application/views/components/hamsat/table.php index 2efd23c2..f7461e72 100644 --- a/application/views/components/hamsat/table.php +++ b/application/views/components/hamsat/table.php @@ -2,153 +2,156 @@

Hamsat - Satellite Rovers

This data is from https://hams.at/. - +

-
- Private feed key empty. Please set the feed key in your profile. -
+
+ Private feed key empty. Please set the feed key in your profile. +
- -
- -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
DateTimeCallsignCommentSatelliteModeGridsquare(s)Workable
- session->userdata('user_date_format')) { - // If Logged in and session exists - $custom_date_format = $this->session->userdata('user_date_format'); - } else { - // Get Default date format from /config/wavelog.php - $custom_date_format = $this->config->item('qso_date_format'); - } - - ?> - - - - - - - load->model('logbooks_model'); - $logbooks_locations_array = $CI->logbooks_model->list_logbook_relationships($this->session->userdata('active_station_logbook')); - $CI->load->model('logbook_model'); - $call_worked = $CI->logbook_model->check_if_callsign_worked_in_logbook($rove['callsign'], $logbooks_locations_array, "SAT"); - if ($call_worked != 0) { - echo "".$rove['callsign'].""; - } else { - echo $rove['callsign']; - } - ?> - - - "> - - - logbook_model->check_if_grid_4char_worked_in_logbook($grid, null, "SAT"); - if ($worked != 0) { - echo " " . $grid . ""; - } else { - echo " " . $grid . ""; - } - } - ?> - - - - No"; - } - } else { - echo "Unknown"; - } - ?> - Track - - Sked - -
- + +
+ +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
DateTimeCallsignCommentSatelliteModeGridsquare(s)Workable
+ session->userdata('user_date_format')) { + // If Logged in and session exists + $custom_date_format = $this->session->userdata('user_date_format'); + } else { + // Get Default date format from /config/wavelog.php + $custom_date_format = $this->config->item('qso_date_format'); + } + + ?> + + + + + + + load->model('logbooks_model'); + $logbooks_locations_array = $CI->logbooks_model->list_logbook_relationships($this->session->userdata('active_station_logbook')); + $CI->load->model('logbook_model'); + $call_worked = $CI->logbook_model->check_if_callsign_worked_in_logbook($rove['callsign'], $logbooks_locations_array, "SAT"); + if ($call_worked != 0) { + echo "" . $rove['callsign'] . ""; + } else { + echo $rove['callsign']; + } + ?> + + + "> + + + logbook_model->check_if_grid_4char_worked_in_logbook($grid, null, "SAT"); + if ($worked != 0) { + echo " " . $grid . ""; + } else { + echo " " . $grid . ""; + } + } + ?> + + + + No"; + } + } else { + echo "Unknown"; + } + ?> + Track + + Sked + +
+ - + \ No newline at end of file From 195774e1a895bf4614c2d2035ca32a5f55b52d0e Mon Sep 17 00:00:00 2001 From: Peter Goodhall Date: Tue, 28 May 2024 17:20:47 +0100 Subject: [PATCH 03/15] Removed redundant code --- application/views/view_log/qso.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/application/views/view_log/qso.php b/application/views/view_log/qso.php index 64b70fbf..ad23646b 100644 --- a/application/views/view_log/qso.php +++ b/application/views/view_log/qso.php @@ -253,7 +253,7 @@ $ci->load->library('DxccFlag'); $flag = strtolower($ci->dxccflag->getISO($row->COL_DXCC)); echo ' '; - echo ucwords(strtolower(($row->name)), "- (/"); if (isset($dxccFlag)) { echo " ".$dxccFlag; } if ($row->end != null) { echo ' '.lang('gen_hamradio_deleted_dxcc').''; } ?> + echo ucwords(strtolower(($row->name)), "- (/"); if ($row->end != null) { echo ' '.lang('gen_hamradio_deleted_dxcc').''; } ?> From 7ff122431fa30235a2e7481914ae6b2692b74028 Mon Sep 17 00:00:00 2001 From: Peter Goodhall Date: Wed, 29 May 2024 15:29:00 +0100 Subject: [PATCH 04/15] tag 2.6.14 --- application/config/migration.php | 2 +- application/migrations/185_tag_2_6_14.php | 30 +++++++++++++++++++++++ 2 files changed, 31 insertions(+), 1 deletion(-) create mode 100644 application/migrations/185_tag_2_6_14.php diff --git a/application/config/migration.php b/application/config/migration.php index ad5f2d9e..c52d5d72 100644 --- a/application/config/migration.php +++ b/application/config/migration.php @@ -22,7 +22,7 @@ $config['migration_enabled'] = TRUE; | */ -$config['migration_version'] = 184; +$config['migration_version'] = 185; /* |-------------------------------------------------------------------------- diff --git a/application/migrations/185_tag_2_6_14.php b/application/migrations/185_tag_2_6_14.php new file mode 100644 index 00000000..b5999005 --- /dev/null +++ b/application/migrations/185_tag_2_6_14.php @@ -0,0 +1,30 @@ +db->where('option_name', 'version'); + $this->db->update('options', array('option_value' => '2.6.14')); + + // Trigger Version Info Dialog + $this->db->where('option_type', 'version_dialog'); + $this->db->where('option_name', 'confirmed'); + $this->db->update('user_options', array('option_value' => 'false')); + + } + + public function down() + { + $this->db->where('option_name', 'version'); + $this->db->update('options', array('option_value' => '2.6.13')); + } +} \ No newline at end of file From 8e591bed4fc5dc8cd6e664c376a8714e34776f3f Mon Sep 17 00:00:00 2001 From: Peter Goodhall Date: Wed, 29 May 2024 15:42:56 +0100 Subject: [PATCH 05/15] [Station Locations] catched showing us grid in testing --- assets/js/sections/station_locations.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/assets/js/sections/station_locations.js b/assets/js/sections/station_locations.js index 997e3e73..07c890cf 100644 --- a/assets/js/sections/station_locations.js +++ b/assets/js/sections/station_locations.js @@ -21,7 +21,8 @@ $(document).ready( function () { '112': 'chile_state', '132': 'paraguay_state', '137': 'korea_state', - '144': 'uruguay_state' + '144': 'uruguay_state', + '291': 'us_state' }; // Hide all states initially From 6a6221bba504009600848673beb132b0b1b27c3c Mon Sep 17 00:00:00 2001 From: Peter Goodhall Date: Wed, 29 May 2024 15:56:46 +0100 Subject: [PATCH 06/15] Forgot to add Alaska to USA --- assets/js/sections/station_locations.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/assets/js/sections/station_locations.js b/assets/js/sections/station_locations.js index 07c890cf..a233c7d4 100644 --- a/assets/js/sections/station_locations.js +++ b/assets/js/sections/station_locations.js @@ -22,7 +22,8 @@ $(document).ready( function () { '132': 'paraguay_state', '137': 'korea_state', '144': 'uruguay_state', - '291': 'us_state' + '291': 'us_state', + '6': 'us_state' // Alaska }; // Hide all states initially From 7d5ff634176e1a3b3c2fcebf51241e28252cca34 Mon Sep 17 00:00:00 2001 From: Peter Goodhall Date: Thu, 30 May 2024 14:21:48 +0100 Subject: [PATCH 07/15] Readme updated --- README.md | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 82ba8a9c..a9359ec0 100644 --- a/README.md +++ b/README.md @@ -1,12 +1,11 @@ -# Cloudlog +[![Cypress Tests](https://github.com/magicbug/Cloudlog/actions/workflows/cypress-tests.yml/badge.svg)](https://github.com/magicbug/Cloudlog/actions/workflows/cypress-tests.yml) +# Cloudlog > Important: Only accepting PRs on the "dev" branch. Cloudlog is a self-hosted PHP application that allows you to log your amateur radio contacts anywhere. All you need is a web browser and active internet connection. -While Cloudlog as started by Peter Goodhall, 2M0SQL, it is has gained a core group of contributors these are listed below. If you would like to contribute to Cloudlog please see the [Contributing](#contributing) section below. - -Core Contributors: 2M0SQL ([@magicbug](https://github.com/magicbug)), LA8AJA ([@AndreasK79](https://github.com/AndreasK79)), DF2ET ([@phl0](https://github.com/phl0)), HB9HIL ([@HB9HIL](https://github.com/HB9HIL)), DJ7NT ([@int2001](https://github.com/int2001)) +While Cloudlog as started by Peter Goodhall, 2M0SQL, although since has received a lot of community code contributions. If you would like to contribute to Cloudlog please see the [Contributing](#contributing) section below. Website: [http://www.cloudlog.co.uk](http://www.cloudlog.co.uk) @@ -114,7 +113,11 @@ If you would prefer not to setup Cloudlog yourself [magicbug](https://magicbug.c If you would like to contribute in any way to Cloudlog, it is most appreciated. This has been developed in free time, help coding new features or writing documentation is always useful. -Please note that Cloudlog was built using [Codeigniter](https://www.codeigniter.com/docs) version 3 and uses Bootstrap 4 for the user CSS framework documentation is available for this when building components. +Please note that Cloudlog was built using [Codeigniter](https://www.codeigniter.com/userguide3/) version 3 and uses [Bootstrap 5](https://getbootstrap.com/docs/5.3/getting-started/introduction/) as the frontend toolkit. + +We also [HTMX](https://htmx.org/) for AJAX requests and [jQuery](https://jquery.com/) for some of the frontend functionality. We use [Font Awesome](https://fontawesome.com/) for icons. + +At the moment we use [Cypress](https://www.cypress.io/) for end-to-end testing. When submitting PRs please make sure code is commented and includes one feature only, multiple features or bug fixes will not be accepted. Please include a description of what your PR does and why it is needed. From b3db31aa05220ef971399dc55cc826f17a8fbae1 Mon Sep 17 00:00:00 2001 From: Peter Goodhall Date: Thu, 30 May 2024 14:26:18 +0100 Subject: [PATCH 08/15] Old comment --- assets/js/sections/station_locations.js | 2 -- 1 file changed, 2 deletions(-) diff --git a/assets/js/sections/station_locations.js b/assets/js/sections/station_locations.js index a233c7d4..cc6c9c27 100644 --- a/assets/js/sections/station_locations.js +++ b/assets/js/sections/station_locations.js @@ -1,7 +1,5 @@ $(document).ready( function () { - // Use Jquery to hide div ca_state - $('#station_locations_table').DataTable({ "stateSave": true, "language": { From 7741c3830521e8d48e4f2fd86ce4ed2c7cb89b38 Mon Sep 17 00:00:00 2001 From: Peter Goodhall Date: Thu, 30 May 2024 14:28:01 +0100 Subject: [PATCH 09/15] Add better comments --- assets/js/sections/station_locations.js | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/assets/js/sections/station_locations.js b/assets/js/sections/station_locations.js index cc6c9c27..7510a2be 100644 --- a/assets/js/sections/station_locations.js +++ b/assets/js/sections/station_locations.js @@ -1,5 +1,13 @@ +/** + * Initializes the DataTable and handles the logic for showing/hiding states based on the selected DXCC ID. + */ $(document).ready( function () { + /** + * Initializes the DataTable with state saving enabled and custom language settings. + * + * @type {DataTable} + */ $('#station_locations_table').DataTable({ "stateSave": true, "language": { @@ -7,6 +15,11 @@ $(document).ready( function () { } }); + /** + * Maps DXCC IDs to their corresponding state IDs. + * + * @type {Object} + */ var stateMap = { '1': 'canada_state', '5': 'aland_state', @@ -27,6 +40,9 @@ $(document).ready( function () { // Hide all states initially $("#canada_state, #aland_state, #asiatic_russia_state, #belarus_state, #mexico_state, #eu_russia_state, #argentina_state, #brazil_state, #chile_state, #us_state, #paraguay_state, #korea_state, #uruguay_state").hide(); + /** + * Gets the selected DXCC ID and shows the corresponding state. + */ var selectedDXCCID = $('#dxcc_select').find(":selected").val(); var stateToShow = stateMap[selectedDXCCID]; @@ -38,6 +54,10 @@ $(document).ready( function () { $("#us_state").show(); } + /** + * Handles the change event of the DXCC select element. + * Shows the corresponding state based on the selected DXCC ID. + */ $('#dxcc_select').change(function(){ var selectedValue = $(this).val(); var stateToShow = stateMap[selectedValue] || stateMap['default']; From afb567c9c36002d88ffd09786450a2ad244dd4b0 Mon Sep 17 00:00:00 2001 From: Peter Goodhall Date: Thu, 30 May 2024 21:14:28 +0100 Subject: [PATCH 10/15] [Dashboard] Update the QSO Today every few seconds --- application/views/dashboard/index.php | 178 +++++++++++++------------- 1 file changed, 90 insertions(+), 88 deletions(-) diff --git a/application/views/dashboard/index.php b/application/views/dashboard/index.php index 3b3711d5..1742d2e8 100644 --- a/application/views/dashboard/index.php +++ b/application/views/dashboard/index.php @@ -143,7 +143,7 @@ function echo_table_col($row, $name) case 'Flag': $ci->load->library('DxccFlag'); $flag = strtolower($ci->dxccflag->getISO($row->COL_DXCC)); - echo 'name))) . '">'; + echo 'name))) . '">'; break; } } @@ -185,15 +185,17 @@ function echoQrbCalcLink($mygrid, $grid, $vucc) optionslib->get_option('dashboard_banner') != "false") { ?> - = 1) { ?> - - - - +
+ = 1) { ?> + + + + +
@@ -294,80 +296,80 @@ function echoQrbCalcLink($mygrid, $grid, $vucc) - + - config->item('use_auth') && ($this->session->userdata('user_type') >= 2)) || $this->config->item('use_auth') === FALSE) && ($total_qsl_sent != 0 || $total_qsl_rcvd != 0 || $total_qsl_requested != 0)) { ?> - - - - - + config->item('use_auth') && ($this->session->userdata('user_type') >= 2)) || $this->config->item('use_auth') === FALSE) && ($total_qsl_sent != 0 || $total_qsl_rcvd != 0 || $total_qsl_requested != 0)) { ?> +
+ + + + - - - - - + + + + + - - - - - + + + + + - - - - - -
- + + + + + + + - config->item('use_auth') && ($this->session->userdata('user_type') >= 2)) || $this->config->item('use_auth') === FALSE) && ($total_eqsl_sent != 0 || $total_eqsl_rcvd != 0)) { ?> - - - - - + config->item('use_auth') && ($this->session->userdata('user_type') >= 2)) || $this->config->item('use_auth') === FALSE) && ($total_eqsl_sent != 0 || $total_eqsl_rcvd != 0)) { ?> +
+ + + + - - - - - + + + + + - - - - - -
- + + + + + + + - config->item('use_auth') && ($this->session->userdata('user_type') >= 2)) || $this->config->item('use_auth') === false) && ($total_lotw_sent != 0 || $total_lotw_rcvd != 0)) { ?> - - - - - + config->item('use_auth') && ($this->session->userdata('user_type') >= 2)) || $this->config->item('use_auth') === false) && ($total_lotw_sent != 0 || $total_lotw_rcvd != 0)) { ?> +
+ + + + - - - - - + + + + + - - - - - -
- + + + + + + + config->item('use_auth') && ($this->session->userdata('user_type') >= 2)) || $this->config->item('use_auth') === false) && ($total_qrz_sent != 0 || $total_qrz_rcvd != 0)) { ?> @@ -392,27 +394,27 @@ function echoQrbCalcLink($mygrid, $grid, $vucc) - config->item('use_auth') && ($this->session->userdata('user_type') >= 2)) || $this->config->item('use_auth') === FALSE)) { ?> - - - - - + config->item('use_auth') && ($this->session->userdata('user_type') >= 2)) || $this->config->item('use_auth') === FALSE)) { ?> +
VUCC-GridsSAT
+ + + + - - - - - + + + + + - - - - - + + + + + -
VUCC-GridsSAT
- + + From d1360ed3aa9bdb264d7ad616b6dd4a1d3b355d5e Mon Sep 17 00:00:00 2001 From: Peter Goodhall Date: Wed, 5 Jun 2024 15:03:39 +0100 Subject: [PATCH 11/15] [Station Locations] Added venezuela states --- application/views/station_profile/edit.php | 31 ++++++++++++++++++++++ assets/js/sections/station_locations.js | 5 ++-- 2 files changed, 34 insertions(+), 2 deletions(-) diff --git a/application/views/station_profile/edit.php b/application/views/station_profile/edit.php index 3687406c..3e5f5933 100644 --- a/application/views/station_profile/edit.php +++ b/application/views/station_profile/edit.php @@ -529,6 +529,37 @@ +
+ + + +
diff --git a/assets/js/sections/station_locations.js b/assets/js/sections/station_locations.js index 7510a2be..18e9dd86 100644 --- a/assets/js/sections/station_locations.js +++ b/assets/js/sections/station_locations.js @@ -34,11 +34,12 @@ $(document).ready( function () { '137': 'korea_state', '144': 'uruguay_state', '291': 'us_state', + '148': 'venezuela_state', '6': 'us_state' // Alaska }; // Hide all states initially - $("#canada_state, #aland_state, #asiatic_russia_state, #belarus_state, #mexico_state, #eu_russia_state, #argentina_state, #brazil_state, #chile_state, #us_state, #paraguay_state, #korea_state, #uruguay_state").hide(); + $("#canada_state, #aland_state, #asiatic_russia_state, #belarus_state, #mexico_state, #eu_russia_state, #argentina_state, #brazil_state, #chile_state, #us_state, #paraguay_state, #korea_state, #uruguay_state, #venezuela_state").hide(); /** * Gets the selected DXCC ID and shows the corresponding state. @@ -63,7 +64,7 @@ $(document).ready( function () { var stateToShow = stateMap[selectedValue] || stateMap['default']; // Hide all states - $("#mexico_state, #belarus_state, #asiatic_russia_state, #aland_state, #canada_state, #us_state, #eu_russia_state, #argentina_state, #brazil_state, #chile_state, #paraguay_state, #korea_state, #uruguay_state").hide(); + $("#mexico_state, #belarus_state, #asiatic_russia_state, #aland_state, #canada_state, #us_state, #eu_russia_state, #argentina_state, #brazil_state, #chile_state, #paraguay_state, #korea_state, #uruguay_state, #venezuela_state").hide(); // Show the selected state $("#" + stateToShow).show(); From 83ce05642a5ae7319d6be9442f763ec92a079710 Mon Sep 17 00:00:00 2001 From: Peter Goodhall Date: Wed, 5 Jun 2024 15:05:28 +0100 Subject: [PATCH 12/15] [Station Locations] Added australia states --- application/views/station_profile/edit.php | 15 +++++++++++++++ assets/js/sections/station_locations.js | 5 +++-- 2 files changed, 18 insertions(+), 2 deletions(-) diff --git a/application/views/station_profile/edit.php b/application/views/station_profile/edit.php index 3e5f5933..a6bb4db7 100644 --- a/application/views/station_profile/edit.php +++ b/application/views/station_profile/edit.php @@ -561,6 +561,21 @@ +
+ + + +
diff --git a/assets/js/sections/station_locations.js b/assets/js/sections/station_locations.js index 18e9dd86..8278eff7 100644 --- a/assets/js/sections/station_locations.js +++ b/assets/js/sections/station_locations.js @@ -35,11 +35,12 @@ $(document).ready( function () { '144': 'uruguay_state', '291': 'us_state', '148': 'venezuela_state', + '150': 'australia_state', '6': 'us_state' // Alaska }; // Hide all states initially - $("#canada_state, #aland_state, #asiatic_russia_state, #belarus_state, #mexico_state, #eu_russia_state, #argentina_state, #brazil_state, #chile_state, #us_state, #paraguay_state, #korea_state, #uruguay_state, #venezuela_state").hide(); + $("#canada_state, #aland_state, #asiatic_russia_state, #belarus_state, #mexico_state, #eu_russia_state, #argentina_state, #brazil_state, #chile_state, #us_state, #paraguay_state, #korea_state, #uruguay_state, #venezuela_state, #australia_state").hide(); /** * Gets the selected DXCC ID and shows the corresponding state. @@ -64,7 +65,7 @@ $(document).ready( function () { var stateToShow = stateMap[selectedValue] || stateMap['default']; // Hide all states - $("#mexico_state, #belarus_state, #asiatic_russia_state, #aland_state, #canada_state, #us_state, #eu_russia_state, #argentina_state, #brazil_state, #chile_state, #paraguay_state, #korea_state, #uruguay_state, #venezuela_state").hide(); + $("#mexico_state, #belarus_state, #asiatic_russia_state, #aland_state, #canada_state, #us_state, #eu_russia_state, #argentina_state, #brazil_state, #chile_state, #paraguay_state, #korea_state, #uruguay_state, #venezuela_state, #australia_state").hide(); // Show the selected state $("#" + stateToShow).show(); From 51886c73188f476247f4c54b5f05535b23b3cc53 Mon Sep 17 00:00:00 2001 From: Peter Goodhall Date: Wed, 5 Jun 2024 15:08:34 +0100 Subject: [PATCH 13/15] [Station Location] Added Papua New Guinea States --- application/views/station_profile/edit.php | 28 ++++++++++++++++++++++ assets/js/sections/station_locations.js | 5 ++-- 2 files changed, 31 insertions(+), 2 deletions(-) diff --git a/application/views/station_profile/edit.php b/application/views/station_profile/edit.php index a6bb4db7..9709055c 100644 --- a/application/views/station_profile/edit.php +++ b/application/views/station_profile/edit.php @@ -577,6 +577,34 @@ +
+ + + +
+
diff --git a/assets/js/sections/station_locations.js b/assets/js/sections/station_locations.js index 8278eff7..0c9becf3 100644 --- a/assets/js/sections/station_locations.js +++ b/assets/js/sections/station_locations.js @@ -36,11 +36,12 @@ $(document).ready( function () { '291': 'us_state', '148': 'venezuela_state', '150': 'australia_state', + '163': 'png_state', '6': 'us_state' // Alaska }; // Hide all states initially - $("#canada_state, #aland_state, #asiatic_russia_state, #belarus_state, #mexico_state, #eu_russia_state, #argentina_state, #brazil_state, #chile_state, #us_state, #paraguay_state, #korea_state, #uruguay_state, #venezuela_state, #australia_state").hide(); + $("#canada_state, #aland_state, #asiatic_russia_state, #belarus_state, #mexico_state, #eu_russia_state, #argentina_state, #brazil_state, #chile_state, #us_state, #paraguay_state, #korea_state, #uruguay_state, #venezuela_state, #australia_state, #png_state").hide(); /** * Gets the selected DXCC ID and shows the corresponding state. @@ -65,7 +66,7 @@ $(document).ready( function () { var stateToShow = stateMap[selectedValue] || stateMap['default']; // Hide all states - $("#mexico_state, #belarus_state, #asiatic_russia_state, #aland_state, #canada_state, #us_state, #eu_russia_state, #argentina_state, #brazil_state, #chile_state, #paraguay_state, #korea_state, #uruguay_state, #venezuela_state, #australia_state").hide(); + $("#mexico_state, #belarus_state, #asiatic_russia_state, #aland_state, #canada_state, #us_state, #eu_russia_state, #argentina_state, #brazil_state, #chile_state, #paraguay_state, #korea_state, #uruguay_state, #venezuela_state, #australia_state, #png_state").hide(); // Show the selected state $("#" + stateToShow).show(); From d76896edd8083d86710b4ec0af33ed05d2c76cbb Mon Sep 17 00:00:00 2001 From: Peter Goodhall Date: Wed, 5 Jun 2024 15:11:02 +0100 Subject: [PATCH 14/15] [Station Locations] Added New Zealand States --- application/views/station_profile/edit.php | 25 ++++++++++++++++++++++ assets/js/sections/station_locations.js | 6 +++--- 2 files changed, 28 insertions(+), 3 deletions(-) diff --git a/application/views/station_profile/edit.php b/application/views/station_profile/edit.php index 9709055c..2baa1c28 100644 --- a/application/views/station_profile/edit.php +++ b/application/views/station_profile/edit.php @@ -605,6 +605,31 @@
+
+ + + +
+ +
diff --git a/assets/js/sections/station_locations.js b/assets/js/sections/station_locations.js index 0c9becf3..b9acbf05 100644 --- a/assets/js/sections/station_locations.js +++ b/assets/js/sections/station_locations.js @@ -37,12 +37,12 @@ $(document).ready( function () { '148': 'venezuela_state', '150': 'australia_state', '163': 'png_state', + '170': 'nz_state', '6': 'us_state' // Alaska }; // Hide all states initially - $("#canada_state, #aland_state, #asiatic_russia_state, #belarus_state, #mexico_state, #eu_russia_state, #argentina_state, #brazil_state, #chile_state, #us_state, #paraguay_state, #korea_state, #uruguay_state, #venezuela_state, #australia_state, #png_state").hide(); - + $("#canada_state, #aland_state, #asiatic_russia_state, #belarus_state, #mexico_state, #eu_russia_state, #argentina_state, #brazil_state, #chile_state, #us_state, #paraguay_state, #korea_state, #uruguay_state, #venezuela_state, #australia_state, #png_state, #nz_state").hide(); /** * Gets the selected DXCC ID and shows the corresponding state. */ @@ -66,7 +66,7 @@ $(document).ready( function () { var stateToShow = stateMap[selectedValue] || stateMap['default']; // Hide all states - $("#mexico_state, #belarus_state, #asiatic_russia_state, #aland_state, #canada_state, #us_state, #eu_russia_state, #argentina_state, #brazil_state, #chile_state, #paraguay_state, #korea_state, #uruguay_state, #venezuela_state, #australia_state, #png_state").hide(); + $("#mexico_state, #belarus_state, #asiatic_russia_state, #aland_state, #canada_state, #us_state, #eu_russia_state, #argentina_state, #brazil_state, #chile_state, #paraguay_state, #korea_state, #uruguay_state, #venezuela_state, #australia_state, #png_state, #nz_state").hide(); // Show the selected state $("#" + stateToShow).show(); From f40b244f737ae7e10a7f3dd8f9f65ba75ddd94ea Mon Sep 17 00:00:00 2001 From: Peter Goodhall Date: Wed, 5 Jun 2024 15:13:37 +0100 Subject: [PATCH 15/15] [Station Location] Added Belgium States --- application/views/station_profile/edit.php | 18 ++++++++++++++++++ assets/js/sections/station_locations.js | 5 +++-- 2 files changed, 21 insertions(+), 2 deletions(-) diff --git a/application/views/station_profile/edit.php b/application/views/station_profile/edit.php index 2baa1c28..4c4f4a42 100644 --- a/application/views/station_profile/edit.php +++ b/application/views/station_profile/edit.php @@ -629,6 +629,24 @@
+
+ + + +
diff --git a/assets/js/sections/station_locations.js b/assets/js/sections/station_locations.js index b9acbf05..4d28ed9e 100644 --- a/assets/js/sections/station_locations.js +++ b/assets/js/sections/station_locations.js @@ -38,11 +38,12 @@ $(document).ready( function () { '150': 'australia_state', '163': 'png_state', '170': 'nz_state', + '209': 'belgium_state', '6': 'us_state' // Alaska }; // Hide all states initially - $("#canada_state, #aland_state, #asiatic_russia_state, #belarus_state, #mexico_state, #eu_russia_state, #argentina_state, #brazil_state, #chile_state, #us_state, #paraguay_state, #korea_state, #uruguay_state, #venezuela_state, #australia_state, #png_state, #nz_state").hide(); + $("#canada_state, #aland_state, #asiatic_russia_state, #belarus_state, #mexico_state, #eu_russia_state, #argentina_state, #brazil_state, #chile_state, #us_state, #paraguay_state, #korea_state, #uruguay_state, #venezuela_state, #australia_state, #png_state, #nz_state, #belgium_state").hide(); /** * Gets the selected DXCC ID and shows the corresponding state. */ @@ -66,7 +67,7 @@ $(document).ready( function () { var stateToShow = stateMap[selectedValue] || stateMap['default']; // Hide all states - $("#mexico_state, #belarus_state, #asiatic_russia_state, #aland_state, #canada_state, #us_state, #eu_russia_state, #argentina_state, #brazil_state, #chile_state, #paraguay_state, #korea_state, #uruguay_state, #venezuela_state, #australia_state, #png_state, #nz_state").hide(); + $("#mexico_state, #belarus_state, #asiatic_russia_state, #aland_state, #canada_state, #us_state, #eu_russia_state, #argentina_state, #brazil_state, #chile_state, #paraguay_state, #korea_state, #uruguay_state, #venezuela_state, #australia_state, #png_state, #nz_state, #belgium_state").hide(); // Show the selected state $("#" + stateToShow).show();