From fc7a9c7f5ae0247db1da9ab5d11e9925472a34f1 Mon Sep 17 00:00:00 2001 From: int2001 Date: Sun, 23 Jul 2023 18:02:04 +0000 Subject: [PATCH] Added kHz and spotter to list --- application/views/bandmap/list.php | 1 + assets/js/sections/bandmap_list.js | 7 ++++--- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/application/views/bandmap/list.php b/application/views/bandmap/list.php index a2c9c1c0..ab192bc2 100644 --- a/application/views/bandmap/list.php +++ b/application/views/bandmap/list.php @@ -77,6 +77,7 @@ DXCC + Spotter diff --git a/assets/js/sections/bandmap_list.js b/assets/js/sections/bandmap_list.js index f9ee2d69..c2a5227c 100644 --- a/assets/js/sections/bandmap_list.js +++ b/assets/js/sections/bandmap_list.js @@ -24,9 +24,10 @@ $(function() { var data=[]; data[0]=[]; data[0].push(single.when_pretty); - data[0].push(single.frequency); + data[0].push(single.frequency + " kHz"); data[0].push((single.worked_call ?'' : '')+single.spotted+(single.worked_call ? '' : '')); data[0].push(single.dxcc_spotted.entity); + data[0].push(single.spotter); if (oldtable.length > 0) { let update=false; oldtable.each( function (srow) { @@ -54,7 +55,7 @@ $(function() { var table=$('.spottable').DataTable(); table.rows().every(function() { var d=this.data(); - var distance=Math.abs(parseInt(d[1])-qrg); + var distance=Math.abs(parseInt(d[1].substring(0,d[1].length-4))-qrg); if (distance<=20) { distance++; alpha=(.5/distance); @@ -133,7 +134,7 @@ $(function() { } else { $(".radio_timeout_error" ).remove(); text = 'TX: '+(Math.round(parseInt(data.frequency)/100)/10000).toFixed(4)+' MHz'; - highlight_current_qrg((parseInt(data.frequency)/1000)); + highlight_current_qrg((parseInt(data.frequency))/1000); if(data.mode != null) { text = text+''+data.mode; }