mirror of
https://git.ianrenton.com/ian/spothole.git
synced 2025-10-27 08:49:27 +00:00
ZLOTA support + misc changes
This commit is contained in:
@@ -111,6 +111,12 @@ function updateTable() {
|
||||
sig_refs = s["sig_refs"].map(s => `<span class='nowrap'>${s}</span>`).join(", ");
|
||||
}
|
||||
|
||||
// Format sig_refs title
|
||||
var sig_refs_title_string = "";
|
||||
if (s["sig_refs_names"]) {
|
||||
sig_refs_title_string = " title=\"" + s["sig_refs_names"].join(", ") + "\"";
|
||||
}
|
||||
|
||||
// Format DE flag
|
||||
var de_flag = "<i class='fa-solid fa-circle-question'></i>";
|
||||
if (s["de_flag"] && s["de_flag"] != null && s["de_flag"] != "") {
|
||||
@@ -123,6 +129,13 @@ function updateTable() {
|
||||
de_country = "Unknown or not a country";
|
||||
}
|
||||
|
||||
// Format de call
|
||||
var de_call = s["de_call"];
|
||||
if (de_call == null) {
|
||||
de_call = "";
|
||||
de_flag = "";
|
||||
}
|
||||
|
||||
// CSS doesn't like classes with decimal points in, so we need to replace that in the same way as when we originally
|
||||
// queried the options endpoint and set our CSS.
|
||||
var cssFormattedBandName = s['band'] ? s['band'].replace('.', 'p') : "unknown";
|
||||
@@ -135,8 +148,8 @@ function updateTable() {
|
||||
$tr.append(`<td class='nowrap'>${mode_string}</td>`);
|
||||
$tr.append(`<td class='hideonmobile'>${commentText}</td>`);
|
||||
$tr.append(`<td class='nowrap hideonmobile'><span class='icon-wrapper'><i class='fa-solid fa-${s["icon"]}'></i></span> ${sigSourceText}</td>`);
|
||||
$tr.append(`<td class='hideonmobile'>${sig_refs}</td>`);
|
||||
$tr.append(`<td class='nowrap hideonmobile'><span class='flag-wrapper' title='${de_country}'>${de_flag}</span>${s["de_call"]}</td>`);
|
||||
$tr.append(`<td class='hideonmobile'><span ${sig_refs_title_string}>${sig_refs}</span></td>`);
|
||||
$tr.append(`<td class='nowrap hideonmobile'><span class='flag-wrapper' title='${de_country}'>${de_flag}</span>${de_call}</td>`);
|
||||
table.find('tbody').append($tr);
|
||||
|
||||
// Second row for mobile view only, containing source, ref & comment
|
||||
|
||||
Reference in New Issue
Block a user