From f5ba31df30be3364fefc8830f02c519bb54256cb Mon Sep 17 00:00:00 2001 From: Peter Goodhall Date: Tue, 11 Jun 2024 15:00:32 +0100 Subject: [PATCH 01/13] Update Information.php --- application/controllers/Information.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/application/controllers/Information.php b/application/controllers/Information.php index 42d4701c..061f825e 100644 --- a/application/controllers/Information.php +++ b/application/controllers/Information.php @@ -32,6 +32,8 @@ class Information extends CI_Controller // Check country files are present + // Information about Cloudlog Aurora + // If all is present welcome the user and redirect to the dashboard } } \ No newline at end of file From d99fc35a3bd91d3b6a936bc4a3a09b5f51e6bbed Mon Sep 17 00:00:00 2001 From: Emiliano Macedonio Date: Tue, 11 Jun 2024 17:35:15 +0200 Subject: [PATCH 02/13] Font correction Map Popup in Advanced Logbook --- assets/js/sections/logbookadvanced.js | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/assets/js/sections/logbookadvanced.js b/assets/js/sections/logbookadvanced.js index 98444002..b13acf1e 100644 --- a/assets/js/sections/logbookadvanced.js +++ b/assets/js/sections/logbookadvanced.js @@ -1012,11 +1012,11 @@ function loadMap(data) { var table = '' + '' + '" + '' + '"; return (table += "
' + - 'Station callsign: ' + qso.mycallsign + + '

' + qso.mycallsign + '

