From 028644a837d8ec41c23fb69d06ba72c62bd42744 Mon Sep 17 00:00:00 2001 From: HB9HIL Date: Tue, 14 Nov 2023 20:29:58 +0100 Subject: [PATCH 01/22] changed if callsignValue --- assets/js/sections/qso.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/assets/js/sections/qso.js b/assets/js/sections/qso.js index a1146772..f454e03c 100644 --- a/assets/js/sections/qso.js +++ b/assets/js/sections/qso.js @@ -1,7 +1,7 @@ $( document ).ready(function() { setTimeout(function() { var callsignValue = localStorage.getItem("quicklogCallsign"); - if (callsignValue !== "") { + if (callsignValue !== null && callsignValue !== undefined) { $("#callsign").val(callsignValue); $("#mode").focus(); localStorage.removeItem("quicklogCallsign"); From 0e68b0641ddde9f7b999d2d5fd68f0dafacde452 Mon Sep 17 00:00:00 2001 From: HB9HIL Date: Tue, 14 Nov 2023 23:25:06 +0100 Subject: [PATCH 02/22] fix_reset_time --- application/views/interface_assets/footer.php | 31 ----------------- assets/js/sections/qso.js | 33 ++++++++++++++++++- 2 files changed, 32 insertions(+), 32 deletions(-) diff --git a/application/views/interface_assets/footer.php b/application/views/interface_assets/footer.php index 18970412..40597e06 100644 --- a/application/views/interface_assets/footer.php +++ b/application/views/interface_assets/footer.php @@ -1000,37 +1000,6 @@ $(document).on('keypress',function(e) { } ); }); - $('#reset_time').click(function() { - var now = new Date(); - var localTime = now.getTime(); - var utc = localTime + (now.getTimezoneOffset() * 60000); - $('#start_time').val(("0" + now.getUTCHours()).slice(-2)+':'+("0" + now.getUTCMinutes()).slice(-2)+':'+("0" + now.getUTCSeconds()).slice(-2)); - $("[id='start_time']").each(function() { - $(this).attr("value", ("0" + now.getUTCHours()).slice(-2)+':'+("0" + now.getUTCMinutes()).slice(-2)+':'+("0" + now.getUTCSeconds()).slice(-2)); - }); - }); - $('#reset_start_time').click(function() { - var now = new Date(); - var localTime = now.getTime(); - var utc = localTime + (now.getTimezoneOffset() * 60000); - $('#start_time').val(("0" + now.getUTCHours()).slice(-2)+':'+("0" + now.getUTCMinutes()).slice(-2)); - $("[id='start_time']").each(function() { - $(this).attr("value", ("0" + now.getUTCHours()).slice(-2)+':'+("0" + now.getUTCMinutes()).slice(-2)+':'+("0" + now.getUTCSeconds()).slice(-2)); - }); - $('#end_time').val(("0" + now.getUTCHours()).slice(-2)+':'+("0" + now.getUTCMinutes()).slice(-2)); - $("[id='end_time']").each(function() { - $(this).attr("value", ("0" + now.getUTCHours()).slice(-2)+':'+("0" + now.getUTCMinutes()).slice(-2)+':'+("0" + now.getUTCSeconds()).slice(-2)); - }); - }); - $('#reset_end_time').click(function() { - var now = new Date(); - var localTime = now.getTime(); - var utc = localTime + (now.getTimezoneOffset() * 60000); - $('#end_time').val(("0" + now.getUTCHours()).slice(-2)+':'+("0" + now.getUTCMinutes()).slice(-2)); - $("[id='end_time']").each(function() { - $(this).attr("value", ("0" + now.getUTCHours()).slice(-2)+':'+("0" + now.getUTCMinutes()).slice(-2)+':'+("0" + now.getUTCSeconds()).slice(-2)); - }); - }); }); diff --git a/assets/js/sections/qso.js b/assets/js/sections/qso.js index f454e03c..b3090454 100644 --- a/assets/js/sections/qso.js +++ b/assets/js/sections/qso.js @@ -6,7 +6,38 @@ $( document ).ready(function() { $("#mode").focus(); localStorage.removeItem("quicklogCallsign"); } - }, 100); + }, 100); + $('#reset_time').click(function() { + var now = new Date(); + var localTime = now.getTime(); + var utc = localTime + (now.getTimezoneOffset() * 60000); + $('#start_time').val(("0" + now.getUTCHours()).slice(-2)+':'+("0" + now.getUTCMinutes()).slice(-2)+':'+("0" + now.getUTCSeconds()).slice(-2)); + $("[id='start_time']").each(function() { + $(this).attr("value", ("0" + now.getUTCHours()).slice(-2)+':'+("0" + now.getUTCMinutes()).slice(-2)+':'+("0" + now.getUTCSeconds()).slice(-2)); + }); + }); + $('#reset_start_time').click(function() { + var now = new Date(); + var localTime = now.getTime(); + var utc = localTime + (now.getTimezoneOffset() * 60000); + $('#start_time').val(("0" + now.getUTCHours()).slice(-2)+':'+("0" + now.getUTCMinutes()).slice(-2)); + $("[id='start_time']").each(function() { + $(this).attr("value", ("0" + now.getUTCHours()).slice(-2)+':'+("0" + now.getUTCMinutes()).slice(-2)+':'+("0" + now.getUTCSeconds()).slice(-2)); + }); + $('#end_time').val(("0" + now.getUTCHours()).slice(-2)+':'+("0" + now.getUTCMinutes()).slice(-2)); + $("[id='end_time']").each(function() { + $(this).attr("value", ("0" + now.getUTCHours()).slice(-2)+':'+("0" + now.getUTCMinutes()).slice(-2)+':'+("0" + now.getUTCSeconds()).slice(-2)); + }); + }); + $('#reset_end_time').click(function() { + var now = new Date(); + var localTime = now.getTime(); + var utc = localTime + (now.getTimezoneOffset() * 60000); + $('#end_time').val(("0" + now.getUTCHours()).slice(-2)+':'+("0" + now.getUTCMinutes()).slice(-2)); + $("[id='end_time']").each(function() { + $(this).attr("value", ("0" + now.getUTCHours()).slice(-2)+':'+("0" + now.getUTCMinutes()).slice(-2)+':'+("0" + now.getUTCSeconds()).slice(-2)); + }); + }); var favs={}; get_fav(); From 0025ff8fccbcfd8d2e483fdcd465387cb1cb5e63 Mon Sep 17 00:00:00 2001 From: phl0 Date: Wed, 15 Nov 2023 08:58:42 +0100 Subject: [PATCH 03/22] Prevent fetching image from non-existent qrz.com entry --- application/controllers/Logbook.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/application/controllers/Logbook.php b/application/controllers/Logbook.php index f0ff8f12..4f56f4b7 100644 --- a/application/controllers/Logbook.php +++ b/application/controllers/Logbook.php @@ -168,7 +168,7 @@ class Logbook extends CI_Controller { $return['confirmed'] = $this->confirmed_grid_before($return['callsign_qra'], $type, $band, $mode); if ($this->session->userdata('user_show_profile_image')) { - if (isset($callbook)) { + if (isset($callbook) && isset($callbook['image'])) { if ($callbook['image'] == "") { $return['image'] = "n/a"; } else { From 582cbb803cacf89a35a82c5c8d790ab0caf03686 Mon Sep 17 00:00:00 2001 From: phl0 Date: Wed, 15 Nov 2023 10:01:36 +0100 Subject: [PATCH 04/22] Fix previous lookup for QSO logging window --- application/controllers/Logbook.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/application/controllers/Logbook.php b/application/controllers/Logbook.php index 4f56f4b7..5e2cb87e 100644 --- a/application/controllers/Logbook.php +++ b/application/controllers/Logbook.php @@ -851,13 +851,13 @@ function worked_grid_before($gridsquare, $type, $band, $mode) $qrz_session_key = $this->qrz->session($this->config->item('qrz_username'), $this->config->item('qrz_password')); $this->session->set_userdata('qrz_session_key', $qrz_session_key); } - $data= $this->qrz->search($id, $this->session->userdata('qrz_session_key'), $this->config->item('use_fullname')); + $callsign['callsign'] = $this->qrz->search($id, $this->session->userdata('qrz_session_key'), $this->config->item('use_fullname')); - if (empty($data['callsign'])) + if (empty($callsign['callsign']['callsign'])) { $qrz_session_key = $this->qrz->session($this->config->item('qrz_username'), $this->config->item('qrz_password')); $this->session->set_userdata('qrz_session_key', $qrz_session_key); - $data = $this->qrz->search($id, $this->session->userdata('qrz_session_key'), $this->config->item('use_fullname')); + $callsign['callsign'] = $this->qrz->search($id, $this->session->userdata('qrz_session_key'), $this->config->item('use_fullname')); } } @@ -866,12 +866,12 @@ function worked_grid_before($gridsquare, $type, $band, $mode) // Lookup using hamli $this->load->library('hamli'); - $data['callsign'] = $this->hamli->callsign($id); + $callsign['callsign'] = $this->hamli->callsign($id); }*/ - $data['id'] = strtoupper($id); + $callsign['id'] = strtoupper($id); - return $this->load->view('search/result', $data, true); + return $this->load->view('search/result', $callsign, true); } } From 596a276020643e615ce57274a9dbf0474c750f1a Mon Sep 17 00:00:00 2001 From: phl0 Date: Wed, 15 Nov 2023 10:03:38 +0100 Subject: [PATCH 05/22] Worked grid lookup also for QSO logging view --- application/controllers/Logbook.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/application/controllers/Logbook.php b/application/controllers/Logbook.php index 5e2cb87e..e2fa74f1 100644 --- a/application/controllers/Logbook.php +++ b/application/controllers/Logbook.php @@ -869,6 +869,11 @@ function worked_grid_before($gridsquare, $type, $band, $mode) $callsign['callsign'] = $this->hamli->callsign($id); }*/ + if (isset($callsign['callsign']['gridsquare'])) { + $CI = &get_instance(); + $CI->load->model('logbook_model'); + $callsign['grid_worked'] = $CI->logbook_model->check_if_grid_worked_in_logbook(strtoupper(substr($callsign['callsign']['gridsquare'],0,4)), 0, $this->session->userdata('user_default_band')); + } $callsign['id'] = strtoupper($id); return $this->load->view('search/result', $callsign, true); From 99a88e96d5f0235d8010d203abc86b3f57b0bc8d Mon Sep 17 00:00:00 2001 From: phl0 Date: Wed, 15 Nov 2023 10:09:03 +0100 Subject: [PATCH 06/22] Also show lookup error during QSO logging --- application/controllers/Logbook.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/application/controllers/Logbook.php b/application/controllers/Logbook.php index e2fa74f1..5835dff2 100644 --- a/application/controllers/Logbook.php +++ b/application/controllers/Logbook.php @@ -874,6 +874,9 @@ function worked_grid_before($gridsquare, $type, $band, $mode) $CI->load->model('logbook_model'); $callsign['grid_worked'] = $CI->logbook_model->check_if_grid_worked_in_logbook(strtoupper(substr($callsign['callsign']['gridsquare'],0,4)), 0, $this->session->userdata('user_default_band')); } + if (isset($callsign['callsign']['error'])) { + $callsign['error'] = $callsign['callsign']['error']; + } $callsign['id'] = strtoupper($id); return $this->load->view('search/result', $callsign, true); From 6b41927d8d2de9a7ab60d502205ab1dec8c363d0 Mon Sep 17 00:00:00 2001 From: phl0 Date: Wed, 15 Nov 2023 11:06:14 +0100 Subject: [PATCH 07/22] Cover not configured lookup --- application/controllers/Logbook.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/application/controllers/Logbook.php b/application/controllers/Logbook.php index 5835dff2..223f1c9c 100644 --- a/application/controllers/Logbook.php +++ b/application/controllers/Logbook.php @@ -859,6 +859,8 @@ function worked_grid_before($gridsquare, $type, $band, $mode) $this->session->set_userdata('qrz_session_key', $qrz_session_key); $callsign['callsign'] = $this->qrz->search($id, $this->session->userdata('qrz_session_key'), $this->config->item('use_fullname')); } + } else { + $callsign['error'] = 'Lookup not configured or set to hamqth. Currently only qrz is supported.'; } // There's no hamli integration? Disabled for now. @@ -936,7 +938,7 @@ function worked_grid_before($gridsquare, $type, $band, $mode) $data['error'] = $data['callsign']['error']; } } else { - $data['error'] = 'No result (qrz not configured)'; + $data['error'] = 'Lookup not configured or set to hamqth. Currently only qrz is supported.'; } /*else { // Lookup using hamli $this->load->library('hamli'); From 7e8e108ff4a358683eaa1b8b185e2a540ccafc79 Mon Sep 17 00:00:00 2001 From: phl0 Date: Wed, 15 Nov 2023 12:20:32 +0100 Subject: [PATCH 08/22] We do not need to (re-)update distances if grids are the same --- application/models/Logbook_model.php | 1 + 1 file changed, 1 insertion(+) diff --git a/application/models/Logbook_model.php b/application/models/Logbook_model.php index fdeef86e..46cd4788 100755 --- a/application/models/Logbook_model.php +++ b/application/models/Logbook_model.php @@ -4083,6 +4083,7 @@ function check_if_callsign_worked_in_logbook($callsign, $StationLocationsArray = $this->db->where("((COL_DISTANCE is NULL) or (COL_DISTANCE = 0))"); $this->db->where("COL_GRIDSQUARE is NOT NULL"); $this->db->where("COL_GRIDSQUARE != ''"); + $this->db->where("COL_GRIDSQUARE != station_gridsquare"); $this->db->trans_start(); $query = $this->db->get($this->config->item('table_name')); From 7fc5b98826033cd8c997477cca841547e647fa5c Mon Sep 17 00:00:00 2001 From: phl0 Date: Wed, 15 Nov 2023 12:24:45 +0100 Subject: [PATCH 09/22] Remove forgotten debug statements --- application/models/Logbook_model.php | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/application/models/Logbook_model.php b/application/models/Logbook_model.php index 46cd4788..34ec1c34 100755 --- a/application/models/Logbook_model.php +++ b/application/models/Logbook_model.php @@ -433,8 +433,7 @@ class Logbook_model extends CI_Model { $this->db->limit(500); $result = $this->db->get($this->config->item('table_name')); - log_message('debug', 'SQL: '.$this->db->last_query()); - return $result; + return $result; //return $this->db->get($this->config->item('table_name')); } @@ -4118,7 +4117,6 @@ function check_if_callsign_worked_in_logbook($callsign, $StationLocationsArray = $this->db->select('COL_PRIMARY_KEY, COL_TIME_ON, COL_CALL, COL_MODE, COL_BAND'); $this->db->where('station_id =', NULL); $query = $this->db->get($this->config->item('table_name')); - log_message('debug','SQL: '.$this->db->last_query()); if($query->num_rows() >= 1) { return $query->result(); } else { From e8bfe6ed7fb123e545f07fa8208d70149a127c32 Mon Sep 17 00:00:00 2001 From: phl0 Date: Wed, 15 Nov 2023 17:11:45 +0100 Subject: [PATCH 10/22] HamQTH Lookup for search --- application/controllers/Logbook.php | 27 ++++++++++++++++++++++++++- application/libraries/Hamqth.php | 2 +- 2 files changed, 27 insertions(+), 2 deletions(-) diff --git a/application/controllers/Logbook.php b/application/controllers/Logbook.php index 223f1c9c..fa5d33f3 100644 --- a/application/controllers/Logbook.php +++ b/application/controllers/Logbook.php @@ -937,8 +937,33 @@ function worked_grid_before($gridsquare, $type, $band, $mode) if (isset($data['callsign']['error'])) { $data['error'] = $data['callsign']['error']; } + } else if ($this->config->item('callbook') == "hamqth" && $this->config->item('hamqth_username') != null && $this->config->item('hamqth_password') != null) { + // Load the HamQTH library + $this->load->library('hamqth'); + + if(!$this->session->userdata('hamqth_session_key')) { + $hamqth_session_key = $this->hamqth->session($this->config->item('hamqth_username'), $this->config->item('hamqth_password')); + $this->session->set_userdata('hamqth_session_key', $hamqth_session_key); + } + + $data['callsign'] = $this->hamqth->search($id, $this->session->userdata('hamqth_session_key')); + + // If HamQTH session has expired, start a new session and retry the search. + if($data['callsign']['error'] == "Session does not exist or expired") { + $hamqth_session_key = $this->hamqth->session($this->config->item('hamqth_username'), $this->config->item('hamqth_password')); + $this->session->set_userdata('hamqth_session_key', $hamqth_session_key); + $data['callsign'] = $this->hamqth->search($callsign, $this->session->userdata('hamqth_session_key')); + } + if (isset($data['callsign']['gridsquare'])) { + $CI = &get_instance(); + $CI->load->model('logbook_model'); + $data['grid_worked'] = $CI->logbook_model->check_if_grid_worked_in_logbook(strtoupper(substr($data['callsign']['gridsquare'],0,4)), 0, $this->session->userdata('user_default_band')); + } + if (isset($data['callsign']['error'])) { + $data['error'] = $data['callsign']['error']; + } } else { - $data['error'] = 'Lookup not configured or set to hamqth. Currently only qrz is supported.'; + $data['error'] = 'Lookup not configured. Please review configuration.'; } /*else { // Lookup using hamli $this->load->library('hamli'); diff --git a/application/libraries/Hamqth.php b/application/libraries/Hamqth.php index f2646735..1b71449b 100644 --- a/application/libraries/Hamqth.php +++ b/application/libraries/Hamqth.php @@ -71,7 +71,7 @@ class Hamqth { // Create XML object $xml = simplexml_load_string($xml); - if (empty($xml)) return; + if (!empty($xml->session->error)) return $data['error'] = $xml->session->error; // Return Required Fields $data['callsign'] = (string)$xml->search->callsign; From 528c2ed3fd8078f1a11a628940c83fe4c8dd8158 Mon Sep 17 00:00:00 2001 From: phl0 Date: Wed, 15 Nov 2023 20:17:44 +0100 Subject: [PATCH 11/22] Implement hamqth lookup for QSO log view --- application/controllers/Logbook.php | 40 +++++++++++++++++++++++------ 1 file changed, 32 insertions(+), 8 deletions(-) diff --git a/application/controllers/Logbook.php b/application/controllers/Logbook.php index fa5d33f3..3fa7c0f7 100644 --- a/application/controllers/Logbook.php +++ b/application/controllers/Logbook.php @@ -851,16 +851,40 @@ function worked_grid_before($gridsquare, $type, $band, $mode) $qrz_session_key = $this->qrz->session($this->config->item('qrz_username'), $this->config->item('qrz_password')); $this->session->set_userdata('qrz_session_key', $qrz_session_key); } - $callsign['callsign'] = $this->qrz->search($id, $this->session->userdata('qrz_session_key'), $this->config->item('use_fullname')); + $callsign['callsign'] = $this->qrz->search($id, $this->session->userdata('qrz_session_key'), $this->config->item('use_fullname')); - if (empty($callsign['callsign']['callsign'])) - { - $qrz_session_key = $this->qrz->session($this->config->item('qrz_username'), $this->config->item('qrz_password')); - $this->session->set_userdata('qrz_session_key', $qrz_session_key); - $callsign['callsign'] = $this->qrz->search($id, $this->session->userdata('qrz_session_key'), $this->config->item('use_fullname')); - } + if (empty($callsign['callsign']['callsign'])) { + $qrz_session_key = $this->qrz->session($this->config->item('qrz_username'), $this->config->item('qrz_password')); + $this->session->set_userdata('qrz_session_key', $qrz_session_key); + $callsign['callsign'] = $this->qrz->search($id, $this->session->userdata('qrz_session_key'), $this->config->item('use_fullname')); + } + } else if ($this->config->item('callbook') == "hamqth" && $this->config->item('hamqth_username') != null && $this->config->item('hamqth_password') != null) { + // Load the HamQTH library + $this->load->library('hamqth'); + + if(!$this->session->userdata('hamqth_session_key')) { + $hamqth_session_key = $this->hamqth->session($this->config->item('hamqth_username'), $this->config->item('hamqth_password')); + $this->session->set_userdata('hamqth_session_key', $hamqth_session_key); + } + + $callsign['callsign'] = $this->hamqth->search($id, $this->session->userdata('hamqth_session_key')); + + // If HamQTH session has expired, start a new session and retry the search. + if($callsign['callsign']['error'] == "Session does not exist or expired") { + $hamqth_session_key = $this->hamqth->session($this->config->item('hamqth_username'), $this->config->item('hamqth_password')); + $this->session->set_userdata('hamqth_session_key', $hamqth_session_key); + $callsign['callsign'] = $this->hamqth->search($callsign, $this->session->userdata('hamqth_session_key')); + } + if (isset($data['callsign']['gridsquare'])) { + $CI = &get_instance(); + $CI->load->model('logbook_model'); + $callsign['grid_worked'] = $CI->logbook_model->check_if_grid_worked_in_logbook(strtoupper(substr($data['callsign']['gridsquare'],0,4)), 0, $this->session->userdata('user_default_band')); + } + if (isset($callsign['callsign']['error'])) { + $callsign['error'] = $callsign['callsign']['error']; + } } else { - $callsign['error'] = 'Lookup not configured or set to hamqth. Currently only qrz is supported.'; + $callsign['error'] = 'Lookup not configured. Please review configuration.'; } // There's no hamli integration? Disabled for now. From 2817eee2cfe879846aaa45e86b18941a01cb8f50 Mon Sep 17 00:00:00 2001 From: phl0 Date: Thu, 16 Nov 2023 09:08:43 +0100 Subject: [PATCH 12/22] Disable debug output (spoiling logs) --- application/libraries/Curl.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/application/libraries/Curl.php b/application/libraries/Curl.php index 106df120..35a75524 100644 --- a/application/libraries/Curl.php +++ b/application/libraries/Curl.php @@ -27,7 +27,6 @@ class Curl { function __construct($url = '') { $this->_ci = & get_instance(); - log_message('debug', 'cURL Class Initialized'); if ( ! $this->is_enabled()) { @@ -369,4 +368,4 @@ class Curl { } /* End of file Curl.php */ -/* Location: ./application/libraries/Curl.php */ \ No newline at end of file +/* Location: ./application/libraries/Curl.php */ From 936e60089a122b4c643e8fc81c50a668fd939d60 Mon Sep 17 00:00:00 2001 From: phl0 Date: Thu, 16 Nov 2023 09:36:56 +0100 Subject: [PATCH 13/22] We should only check directories for being writable --- application/controllers/Debug.php | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/application/controllers/Debug.php b/application/controllers/Debug.php index 5d8d2a9c..1d60cbd5 100644 --- a/application/controllers/Debug.php +++ b/application/controllers/Debug.php @@ -52,9 +52,11 @@ class Debug extends CI_Controller { // Check if the subdirectories are writable (recursive check) $iterator = new RecursiveIteratorIterator(new RecursiveDirectoryIterator($path)); foreach ($iterator as $item) { - if (!is_writable($item->getPathname())) { - return false; - } + if ($item->isDir() && basename($item->getPathName()) != '..') { + if (!is_writable($item->getRealPath())) { + return false; + } + } } return true; From 5707809d0abb7e43287b3a2e91b7df3a24fe8740 Mon Sep 17 00:00:00 2001 From: int2001 Date: Fri, 17 Nov 2023 07:20:02 +0000 Subject: [PATCH 14/22] Fixing Error when "lastupload" isn't set --- application/views/view_log/partial/log_ajax.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/application/views/view_log/partial/log_ajax.php b/application/views/view_log/partial/log_ajax.php index cf246c0b..fb99eed8 100644 --- a/application/views/view_log/partial/log_ajax.php +++ b/application/views/view_log/partial/log_ajax.php @@ -102,7 +102,7 @@ function echoQrbCalcLink($mygrid, $grid, $vucc) { COL_CALL)); ?> lastupload) { + if (isset($row->lastupload) && ($row->lastupload)) { $lotw_hint = ''; $diff = (time() - strtotime($row->lastupload)) / 86400; if ($diff > 365) { From 5cfa27c4d9b52133ed5769efc2e838f44c6285b1 Mon Sep 17 00:00:00 2001 From: int2001 Date: Fri, 17 Nov 2023 07:26:31 +0000 Subject: [PATCH 15/22] Added left-oouter join on lotw_users to fetch last-lotw-up --- application/models/Logbook_model.php | 1 + 1 file changed, 1 insertion(+) diff --git a/application/models/Logbook_model.php b/application/models/Logbook_model.php index 34ec1c34..2e399f4e 100755 --- a/application/models/Logbook_model.php +++ b/application/models/Logbook_model.php @@ -500,6 +500,7 @@ class Logbook_model extends CI_Model { $this->db->join('station_profile', 'station_profile.station_id = '.$this->config->item('table_name').'.station_id'); $this->db->join('dxcc_entities', 'dxcc_entities.adif = '.$this->config->item('table_name').'.COL_DXCC', 'left outer'); + $this->db->join('lotw_users', 'lotw_users.callsign = '.$this->config->item('table_name').'.col_call', 'left outer'); $this->db->where('COL_CALL', $call); if ($band != 'All') { if ($band == 'SAT') { From b5ed396988752637def759c3ed2584a7070115b5 Mon Sep 17 00:00:00 2001 From: phl0 Date: Fri, 17 Nov 2023 13:21:31 +0100 Subject: [PATCH 16/22] Add link to FG8OJ sked tool to hams.at listing --- application/controllers/Components.php | 4 +++- application/views/components/hamsat/table.php | 10 ++++++++++ application/views/hamsat/index.php | 2 +- 3 files changed, 14 insertions(+), 2 deletions(-) diff --git a/application/controllers/Components.php b/application/controllers/Components.php index 942dcbc3..7fc0e27a 100644 --- a/application/controllers/Components.php +++ b/application/controllers/Components.php @@ -14,11 +14,13 @@ class Components extends CI_Controller { } public function index() { + $this->load->model('stations'); $url = 'https://oscarwatch.org/scripts/hamsat_json.php'; $json = file_get_contents($url); $data['rovedata'] = json_decode($json, true); + $data['gridsquare'] = strtoupper($this->stations->find_gridsquare()); // load view $this->load->view('components/hamsat/table', $data); } -} \ No newline at end of file +} diff --git a/application/views/components/hamsat/table.php b/application/views/components/hamsat/table.php index e218916f..0792824d 100644 --- a/application/views/components/hamsat/table.php +++ b/application/views/components/hamsat/table.php @@ -17,6 +17,7 @@ Satellite Gridsquare(s) + @@ -92,6 +93,15 @@ Track + + Sked diff --git a/application/views/hamsat/index.php b/application/views/hamsat/index.php index aba617d2..f5f033f2 100644 --- a/application/views/hamsat/index.php +++ b/application/views/hamsat/index.php @@ -1,3 +1,3 @@
-
\ No newline at end of file + From a71f13d9dc1f59cf7de36bbdec152c4174b280f1 Mon Sep 17 00:00:00 2001 From: Peter Goodhall Date: Fri, 17 Nov 2023 13:19:55 +0000 Subject: [PATCH 17/22] Removed CSS variable as it made required fields red whether they had been inputted or not --- assets/css/general.css | 4 ---- 1 file changed, 4 deletions(-) diff --git a/assets/css/general.css b/assets/css/general.css index 0118e5cf..fbf81e99 100644 --- a/assets/css/general.css +++ b/assets/css/general.css @@ -552,10 +552,6 @@ div#station_logbooks_linked_table_paginate { margin-right: 30px; } -input:invalid { - border-color: red; -} - .sfletable{ height: 470px; } From c881ab2272bae94078066d32fb4e2f3e5ada8b1e Mon Sep 17 00:00:00 2001 From: HB9HIL Date: Fri, 17 Nov 2023 16:44:30 +0100 Subject: [PATCH 18/22] added htmlspecialchars to comment --- application/views/qso/edit_ajax.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/application/views/qso/edit_ajax.php b/application/views/qso/edit_ajax.php index f7e7d097..d5ea0d2b 100644 --- a/application/views/qso/edit_ajax.php +++ b/application/views/qso/edit_ajax.php @@ -187,7 +187,7 @@
- +
From ff2872de6518ae1b643591f3faa8abf409b1b5db Mon Sep 17 00:00:00 2001 From: HB9HIL Date: Fri, 17 Nov 2023 16:53:59 +0100 Subject: [PATCH 19/22] special characters check --- application/views/qso/edit_ajax.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/application/views/qso/edit_ajax.php b/application/views/qso/edit_ajax.php index d5ea0d2b..e49c954d 100644 --- a/application/views/qso/edit_ajax.php +++ b/application/views/qso/edit_ajax.php @@ -187,7 +187,7 @@
- +
From b116f79ae587fa32a9c29521d015f1ed559ba2fe Mon Sep 17 00:00:00 2001 From: Andreas <6977712+AndreasK79@users.noreply.github.com> Date: Sat, 18 Nov 2023 08:35:16 +0100 Subject: [PATCH 20/22] Suppress error message in qslprint/qsolist if band is null --- application/views/qslprint/qsolist.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/application/views/qslprint/qsolist.php b/application/views/qslprint/qsolist.php index 3cbf6699..45710446 100644 --- a/application/views/qslprint/qsolist.php +++ b/application/views/qslprint/qsolist.php @@ -37,7 +37,7 @@ if ($qsos->result() != NULL) { echo ''; $timestamp = strtotime($qsl->COL_TIME_ON); echo date($custom_date_format, $timestamp); echo ''; echo ''; $timestamp = strtotime($qsl->COL_TIME_ON); echo date('H:i', $timestamp); echo ''; echo ''; echo $qsl->COL_SUBMODE==null?$qsl->COL_MODE:$qsl->COL_SUBMODE; echo ''; - echo ''; if($qsl->COL_SAT_NAME != null) { echo $qsl->COL_SAT_NAME; } else { echo strtolower($qsl->COL_BAND); }; echo ''; + echo ''; if($qsl->COL_SAT_NAME != null) { echo $qsl->COL_SAT_NAME; } else { echo strtolower($qsl->COL_BAND ?? ""); }; echo ''; echo '' . $qsl->station_callsign . ''; echo '' . $qsl->COL_QSL_VIA . ''; echo ''; echo_qsl_sent_via($qsl->COL_QSL_SENT_VIA); echo ''; From c2409ec5822e2903e3a7ea0204ef3f7673adcc06 Mon Sep 17 00:00:00 2001 From: HB9HIL Date: Mon, 20 Nov 2023 11:16:04 +0100 Subject: [PATCH 21/22] removed input classes to fix #2703 --- application/views/qso/edit_ajax.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/application/views/qso/edit_ajax.php b/application/views/qso/edit_ajax.php index e49c954d..dc81bf0a 100644 --- a/application/views/qso/edit_ajax.php +++ b/application/views/qso/edit_ajax.php @@ -55,12 +55,12 @@
- +
- +
From f2cbb58dc3efe63fe402aa2e7132a2be52cf7011 Mon Sep 17 00:00:00 2001 From: Peter Goodhall Date: Mon, 20 Nov 2023 14:29:48 +0000 Subject: [PATCH 22/22] tag 2.5.2 --- application/config/migration.php | 2 +- application/migrations/153_tag_2_5_2.php | 24 ++++++++++++++++++++++++ 2 files changed, 25 insertions(+), 1 deletion(-) create mode 100644 application/migrations/153_tag_2_5_2.php diff --git a/application/config/migration.php b/application/config/migration.php index a84fafcf..4a7774a3 100644 --- a/application/config/migration.php +++ b/application/config/migration.php @@ -22,7 +22,7 @@ $config['migration_enabled'] = TRUE; | */ -$config['migration_version'] = 152; +$config['migration_version'] = 153; /* |-------------------------------------------------------------------------- diff --git a/application/migrations/153_tag_2_5_2.php b/application/migrations/153_tag_2_5_2.php new file mode 100644 index 00000000..9be710c1 --- /dev/null +++ b/application/migrations/153_tag_2_5_2.php @@ -0,0 +1,24 @@ +db->where('option_name', 'version'); + $this->db->update('options', array('option_value' => '2.5.2')); + } + + public function down() + { + $this->db->where('option_name', 'version'); + $this->db->update('options', array('option_value' => '2.5.1')); + } +} \ No newline at end of file