status.ejs ajax : suseendhiran
This commit is contained in:
parent
7573347b6c
commit
b4b6c8b5c3
@ -107,7 +107,17 @@ exports.SingleApiStatus = async (req, res) =>
|
|||||||
URL = object.url;
|
URL = object.url;
|
||||||
request_object = object.requestObject;
|
request_object = object.requestObject;
|
||||||
if (object.header == 1 && token_data.status == 200) { request_header = "Bearer"+" "+token_data.data.token; reqObj = {url: URL, method: object.method,json: true,body: request_object,headers : { 'Content-Type' : 'application/json' , 'Authorization' : request_header }} }
|
if (object.header == 1 && token_data.status == 200) { request_header = "Bearer"+" "+token_data.data.token; reqObj = {url: URL, method: object.method,json: true,body: request_object,headers : { 'Content-Type' : 'application/json' , 'Authorization' : request_header }} }
|
||||||
else { reqObj = {url: URL,method: object.method,body: request_object} }
|
else
|
||||||
|
{
|
||||||
|
if (object.name == "SMC Front End")
|
||||||
|
{
|
||||||
|
reqObj = {url: URL,method: object.method}
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
reqObj = {url: URL,method: object.method,body: request_object,json: true}
|
||||||
|
}
|
||||||
|
}
|
||||||
request(reqObj, function (error, response, body) {
|
request(reqObj, function (error, response, body) {
|
||||||
if (response == undefined)
|
if (response == undefined)
|
||||||
{
|
{
|
||||||
@ -133,23 +143,3 @@ exports.SingleApiStatus = async (req, res) =>
|
|||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
exports.test = async (req, res) =>
|
|
||||||
{
|
|
||||||
try
|
|
||||||
{
|
|
||||||
|
|
||||||
reqObj = {url: "https://demo.devopsmcfinance.com/mw/cet/main" ,method: "GET",json: true,body: "request_object"}
|
|
||||||
request(reqObj, function (error, response, body) {
|
|
||||||
console.log(response.statusCode);
|
|
||||||
})
|
|
||||||
}
|
|
||||||
catch(err)
|
|
||||||
{
|
|
||||||
res.send({'status':404,
|
|
||||||
message: err.message || "Some error occurred while inserting statements." ,'data': "No data"
|
|
||||||
});
|
|
||||||
} //end of try catch
|
|
||||||
|
|
||||||
};
|
|
||||||
@ -13,7 +13,6 @@ module.exports = app => {
|
|||||||
// Single Api status check Api
|
// Single Api status check Api
|
||||||
router.post("/SingleApiStatus", Mycontroller.SingleApiStatus);
|
router.post("/SingleApiStatus", Mycontroller.SingleApiStatus);
|
||||||
|
|
||||||
router.get("/test", Mycontroller.test);
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -1,5 +1,7 @@
|
|||||||
<html>
|
<html>
|
||||||
<head>
|
<head>
|
||||||
|
<script src="https://ajax.aspnetcdn.com/ajax/jQuery/jquery-3.4.1.min.js"></script>
|
||||||
|
<!-- <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.js"></script> -->
|
||||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
|
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
|
||||||
<link href="//maxcdn.bootstrapcdn.com/bootstrap/4.1.1/css/bootstrap.min.css" rel="stylesheet" id="bootstrap-css">
|
<link href="//maxcdn.bootstrapcdn.com/bootstrap/4.1.1/css/bootstrap.min.css" rel="stylesheet" id="bootstrap-css">
|
||||||
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
|
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
|
||||||
@ -15,9 +17,7 @@
|
|||||||
}, 300000);
|
}, 300000);
|
||||||
</script>
|
</script>
|
||||||
<style>
|
<style>
|
||||||
|
/* Desktops and laptops ----------- */
|
||||||
|
|
||||||
/* Desktops and laptops ----------- */
|
|
||||||
@media only screen and (min-width : 1224px) {
|
@media only screen and (min-width : 1224px) {
|
||||||
b {
|
b {
|
||||||
font-family: Arial, Helvetica, sans-serif;
|
font-family: Arial, Helvetica, sans-serif;
|
||||||
@ -243,7 +243,7 @@
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
/* Smartphones (portrait and landscape) ----------- */
|
/* Smartphones (portrait and landscape) ----------- */
|
||||||
@media only screen and (min-device-width : 320px) and (max-device-width : 480px) {
|
@media only screen and (min-device-width : 320px) and (max-device-width : 480px) {
|
||||||
b {
|
b {
|
||||||
font-family: Arial, Helvetica, sans-serif;
|
font-family: Arial, Helvetica, sans-serif;
|
||||||
@ -412,7 +412,7 @@
|
|||||||
width: 0em;
|
width: 0em;
|
||||||
padding: 8px;
|
padding: 8px;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
|
font-size: larger;
|
||||||
}
|
}
|
||||||
|
|
||||||
#tab-des tr:nth-child(even){background-color: #f2f2f2;}
|
#tab-des tr:nth-child(even){background-color: #f2f2f2;}
|
||||||
@ -429,7 +429,7 @@
|
|||||||
color: white;
|
color: white;
|
||||||
}
|
}
|
||||||
|
|
||||||
#tab-des-2 {
|
/* #tab-des-2 {
|
||||||
font-family: Arial, Helvetica, sans-serif;
|
font-family: Arial, Helvetica, sans-serif;
|
||||||
border-collapse: collapse;
|
border-collapse: collapse;
|
||||||
width: 87%;
|
width: 87%;
|
||||||
@ -453,7 +453,7 @@
|
|||||||
text-align: center;
|
text-align: center;
|
||||||
background-color: #04AA6D;
|
background-color: #04AA6D;
|
||||||
color: white;
|
color: white;
|
||||||
}
|
} */
|
||||||
|
|
||||||
.xd-content .xd-body .xd-body-inner {
|
.xd-content .xd-body .xd-body-inner {
|
||||||
max-height: unset;
|
max-height: unset;
|
||||||
@ -526,7 +526,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class = "header4"><h1><i style="font-size:18px;color:black"></i> <strong>Server Services</strong></h1></div>
|
<div class = "header4"><h1><i style="font-size:18px;color:black"></i> <strong>Server Services</strong></h1></div>
|
||||||
<div class = "header5">
|
<div class = "header5">
|
||||||
<table id="tab-des-2">
|
<table id="tab-des">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Server</th>
|
<th>Server</th>
|
||||||
@ -556,7 +556,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class = "header6"><h1><i style="font-size:18px;color:black"></i> <strong>Database Services</strong></h1></div>
|
<div class = "header6"><h1><i style="font-size:18px;color:black"></i> <strong>Database Services</strong></h1></div>
|
||||||
<div class = "header7">
|
<div class = "header7">
|
||||||
<table id="tab-des-2">
|
<table id="tab-des">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Database</th>
|
<th>Database</th>
|
||||||
@ -585,8 +585,6 @@
|
|||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
</body>
|
</body>
|
||||||
<script src="https://ajax.aspnetcdn.com/ajax/jQuery/jquery-3.4.1.min.js"></script>
|
|
||||||
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.js"></script>
|
|
||||||
<script>
|
<script>
|
||||||
$(".index").click(function (evt) {
|
$(".index").click(function (evt) {
|
||||||
var api = $(evt.target).parent().parent("tr").find("td:nth-child(1)").text();
|
var api = $(evt.target).parent().parent("tr").find("td:nth-child(1)").text();
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user