' + "
' + - 'Gridsquare: ' + qso.mygridsquare + + 'Gridsquare ' + qso.mygridsquare + "
"); } @@ -1024,41 +1024,41 @@ function loadMap(data) { function createContentMessageDx(qso) { var table = '' + '' + - '' + + '' + '' + '' + '' + - '' + + '' + '' + '' + ''; if (qso.satname != "") { - table += '' + + table += '' + '' + '' + ''; } else { - table += '' + + table += '' + '' + '' + ''; } - table += '' + + table += '' + '' + '' + ''; if (qso.gridsquare != undefined) { - table += '' + + table += '' + '' + ''; } if (qso.distance != undefined) { - table += '' + + table += '' + '' + ''; } if (qso.bearing != undefined) { - table += '' + + table += '' + '' + ''; } From a685b233c6a3a1ec706fbb01146c7b874d3da45c Mon Sep 17 00:00:00 2001 From: Danny Date: Sun, 16 Jun 2024 19:40:24 +0200 Subject: [PATCH 03/13] Distances worked analytics: bugfix and average distance --- application/language/bulgarian/statistics_lang.php | 4 +++- .../language/chinese_simplified/statistics_lang.php | 2 ++ application/language/czech/statistics_lang.php | 4 +++- application/language/dutch/statistics_lang.php | 4 +++- application/language/english/statistics_lang.php | 4 +++- application/language/finnish/statistics_lang.php | 4 +++- application/language/french/statistics_lang.php | 10 ++++++---- application/language/german/statistics_lang.php | 2 ++ application/language/greek/statistics_lang.php | 4 +++- application/language/italian/statistics_lang.php | 4 +++- application/language/polish/statistics_lang.php | 4 +++- application/language/russian/statistics_lang.php | 2 ++ application/language/spanish/statistics_lang.php | 4 +++- application/language/swedish/statistics_lang.php | 4 +++- application/language/turkish/statistics_lang.php | 4 +++- application/models/Distances_model.php | 12 +++++++++--- application/views/distances/index.php | 4 +++- assets/js/sections/distances.js | 3 ++- 18 files changed, 59 insertions(+), 20 deletions(-) diff --git a/application/language/bulgarian/statistics_lang.php b/application/language/bulgarian/statistics_lang.php index 97a2f0b9..70bb6103 100644 --- a/application/language/bulgarian/statistics_lang.php +++ b/application/language/bulgarian/statistics_lang.php @@ -25,10 +25,12 @@ $lang['statistics_number_of_qso_worked'] = "# of QSO's worked"; * */ +$lang['statistics_distances_bands_all'] = "All"; $lang['statistics_distances_worked'] = "Distances Worked"; $lang['statistics_distances_part1_contacts_were_plotted_furthest'] = "contacts were plotted.
Your furthest contact was with"; $lang['statistics_distances_part2_contacts_were_plotted_furthest'] = "in gridsquare"; -$lang['statistics_distances_part3_contacts_were_plotted_furthest'] = "the distance was"; +$lang['statistics_distances_part3_contacts_were_plotted_furthest'] = "The distance was"; +$lang['statistics_distances_part4_contacts_were_plotted_furthest'] = "The average distance is"; $lang['statistics_distances_number_of_qsos'] = "Number of QSOs"; $lang['statistics_distances_callsigns_worked'] = "Callsign(s) worked (max 5 shown)"; $lang['statistics_distances_qsos_with'] = "QSOs with"; diff --git a/application/language/chinese_simplified/statistics_lang.php b/application/language/chinese_simplified/statistics_lang.php index 6e8acf07..76c298c3 100644 --- a/application/language/chinese_simplified/statistics_lang.php +++ b/application/language/chinese_simplified/statistics_lang.php @@ -25,10 +25,12 @@ $lang['statistics_number_of_qso_worked'] = "通联的 QSO 数量"; * */ +$lang['statistics_distances_bands_all'] = "全部"; $lang['statistics_distances_worked'] = "通联距离"; $lang['statistics_distances_part1_contacts_were_plotted_furthest'] = "次通联
您最远的通联是与"; $lang['statistics_distances_part2_contacts_were_plotted_furthest'] = "在网格"; $lang['statistics_distances_part3_contacts_were_plotted_furthest'] = "距离是"; +$lang['statistics_distances_part4_contacts_were_plotted_furthest'] = "平均距离是"; $lang['statistics_distances_number_of_qsos'] = "QSO 数量"; $lang['statistics_distances_callsigns_worked'] = "通联的呼号(最多显示5个):"; $lang['statistics_distances_qsos_with'] = "QSO 与"; diff --git a/application/language/czech/statistics_lang.php b/application/language/czech/statistics_lang.php index f636a7d1..8ccc495d 100644 --- a/application/language/czech/statistics_lang.php +++ b/application/language/czech/statistics_lang.php @@ -25,10 +25,12 @@ $lang['statistics_number_of_qso_worked'] = "# of QSO's worked"; * */ +$lang['statistics_distances_bands_all'] = "All"; $lang['statistics_distances_worked'] = "Distances Worked"; $lang['statistics_distances_part1_contacts_were_plotted_furthest'] = "contacts were plotted.
Your furthest contact was with"; $lang['statistics_distances_part2_contacts_were_plotted_furthest'] = "in gridsquare"; -$lang['statistics_distances_part3_contacts_were_plotted_furthest'] = "the distance was"; +$lang['statistics_distances_part3_contacts_were_plotted_furthest'] = "The distance was"; +$lang['statistics_distances_part4_contacts_were_plotted_furthest'] = "The average distance is"; $lang['statistics_distances_number_of_qsos'] = "Number of QSOs"; $lang['statistics_distances_callsigns_worked'] = "Callsign(s) worked (max 5 shown)"; $lang['statistics_distances_qsos_with'] = "QSOs with"; diff --git a/application/language/dutch/statistics_lang.php b/application/language/dutch/statistics_lang.php index 62bfe00d..90d55860 100644 --- a/application/language/dutch/statistics_lang.php +++ b/application/language/dutch/statistics_lang.php @@ -25,10 +25,12 @@ $lang['statistics_number_of_qso_worked'] = "# of QSO's worked"; * */ +$lang['statistics_distances_bands_all'] = "All"; $lang['statistics_distances_worked'] = "Distances Worked"; $lang['statistics_distances_part1_contacts_were_plotted_furthest'] = "contacts were plotted.
Your furthest contact was with"; $lang['statistics_distances_part2_contacts_were_plotted_furthest'] = "in gridsquare"; -$lang['statistics_distances_part3_contacts_were_plotted_furthest'] = "the distance was"; +$lang['statistics_distances_part3_contacts_were_plotted_furthest'] = "The distance was"; +$lang['statistics_distances_part4_contacts_were_plotted_furthest'] = "The average distance is"; $lang['statistics_distances_number_of_qsos'] = "Number of QSOs"; $lang['statistics_distances_callsigns_worked'] = "Callsign(s) worked (max 5 shown)"; $lang['statistics_distances_qsos_with'] = "QSOs with"; diff --git a/application/language/english/statistics_lang.php b/application/language/english/statistics_lang.php index c995c0f2..a3576bf2 100644 --- a/application/language/english/statistics_lang.php +++ b/application/language/english/statistics_lang.php @@ -25,10 +25,12 @@ $lang['statistics_number_of_qso_worked'] = "# of QSO's worked"; * */ +$lang['statistics_distances_bands_all'] = "All"; $lang['statistics_distances_worked'] = "Distances Worked"; $lang['statistics_distances_part1_contacts_were_plotted_furthest'] = "contacts were plotted.
Your furthest contact was with"; $lang['statistics_distances_part2_contacts_were_plotted_furthest'] = "in gridsquare"; -$lang['statistics_distances_part3_contacts_were_plotted_furthest'] = "the distance was"; +$lang['statistics_distances_part3_contacts_were_plotted_furthest'] = "The distance was"; +$lang['statistics_distances_part4_contacts_were_plotted_furthest'] = "The average distance is"; $lang['statistics_distances_number_of_qsos'] = "Number of QSOs"; $lang['statistics_distances_callsigns_worked'] = "Callsign(s) worked (max 5 shown)"; $lang['statistics_distances_qsos_with'] = "QSOs with"; diff --git a/application/language/finnish/statistics_lang.php b/application/language/finnish/statistics_lang.php index c5b61102..c7811d6b 100644 --- a/application/language/finnish/statistics_lang.php +++ b/application/language/finnish/statistics_lang.php @@ -25,10 +25,12 @@ $lang['statistics_number_of_qso_worked'] = "# of QSO's worked"; * */ +$lang['statistics_distances_bands_all'] = "All"; $lang['statistics_distances_worked'] = "Distances Worked"; $lang['statistics_distances_part1_contacts_were_plotted_furthest'] = "contacts were plotted.
Your furthest contact was with"; $lang['statistics_distances_part2_contacts_were_plotted_furthest'] = "in gridsquare"; -$lang['statistics_distances_part3_contacts_were_plotted_furthest'] = "the distance was"; +$lang['statistics_distances_part3_contacts_were_plotted_furthest'] = "The distance was"; +$lang['statistics_distances_part4_contacts_were_plotted_furthest'] = "The average distance is"; $lang['statistics_distances_number_of_qsos'] = "Number of QSOs"; $lang['statistics_distances_callsigns_worked'] = "Callsign(s) worked (max 5 shown)"; $lang['statistics_distances_qsos_with'] = "QSOs with"; diff --git a/application/language/french/statistics_lang.php b/application/language/french/statistics_lang.php index c9631523..930bee8a 100644 --- a/application/language/french/statistics_lang.php +++ b/application/language/french/statistics_lang.php @@ -25,10 +25,12 @@ $lang['statistics_number_of_qso_worked'] = "QSOs réalisés"; * */ -$lang['statistics_distances_worked'] = "Nombre de QSOs par plage de distances réalisées"; -$lang['statistics_distances_part1_contacts_were_plotted_furthest'] = "contacts utilisés pour le graphique.
Le dernier contact réalisé est : "; -$lang['statistics_distances_part2_contacts_were_plotted_furthest'] = ", avec le locator : "; -$lang['statistics_distances_part3_contacts_were_plotted_furthest'] = ", pour une distance de : "; +$lang['statistics_distances_bands_all'] = "Toutes"; +$lang['statistics_distances_worked'] = "Nombre de QSOs réalisés par plage de distance"; +$lang['statistics_distances_part1_contacts_were_plotted_furthest'] = "contacts utilisés pour le graphique.
Le contact le plus lointain réalisé est "; +$lang['statistics_distances_part2_contacts_were_plotted_furthest'] = "avec le locator"; +$lang['statistics_distances_part3_contacts_were_plotted_furthest'] = "La distance maximale est de"; +$lang['statistics_distances_part4_contacts_were_plotted_furthest'] = "La distance moyenne est de"; $lang['statistics_distances_number_of_qsos'] = "Nombre de QSOs"; $lang['statistics_distances_callsigns_worked'] = "Indicatif(s) contacté(s) (liste de 5 max)"; $lang['statistics_distances_qsos_with'] = "QSOs avec"; diff --git a/application/language/german/statistics_lang.php b/application/language/german/statistics_lang.php index f91e0d98..aa0071b1 100644 --- a/application/language/german/statistics_lang.php +++ b/application/language/german/statistics_lang.php @@ -25,10 +25,12 @@ $lang['statistics_number_of_qso_worked'] = "# gearbeitete QSOs"; * */ +$lang['statistics_distances_bands_all'] = "Alle"; $lang['statistics_distances_worked'] = "Gearbeitete Entfernungen"; $lang['statistics_distances_part1_contacts_were_plotted_furthest'] = "Kontakte wurden dargestellt.
Der weiteste Kontakt war"; // make sure'
' stays there $lang['statistics_distances_part2_contacts_were_plotted_furthest'] = "im Planquadrat"; $lang['statistics_distances_part3_contacts_were_plotted_furthest'] = "Die Distanz betrug"; +$lang['statistics_distances_part4_contacts_were_plotted_furthest'] = "Die durchschnittliche Distanz ist"; $lang['statistics_distances_number_of_qsos'] = "Anzahl der QSOs"; $lang['statistics_distances_callsigns_worked'] = "Gearbeitete(s) Rufzeichen (max 5 werden gezeigt)"; $lang['statistics_distances_qsos_with'] = "QSOs mit"; diff --git a/application/language/greek/statistics_lang.php b/application/language/greek/statistics_lang.php index c995c0f2..a3576bf2 100644 --- a/application/language/greek/statistics_lang.php +++ b/application/language/greek/statistics_lang.php @@ -25,10 +25,12 @@ $lang['statistics_number_of_qso_worked'] = "# of QSO's worked"; * */ +$lang['statistics_distances_bands_all'] = "All"; $lang['statistics_distances_worked'] = "Distances Worked"; $lang['statistics_distances_part1_contacts_were_plotted_furthest'] = "contacts were plotted.
Your furthest contact was with"; $lang['statistics_distances_part2_contacts_were_plotted_furthest'] = "in gridsquare"; -$lang['statistics_distances_part3_contacts_were_plotted_furthest'] = "the distance was"; +$lang['statistics_distances_part3_contacts_were_plotted_furthest'] = "The distance was"; +$lang['statistics_distances_part4_contacts_were_plotted_furthest'] = "The average distance is"; $lang['statistics_distances_number_of_qsos'] = "Number of QSOs"; $lang['statistics_distances_callsigns_worked'] = "Callsign(s) worked (max 5 shown)"; $lang['statistics_distances_qsos_with'] = "QSOs with"; diff --git a/application/language/italian/statistics_lang.php b/application/language/italian/statistics_lang.php index a38b9128..8c412c23 100644 --- a/application/language/italian/statistics_lang.php +++ b/application/language/italian/statistics_lang.php @@ -25,10 +25,12 @@ $lang['statistics_number_of_qso_worked'] = "# di QSO effettuati"; * */ +$lang['statistics_distances_bands_all'] = "Tutte"; $lang['statistics_distances_worked'] = "Distanze percorse"; $lang['statistics_distances_part1_contacts_were_plotted_furthest'] = "i contatti sono stati tracciati.
Il tuo contatto più lontano era con"; $lang['statistics_distances_part2_contacts_were_plotted_furthest'] = "nella griglia"; -$lang['statistics_distances_part3_contacts_were_plotted_furthest'] = "la distanza era"; +$lang['statistics_distances_part3_contacts_were_plotted_furthest'] = "La distanza era"; +$lang['statistics_distances_part4_contacts_were_plotted_furthest'] = "La distanza media è"; $lang['statistics_distances_number_of_qsos'] = "Numero di QSO"; $lang['statistics_distances_callsigns_worked'] = "Nominativo(i) funzionante(i max 5 mostrati)"; $lang['statistics_distances_qsos_with'] = "QSO con"; diff --git a/application/language/polish/statistics_lang.php b/application/language/polish/statistics_lang.php index c995c0f2..a3576bf2 100644 --- a/application/language/polish/statistics_lang.php +++ b/application/language/polish/statistics_lang.php @@ -25,10 +25,12 @@ $lang['statistics_number_of_qso_worked'] = "# of QSO's worked"; * */ +$lang['statistics_distances_bands_all'] = "All"; $lang['statistics_distances_worked'] = "Distances Worked"; $lang['statistics_distances_part1_contacts_were_plotted_furthest'] = "contacts were plotted.
Your furthest contact was with"; $lang['statistics_distances_part2_contacts_were_plotted_furthest'] = "in gridsquare"; -$lang['statistics_distances_part3_contacts_were_plotted_furthest'] = "the distance was"; +$lang['statistics_distances_part3_contacts_were_plotted_furthest'] = "The distance was"; +$lang['statistics_distances_part4_contacts_were_plotted_furthest'] = "The average distance is"; $lang['statistics_distances_number_of_qsos'] = "Number of QSOs"; $lang['statistics_distances_callsigns_worked'] = "Callsign(s) worked (max 5 shown)"; $lang['statistics_distances_qsos_with'] = "QSOs with"; diff --git a/application/language/russian/statistics_lang.php b/application/language/russian/statistics_lang.php index ba34b9fd..127d9f17 100644 --- a/application/language/russian/statistics_lang.php +++ b/application/language/russian/statistics_lang.php @@ -25,10 +25,12 @@ $lang['statistics_number_of_qso_worked'] = "# QSO проведено"; * */ +$lang['statistics_distances_bands_all'] = "все"; $lang['statistics_distances_worked'] = "Сработанные дистанции"; $lang['statistics_distances_part1_contacts_were_plotted_furthest'] = "контакты отображены.
Наиболее дальний контакт с"; $lang['statistics_distances_part2_contacts_were_plotted_furthest'] = "в квадрате"; $lang['statistics_distances_part3_contacts_were_plotted_furthest'] = "на дистанции"; +$lang['statistics_distances_part4_contacts_were_plotted_furthest'] = "Среднее расстояние составляет"; $lang['statistics_distances_number_of_qsos'] = "Количество QSO"; $lang['statistics_distances_callsigns_worked'] = "Сработанные позывные(ной) (максимально 5 показано)"; $lang['statistics_distances_qsos_with'] = "QSOs с"; diff --git a/application/language/spanish/statistics_lang.php b/application/language/spanish/statistics_lang.php index d0928382..719734dd 100644 --- a/application/language/spanish/statistics_lang.php +++ b/application/language/spanish/statistics_lang.php @@ -25,10 +25,12 @@ $lang['statistics_number_of_qso_worked'] = "# de QSOs logradas"; * */ +$lang['statistics_distances_bands_all'] = "Todas"; $lang['statistics_distances_worked'] = "Distancias Logradas"; $lang['statistics_distances_part1_contacts_were_plotted_furthest'] = "contactos fueron dibujados.
Su contacto más lejano fue con"; $lang['statistics_distances_part2_contacts_were_plotted_furthest'] = "en gridsquare"; -$lang['statistics_distances_part3_contacts_were_plotted_furthest'] = "la distancia fue"; +$lang['statistics_distances_part3_contacts_were_plotted_furthest'] = "La distancia fue"; +$lang['statistics_distances_part4_contacts_were_plotted_furthest'] = "La distancia promedio es"; $lang['statistics_distances_number_of_qsos'] = "Número de QSOs"; $lang['statistics_distances_callsigns_worked'] = "Indicativo(s) trabajados (se muestran máximo 5)"; $lang['statistics_distances_qsos_with'] = "QSOs con"; diff --git a/application/language/swedish/statistics_lang.php b/application/language/swedish/statistics_lang.php index 05419132..66b5fc30 100644 --- a/application/language/swedish/statistics_lang.php +++ b/application/language/swedish/statistics_lang.php @@ -25,10 +25,12 @@ $lang['statistics_number_of_qso_worked'] = "# of QSO's worked"; * */ +$lang['statistics_distances_bands_all'] = "All"; $lang['statistics_distances_worked'] = "Distances Worked"; $lang['statistics_distances_part1_contacts_were_plotted_furthest'] = "contacts were plotted.
Your furthest contact was with"; $lang['statistics_distances_part2_contacts_were_plotted_furthest'] = "in gridsquare"; -$lang['statistics_distances_part3_contacts_were_plotted_furthest'] = "the distance was"; +$lang['statistics_distances_part3_contacts_were_plotted_furthest'] = "The distance was"; +$lang['statistics_distances_part4_contacts_were_plotted_furthest'] = "The average distance is"; $lang['statistics_distances_number_of_qsos'] = "Number of QSOs"; $lang['statistics_distances_callsigns_worked'] = "Callsign(s) worked (max 5 shown)"; $lang['statistics_distances_qsos_with'] = "QSOs with"; diff --git a/application/language/turkish/statistics_lang.php b/application/language/turkish/statistics_lang.php index 845318ed..6f068169 100644 --- a/application/language/turkish/statistics_lang.php +++ b/application/language/turkish/statistics_lang.php @@ -25,10 +25,12 @@ $lang['statistics_number_of_qso_worked'] = "Çalışan QSO sayısı"; * */ +$lang['statistics_distances_bands_all'] = "Tüm"; $lang['statistics_distances_worked'] = "Çalışılan Mesafeler"; $lang['statistics_distances_part1_contacts_were_plotted_furthest'] = "kişiler planlandı.
En uzak bağlantınız şununlaydı"; $lang['statistics_distances_part2_contacts_were_plotted_furthest'] = "gridsquare'de"; -$lang['statistics_distances_part3_contacts_were_plotted_furthest'] = "mesafe şuydu"; +$lang['statistics_distances_part3_contacts_were_plotted_furthest'] = "Mesafe şuydu"; +$lang['statistics_distances_part4_contacts_were_plotted_furthest'] = "Ortalama mesafe"; $lang['statistics_distances_number_of_qsos'] = "QSO sayısı"; $lang['statistics_distances_callsigns_worked'] = "Çağrı işaretleri çalıştı (en fazla 5 tane gösterildi)"; $lang['statistics_distances_qsos_with'] = "QSO'lar ile"; diff --git a/application/models/Distances_model.php b/application/models/Distances_model.php index 3aa17c0c..d895a019 100644 --- a/application/models/Distances_model.php +++ b/application/models/Distances_model.php @@ -33,7 +33,7 @@ class Distances_model extends CI_Model $this->db->where('col_sat_name', $postdata['sat']); } } - else { + elseif ($postdata['band'] != 'all') { $this->db->where('col_band', $postdata['band']); } @@ -143,7 +143,7 @@ class Distances_model extends CI_Model $dist = '20000'; } - if (!$this->valid_locator($stationgrid)) { + if (!$this->valid_locator(substr($stationgrid, 0, 6))) { header('Content-Type: application/json'); echo json_encode(array('Error' => 'Error. There is a problem with the gridsquare set in your profile!')); exit; @@ -163,12 +163,16 @@ class Distances_model extends CI_Model 'Grid' => '', 'Distance' => '', 'Qsos' => '', - 'Grids' => '' + 'Grids' => '', + 'Avg_distance' => '' ); + $avg_distance = 0; + foreach ($qsoArray as $qso) { $qrb['Qsos']++; // Counts up number of qsos $bearingdistance = $this->qra->distance($stationgrid, $qso['grid'], $measurement_base); + $avg_distance += ($bearingdistance - $avg_distance) / $qrb['Qsos']; // Calculates running average of distance if ($bearingdistance != $qso['COL_DISTANCE']) { $data = array('COL_DISTANCE' => $bearingdistance); $this->db->where('COL_PRIMARY_KEY', $qso['COL_PRIMARY_KEY']); @@ -190,6 +194,8 @@ class Distances_model extends CI_Model } } + $qrb['Avg_distance'] = round($avg_distance, 1); + $data['ok'] = 'OK'; $data['qrb'] = $qrb; $data['qsodata'] = $dataarray; diff --git a/application/views/distances/index.php b/application/views/distances/index.php index ad1f7e9c..3313c649 100644 --- a/application/views/distances/index.php +++ b/application/views/distances/index.php @@ -9,6 +9,7 @@ var lang_statistics_distances_part1_contacts_were_plotted_furthest = ''; var lang_statistics_distances_part2_contacts_were_plotted_furthest = ''; var lang_statistics_distances_part3_contacts_were_plotted_furthest = ''; + var lang_statistics_distances_part4_contacts_were_plotted_furthest = ''; var lang_statistics_distances_number_of_qsos = ''; var lang_gen_hamradio_distance = ''; var lang_statistics_distances_callsigns_worked = ''; @@ -18,6 +19,7 @@
- ' . $sat . ''."\n"; diff --git a/assets/js/sections/distances.js b/assets/js/sections/distances.js index 56cf1e03..961bb6cb 100644 --- a/assets/js/sections/distances.js +++ b/assets/js/sections/distances.js @@ -117,7 +117,8 @@ function distPlot(form) { $('#information').html(tmp.qrb.Qsos + " " + lang_statistics_distances_part1_contacts_were_plotted_furthest + " " + tmp.qrb.Callsign + " " + lang_statistics_distances_part2_contacts_were_plotted_furthest + " " + tmp.qrb.Grid +". " + lang_statistics_distances_part3_contacts_were_plotted_furthest + " " - + tmp.qrb.Distance + tmp.unit + "."); + + tmp.qrb.Distance + " " + tmp.unit + ". " + lang_statistics_distances_part4_contacts_were_plotted_furthest + " " + + tmp.qrb.Avg_distance + " " + tmp.unit + "."); var chart = new Highcharts.Chart(options); } From 6c76a47a7d752adb1e0cb5c9b7d15c7af3bc439b Mon Sep 17 00:00:00 2001 From: PA8S Date: Sun, 16 Jun 2024 22:32:36 +0200 Subject: [PATCH 04/13] Corrected labels for awards_wab_description_ln1 and awards_wab_description_ln4 for WAB in language files --- application/language/bulgarian/awards_lang.php | 6 +++--- application/language/chinese_simplified/awards_lang.php | 6 +++--- application/language/czech/awards_lang.php | 6 +++--- application/language/dutch/awards_lang.php | 6 +++--- application/language/english/awards_lang.php | 6 +++--- application/language/finnish/awards_lang.php | 6 +++--- application/language/french/awards_lang.php | 6 +++--- application/language/german/awards_lang.php | 6 +++--- application/language/greek/awards_lang.php | 6 +++--- application/language/italian/awards_lang.php | 6 +++--- application/language/polish/awards_lang.php | 6 +++--- application/language/russian/awards_lang.php | 6 +++--- application/language/spanish/awards_lang.php | 6 +++--- application/language/swedish/awards_lang.php | 6 +++--- application/language/turkish/awards_lang.php | 6 +++--- 15 files changed, 45 insertions(+), 45 deletions(-) diff --git a/application/language/bulgarian/awards_lang.php b/application/language/bulgarian/awards_lang.php index 035cce79..23dfe8e4 100644 --- a/application/language/bulgarian/awards_lang.php +++ b/application/language/bulgarian/awards_lang.php @@ -196,10 +196,10 @@ $lang['awards_waja_description_ln4'] = "For more information, please visit: https://www.jarl.org/English/4_Library/A-4-2_Awards/Award_Main.htm."; /* ___________________________________________________________________________________________ -WAB -- Use all 3 Lines of Text +WAB -- Use all 4 Lines of Text ___________________________________________________________________________________________ */ -$lang['awards_waja_description_ln1'] = "WAB - Worked All Britain Award"; +$lang['awards_wab_description_ln1'] = "WAB - Worked All Britain Award"; $lang['awards_wab_description_ln2'] = "The Amateur Radio Worked All Britain (WAB) Award is a prestigious recognition program within the amateur radio community that celebrates communication achievements across the United Kingdom. The WAB Award scheme encourages radio operators to establish contact with stations located in different regions of Britain, fostering camaraderie and promoting radio communication skills. To earn the WAB Award, participants must make successful radio contacts with stations located in specific WAB areas, which are defined by Ordnance Survey grid squares. These grid squares cover the entirety of Great Britain, including England, Scotland, Wales, and some offshore islands."; $lang['awards_wab_description_ln3'] = "Participants in the WAB Award program exchange information such as their location, signal strength, and WAB square reference during radio contacts. Points are awarded based on the location of the contacted station, with different point values assigned to contacts made within different WAB areas. By accumulating points from successful contacts, radio operators can progress through various award levels, each representing a significant milestone in their amateur radio journey. The WAB Award not only recognizes the dedication and skill of radio operators but also promotes geographic diversity and encourages exploration of the rich tapestry of locations across Britain through the medium of amateur radio."; -$lang['awards_waja_description_ln4'] = "For more information, please visit: https://wab.intermip.net/default.php."; +$lang['awards_wab_description_ln4'] = "For more information, please visit: https://wab.intermip.net/default.php."; diff --git a/application/language/dutch/awards_lang.php b/application/language/dutch/awards_lang.php index 502ff497..6115045c 100644 --- a/application/language/dutch/awards_lang.php +++ b/application/language/dutch/awards_lang.php @@ -196,10 +196,10 @@ $lang['awards_waja_description_ln4'] = "For more information, please visit: https://www.jarl.org/English/4_Library/A-4-2_Awards/Award_Main.htm."; /* ___________________________________________________________________________________________ -WAB -- Use all 3 Lines of Text +WAB -- Use all 4 Lines of Text ___________________________________________________________________________________________ */ -$lang['awards_waja_description_ln1'] = "WAB - Worked All Britain Award"; +$lang['awards_wab_description_ln1'] = "WAB - Worked All Britain Award"; $lang['awards_wab_description_ln2'] = "Il Worked All Britain Award (WAB) è un prestigioso programma di riconoscimento all\'interno della comunità dei radioamatori che celebra i risultati ottenuti nella comunicazione in tutto il Regno Unito. Il programma del premio WAB incoraggia gli operatori radio a stabilire un contatto con le stazioni situati in diverse regioni della Gran Bretagna, favorendo il cameratismo e promuovendo le capacità di comunicazione radiofonica. Per ottenere il premio WAB, i partecipanti devono stabilire contatti radio con successo con stazioni situate in aree WAB specifiche, definite dai quadrati della griglia dell\'Ordnance Survey. Questi quadrati della griglia coprono l\'intero della Gran Bretagna, tra cui Inghilterra, Scozia, Galles e alcune isole al largo."; $lang['awards_wab_description_ln3'] = "I partecipanti al programma WAB Award si scambiano informazioni come la loro posizione, la potenza del segnale e il riferimento quadrato WAB durante i contatti radio. I punti vengono assegnati in base alla posizione della stazione contattata, con diversi valori in punti assegnati ai contatti effettuati all\'interno di diverse aree WAB Accumulando punti dai contatti riusciti, gli operatori radiofonici possono progredire attraverso vari livelli di premio, ognuno dei quali rappresenta una pietra miliare significativa nel loro viaggio radioamatoriale. Il Premio WAB non solo riconosce la dedizione e l\'abilità degli operatori radiofonici, ma anche promuove la diversità geografica e incoraggia l\'esplorazione del ricco mosaico di luoghi in tutta la Gran Bretagna attraverso il mezzo della radio amatoriale."; -$lang['awards_waja_description_ln4'] = "Per ulteriori informazioni, visitare: https://wab.intermip.net /default.php."; +$lang['awards_wab_description_ln4'] = "Per ulteriori informazioni, visitare: https://wab.intermip.net /default.php."; diff --git a/application/language/polish/awards_lang.php b/application/language/polish/awards_lang.php index 502ff497..6115045c 100644 --- a/application/language/polish/awards_lang.php +++ b/application/language/polish/awards_lang.php @@ -196,10 +196,10 @@ $lang['awards_waja_description_ln4'] = "For more information, please visit: Date: Wed, 19 Jun 2024 13:46:31 +0100 Subject: [PATCH 05/13] [Dashboard] Fixes JS errors when loading map when theres no qsos --- application/controllers/Map.php | 26 +++++++--- application/views/interface_assets/footer.php | 50 ++++++++++--------- 2 files changed, 45 insertions(+), 31 deletions(-) diff --git a/application/controllers/Map.php b/application/controllers/Map.php index 456b23cb..d26fe437 100644 --- a/application/controllers/Map.php +++ b/application/controllers/Map.php @@ -80,13 +80,23 @@ class Map extends CI_Controller { $offset = (intval($this->input->post('offset'))>0)?xss_clean($this->input->post('offset')):null; $qsos = $this->logbook_model->get_qsos($nb_qso, $offset); } - // [PLOT] ADD plot // - $plot_array = $this->logbook_model->get_plot_array_for_map($qsos->result()); - // [MAP Custom] ADD Station // - $station_array = $this->Stations->get_station_array_for_map(); - header('Content-Type: application/json; charset=utf-8'); - echo json_encode(array_merge($plot_array, $station_array)); - } + if(empty($qsos)) { + // Handle the case where $qsos is empty -} + // return json with error "No QSOs found" + header('Content-Type: application/json; charset=utf-8'); + echo json_encode(array('error' => 'No QSOs found')); + } else { + // Handle the case where $qsos is not empty + // [PLOT] ADD plot // + $plot_array = $this->logbook_model->get_plot_array_for_map($qsos->result()); + // [MAP Custom] ADD Station // + $station_array = $this->Stations->get_station_array_for_map(); + + header('Content-Type: application/json; charset=utf-8'); + echo json_encode(array_merge($plot_array, $station_array)); + } + + } +} \ No newline at end of file diff --git a/application/views/interface_assets/footer.php b/application/views/interface_assets/footer.php index 846d6167..e355472b 100644 --- a/application/views/interface_assets/footer.php +++ b/application/views/interface_assets/footer.php @@ -895,30 +895,34 @@ if ($this->session->userdata('user_id') != null) { fetch(qso_loc) .then(response => response.json()) .then(data => { - var newMarkers = {}; - data.markers.forEach(marker => { - var key = `${marker.lat},${marker.lng}`; - var html = `

