added route
This commit is contained in:
parent
7916873589
commit
40aa56f721
1 changed files with 6 additions and 2 deletions
|
@ -46,19 +46,23 @@ require(['jquery', 'socket.io'], function(jq, io) {
|
|||
socket.on('live_request', function(request_data) {
|
||||
console.log("live request");
|
||||
request_time = new Date(request_data["time"] * 1000);
|
||||
addLiveRequest(request_data["hostname"], request_time);
|
||||
addLiveRequest(request_data["hostname"], request_time, request_data["route"]);
|
||||
});
|
||||
});
|
||||
|
||||
function addLiveRequest(request_host, request_time) {
|
||||
function addLiveRequest(request_host, request_time, link_route) {
|
||||
let hostname = request_host;
|
||||
let timesting = request_time.getHours() + ":" + request_time.getMinutes();
|
||||
let route = link_route;
|
||||
|
||||
let html = `
|
||||
<div class="item">
|
||||
<div>
|
||||
${hostname}
|
||||
</div>
|
||||
<div>
|
||||
${route}
|
||||
</div>
|
||||
<div>
|
||||
${timesting}
|
||||
</div>
|
||||
|
|
Loading…
Reference in a new issue