diff --git a/assets/js/sections/bandmap_list.js b/assets/js/sections/bandmap_list.js index 28e104aa..54732520 100644 --- a/assets/js/sections/bandmap_list.js +++ b/assets/js/sections/bandmap_list.js @@ -15,6 +15,12 @@ $(function() { 'createdCell': function (td, cellData, rowData, row, col) { $(td).addClass("kHz"); } + }, + { + 'targets': 2, + 'createdCell': function (td, cellData, rowData, row, col) { + $(td).addClass("spotted_call"); + } } ] }); @@ -112,6 +118,12 @@ $(function() { } }); + $(document).on('click','.spotted_call', function() { + var bc = new BroadcastChannel('qso_wish'); + bc.postMessage(this.innerText); + console.log(this.innerText); + }); + $("#menutoggle").on("click", function() { if ($('.navbar').is(":hidden")) { $('.navbar').show(); diff --git a/assets/js/sections/qso.js b/assets/js/sections/qso.js index 6351c118..9d2fe535 100644 --- a/assets/js/sections/qso.js +++ b/assets/js/sections/qso.js @@ -1,5 +1,8 @@ $( document ).ready(function() { + var bc = new BroadcastChannel('qso_wish'); + bc.onmessage = function (ev) { console.log(ev); } /* receive */ + $("#locator") .popover({ placement: 'top', title: 'Gridsquare Formatting', content: "Enter multiple (4-digit) grids separated with commas. For example: IO77,IO78" }) .focus(function () {