Fix summary again. Add band in map legend

This commit is contained in:
Andreas Kristiansen
2026-02-25 08:29:05 +01:00
parent 3bd8a03534
commit 6cd41f6715
2 changed files with 7 additions and 3 deletions

View File

@@ -232,7 +232,9 @@
$addsat='<td>' . $band . '</td>';
}
}
echo '<td><b>' . __("Total (ex SAT)") . '</b></td>';
if ($posted_band != 'SAT') {
echo '<td><b>' . __("Total (ex SAT)") . '</b></td>';
}
if (count($bands) > 1) {
echo '<td class="spacingcell"></td>';
}
@@ -242,7 +244,7 @@
<tr><td>" . __("Total worked") . "</td>";
$sat_value = '';
foreach ($cq_summary['worked'] as $cqz => $value) { // Fills the table with the data
foreach ($cq_summary['worked'] as $cqz => $value) {
if ($posted_band == 'SAT' && $cqz == 'Total') {
continue;
}
@@ -260,7 +262,7 @@
echo "</tr><tr>
<td>" . __("Total confirmed") . "</td>";
$sat_value = '';
foreach ($cq_summary['confirmed'] as $cqz => $value) { // Fills the table with the data
foreach ($cq_summary['confirmed'] as $cqz => $value) {
if ($posted_band == 'SAT' && $cqz == 'Total') {
continue;
}

View File

@@ -119,6 +119,8 @@ function load_cq_map2(data) {
legend.onAdd = function(map) {
var div = L.DomUtil.create("div", "legend");
div.innerHTML += "<h4>" + lang_general_word_colors + "</h4>";
var band = $('#band2').val();
div.innerHTML += "<h4>Band: " + band + "</h4>";
div.innerHTML += "<i style='background: "+confirmedColor+"'></i><span>" + lang_general_word_confirmed + " (" + confirmed + ")</span><br>";
div.innerHTML += "<i style='background: "+workedColor+"'></i><span>" + lang_general_word_worked_not_confirmed + " (" + workednotconfirmed + ")</span><br>";
div.innerHTML += "<i style='background: "+unworkedColor+"'></i><span>" + lang_general_word_not_worked + " (" + notworked + ")</span><br>";