Update heartbeat function location and name
This commit is contained in:
@@ -1,3 +0,0 @@
|
||||
function sendNodeHeartbeat(nodeId) {
|
||||
console.log(nodeId);
|
||||
}
|
||||
@@ -80,7 +80,7 @@ function createToast(notificationMessage){
|
||||
$('.toast').toast('show');
|
||||
}
|
||||
|
||||
function checkInByNodeId(nodeId){
|
||||
function sendNodeHeartbeat(nodeId){
|
||||
const Http = new XMLHttpRequest();
|
||||
const url='/nodes/'+nodeId;
|
||||
Http.open("GET", url);
|
||||
|
||||
@@ -7,5 +7,5 @@
|
||||
</div>
|
||||
</div>
|
||||
<%- include('partials/bodyEnd.ejs') %>
|
||||
<script src="/res/js/controller.js"></script>
|
||||
<script src="/res/js/node.js"></script>
|
||||
<%- include('partials/htmlFooter.ejs') %>
|
||||
@@ -30,7 +30,7 @@
|
||||
<!-- Leave Server button -->
|
||||
<a type="button" class="btn btn-danger <% if(!node.online) { %>disabled<% } %>" href="#" onclick="leaveServer()">Leave Server</a>
|
||||
<!-- Checkin with client button -->
|
||||
<a type="button" class="btn btn-secondary" href="#" onclick="checkInByNodeId('<%=node.id%>')">Check-in with Node</a>
|
||||
<a type="button" class="btn btn-secondary" href="#" onclick="sendNodeHeartbeat('<%=node.id%>')">Check-in with Node</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user