diff --git a/views/index.jade b/views/index.jade index 806bc8b..0b53687 100644 --- a/views/index.jade +++ b/views/index.jade @@ -68,16 +68,15 @@ block content socket.on('gotstream', function(data) { console.log("gotstream " + data.id); - $("div#stream-" + data.id + " h3").text(data.title); - $("div#stream-" + data.id + " td.location").text(data.location); - $("div#stream-" + data.id + " td.latitude").text(data.lat); - $("div#stream-" + data.id + " td.longitude").text(data.lon); - var now = new Date(); - $("div#stream-" + data.id + " td.update").text(now); + $("#stream-" + data.id + " h3").text(data.title); + $("#stream-" + data.id + " td.location").text(data.location); + $("#stream-" + data.id + " td.latitude").text(data.lat); + $("#stream-" + data.id + " td.longitude").text(data.lon); + $("#stream-" + data.id + " td.update").text(new Date().toLocaleString()); if (data.id != 43573) { - loadMap($('div#map-' + data.id)[0], data.lat, data.lon); + loadMap($('#map-' + data.id)[0], data.lat, data.lon); } else { - loadMap($('div#map-' + data.id)[0], 34.737596,135.341564); + loadMap($('#map-' + data.id)[0], 34.737596, 135.341564); } }); @@ -87,6 +86,7 @@ block content console.log('searching for "#feed-' + data.feed + '"') var row = $('#stream-' + data.stream + '-feed-' + data.feed).html(); if (row === undefined) { + $("#stream-" + data.stream + " td.update").text(new Date().toLocaleString()); var tmp = '