${marker.flag}${marker.label}

${marker.html}`; - newMarkers[key] = marker; - if (!markers[key]) { - var icon = L.divIcon({ - className: 'custom-icon', - html: `` - }); - - L.marker([marker.lat, marker.lng], { - icon: icon - }) - .addTo(map) - .bindPopup(html); + if (data.error !== "No QSOs found") { + var newMarkers = {}; + data.markers.forEach(marker => { + var key = `${marker.lat},${marker.lng}`; + var html = `

${marker.flag}${marker.label}

${marker.html}`; + newMarkers[key] = marker; + if (!markers[key]) { + var icon = L.divIcon({ + className: 'custom-icon', + html: `` + }); + + L.marker([marker.lat, marker.lng], { + icon: icon + }) + .addTo(map) + .bindPopup(html); + } + }); + Object.keys(markers).forEach(key => { + if (!newMarkers[key]) { + map.removeLayer(markers[key]); + } + }); + markers = newMarkers; + } else { + console.log("No QSOs found to populate dashboard map."); } - }); - Object.keys(markers).forEach(key => { - if (!newMarkers[key]) { - map.removeLayer(markers[key]); - } - }); - markers = newMarkers; }); } From 4ca9268bf86834c5199cfc0835395cb617e05de8 Mon Sep 17 00:00:00 2001 From: Peter Goodhall Date: Wed, 19 Jun 2024 13:57:31 +0100 Subject: [PATCH 06/13] Update cypress-tests.yml --- .github/workflows/cypress-tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/cypress-tests.yml b/.github/workflows/cypress-tests.yml index a8a2c9e7..85d00363 100644 --- a/.github/workflows/cypress-tests.yml +++ b/.github/workflows/cypress-tests.yml @@ -1,5 +1,5 @@ name: Cypress Tests -on: [pull_request] +on: [pull_request, workflow_dispatch] jobs: cypress-e2e-tests: runs-on: ubuntu-latest From df6538afa37b6a3f70109039f0ef82a51a9faf71 Mon Sep 17 00:00:00 2001 From: Peter Goodhall Date: Wed, 19 Jun 2024 14:03:41 +0100 Subject: [PATCH 07/13] [Station Locations] Fixed JS error extra " --- assets/js/sections/station_locations.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/assets/js/sections/station_locations.js b/assets/js/sections/station_locations.js index ba2061a5..7e67e16c 100644 --- a/assets/js/sections/station_locations.js +++ b/assets/js/sections/station_locations.js @@ -44,7 +44,7 @@ $(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, #venezuela_state, #australia_state, #png_state, #nz_state, #belgium_state, #italy_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, #italy_state").hide(); /** * Gets the selected DXCC ID and shows the corresponding state. */ @@ -68,7 +68,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, #belgium_state, #italy_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, #italy_state").hide(); // Show the selected state $("#" + stateToShow).show(); From ccb9f592b3fcd5be0eb5fcb44c5fbbd24ec996a1 Mon Sep 17 00:00:00 2001 From: Peter Goodhall Date: Wed, 19 Jun 2024 14:29:01 +0100 Subject: [PATCH 08/13] [Gridsquare Map] Shows 2,4,6 grids Fixes #3136 --- application/controllers/Gridmap.php | 21 +++++++-------------- assets/js/sections/gridmap.js | 1 + 2 files changed, 8 insertions(+), 14 deletions(-) diff --git a/application/controllers/Gridmap.php b/application/controllers/Gridmap.php index 07590626..b726bd00 100644 --- a/application/controllers/Gridmap.php +++ b/application/controllers/Gridmap.php @@ -76,9 +76,7 @@ class Gridmap extends CI_Controller { foreach ($query->result() as $row) { $grid_2char_confirmed = strtoupper(substr($row->GRID_SQUARES,0,2)); $grid_4char_confirmed = strtoupper(substr($row->GRID_SQUARES,0,4)); - if ($this->config->item('map_6digit_grids')) { - $grid_6char_confirmed = strtoupper(substr($row->GRID_SQUARES,0,6)); - } + $grid_6char_confirmed = strtoupper(substr($row->GRID_SQUARES,0,6)); // Check if 2 Char is in array if(!in_array($grid_2char_confirmed, $array_grid_2char_confirmed)){ @@ -89,10 +87,8 @@ class Gridmap extends CI_Controller { array_push($array_grid_4char_confirmed, $grid_4char_confirmed); } - if ($this->config->item('map_6digit_grids')) { - if(!in_array($grid_6char_confirmed, $array_grid_6char_confirmed)){ + if(!in_array($grid_6char_confirmed, $array_grid_6char_confirmed)){ array_push($array_grid_6char_confirmed, $grid_6char_confirmed); - } } } } @@ -104,9 +100,7 @@ class Gridmap extends CI_Controller { $grid_two = strtoupper(substr($row->GRID_SQUARES,0,2)); $grid_four = strtoupper(substr($row->GRID_SQUARES,0,4)); - if ($this->config->item('map_6digit_grids')) { - $grid_six = strtoupper(substr($row->GRID_SQUARES,0,6)); - } + $grid_six = strtoupper(substr($row->GRID_SQUARES,0,6)); // Check if 2 Char is in array if(!in_array($grid_two, $array_grid_2char)){ @@ -116,12 +110,11 @@ class Gridmap extends CI_Controller { if(!in_array($grid_four, $array_grid_4char)){ array_push($array_grid_4char, $grid_four); } - - if ($this->config->item('map_6digit_grids')) { - if(!in_array($grid_six, $array_grid_6char)){ - array_push($array_grid_6char, $grid_six); - } + + if(!in_array($grid_six, $array_grid_6char)){ + array_push($array_grid_6char, $grid_six); } + } } $query_vucc = $this->gridmap_model->get_band_worked_vucc_squares($band, $mode, $qsl, $lotw, $eqsl, $qrz, $sat); diff --git a/assets/js/sections/gridmap.js b/assets/js/sections/gridmap.js index 3335d444..55d096a2 100644 --- a/assets/js/sections/gridmap.js +++ b/assets/js/sections/gridmap.js @@ -55,6 +55,7 @@ function gridPlot(form, visitor=true) { sat: $("#sats").val(), }, success: function (data) { + console.log(data); $('.cohidden').show(); $(".ld-ext-right-plot").removeClass('running'); $(".ld-ext-right-plot").prop('disabled', false); From 24f3b3397c206f53b6995377d776ee01e0d92b72 Mon Sep 17 00:00:00 2001 From: Peter Goodhall Date: Wed, 19 Jun 2024 14:34:31 +0100 Subject: [PATCH 09/13] [API] When looking up a grid only do first 4 chars --- application/models/Logbook_model.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/application/models/Logbook_model.php b/application/models/Logbook_model.php index 61f3129b..b365038b 100755 --- a/application/models/Logbook_model.php +++ b/application/models/Logbook_model.php @@ -2037,6 +2037,9 @@ class Logbook_model extends CI_Model $logbooks_locations_array = $StationLocationsArray; } + // Only take the first 4 characters of the grid + $grid = substr($grid, 0, 4); + $this->db->select('COL_GRIDSQUARE'); $this->db->where_in('station_id', $logbooks_locations_array); $this->db->group_start(); From 05f4f4ea925dc110f1da81f144cc140cb6092525 Mon Sep 17 00:00:00 2001 From: Emiliano Macedonio Date: Wed, 19 Jun 2024 16:13:22 +0200 Subject: [PATCH 10/13] Add Message alert in Advanced Logbook --- assets/js/sections/logbookadvanced.js | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/assets/js/sections/logbookadvanced.js b/assets/js/sections/logbookadvanced.js index b13acf1e..0c8a6fa5 100644 --- a/assets/js/sections/logbookadvanced.js +++ b/assets/js/sections/logbookadvanced.js @@ -616,7 +616,15 @@ $(document).ready(function () { var elements = $('#qsoList tbody input:checked'); var nElements = elements.length; if (nElements == 0) { - return; + BootstrapDialog.alert({ + title: 'INFO', + message: 'Select a row from the list for Quickfilter search.', + type: BootstrapDialog.TYPE_INFO, + closable: false, + draggable: false, + callback: function (result) { + } + }); } if (nElements > 1) { BootstrapDialog.alert({ From 12c271f5b9237370ceef54290c383e5aabeb1e8d Mon Sep 17 00:00:00 2001 From: Emiliano Macedonio Date: Thu, 20 Jun 2024 12:37:40 +0200 Subject: [PATCH 11/13] New menu item for Third Party Logbooks Realign submenu popup for correct visualization in Portrait screen Review some wrong icon in dropdown menu --- application/views/interface_assets/header.php | 85 ++++++++++--------- assets/css/general.css | 4 +- 2 files changed, 46 insertions(+), 43 deletions(-) diff --git a/application/views/interface_assets/header.php b/application/views/interface_assets/header.php index 86eb46cc..4f674446 100644 --- a/application/views/interface_assets/header.php +++ b/application/views/interface_assets/header.php @@ -77,11 +77,11 @@
@@ -113,15 +113,15 @@ @@ -326,23 +326,37 @@ - + - + - + -
CallsignCallsign' + qso.callsign + '
Date/timeDate/time' + qso.datetime + '
BandBand' + qso.satname + '
BandBand' + qso.band + '
ModeMode' + qso.mode + '
GridsquareGridsquare' + qso.gridsquare + '
DistanceDistance' + qso.distance + '
BearingBearing' + qso.bearing + '