change url path in ajax : suseendhiran

This commit is contained in:
suseendhiran17 2022-09-21 15:27:43 +05:30
parent 843bac3d66
commit cb3164a13d

View File

@ -483,7 +483,7 @@
Last updated <%=date %>
</div>
</div>
<div class = "header1">
<div id="statusHeader" class = "header1">
<% if ( down == 0) { %>
<h1><i class="dot" aria-hidden = "true" style="font-size:26px;color:lightgreen"></i> <strong> All systems
<span class="uk-text-primary">operational</span></strong></h1>
@ -590,7 +590,7 @@
var api = $(evt.target).parent().parent("tr").find("td:nth-child(1)").text();
$.ajax({
type: "post",
url: "/api_monitor/api/SingleApiStatus",
url: "/api/SingleApiStatus",
data: {api : api},
success: function(response) {
if (response.success == true)
@ -601,11 +601,14 @@
if (response.Status == "Up")
{
var success = '<i class="dot" style="font-size:14px;color: #3bd671 !important;height:15px;width:15px;"></i> <b>'+response.Status+'</b>'
var status = '<h1><i class="dot" aria-hidden = "true" style="font-size:26px;color:lightgreen"></i> <strong> All systems <span class="uk-text-primary">operational</span></strong></h1>'
}
else
{
var success = '<i class="dot1" style="font-size:14px;color: red;height:15px;width:15px;"></i> <b1>'+response.Status+'</b1>'
var status = '<h1><i class="dot1" aria-hidden = "true" style="font-size:26px;color:red"></i> <strong> Some systems are <span class="uk-text-primary1">down</span></strong></h1>'
}
$('#statusHeader').html(status);
$(evt.target).parent().parent("tr").find("td:nth-child(2)").html(response.StatusCode);
$(evt.target).parent().parent("tr").find("td:nth-child(3)").html(success);
}