|
@ -244,6 +244,18 @@ app.get("/test2", cors(corsOptions), (req, res) => { |
|
|
RES.data = await mydb.collection(COLLECTION).find({}).toArray() |
|
|
RES.data = await mydb.collection(COLLECTION).find({}).toArray() |
|
|
var jsonfinal = []; |
|
|
var jsonfinal = []; |
|
|
RES.data.forEach((value) => { |
|
|
RES.data.forEach((value) => { |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (value.tailed_path == selected) { |
|
|
|
|
|
var tmp = { |
|
|
|
|
|
message: value.message, |
|
|
|
|
|
timestamp: value.time, |
|
|
|
|
|
type: "<div class= 'outtype'>" + value._id+ "</div>", |
|
|
|
|
|
process_id: '', |
|
|
|
|
|
app_name: value.tailed_path, |
|
|
|
|
|
}; |
|
|
|
|
|
jsonfinal.push(tmp); |
|
|
|
|
|
} else if (selected == "All") { |
|
|
var tmp = { |
|
|
var tmp = { |
|
|
message: value.message, |
|
|
message: value.message, |
|
|
timestamp: value.time, |
|
|
timestamp: value.time, |
|
@ -252,6 +264,8 @@ app.get("/test2", cors(corsOptions), (req, res) => { |
|
|
app_name: value.tailed_path, |
|
|
app_name: value.tailed_path, |
|
|
}; |
|
|
}; |
|
|
jsonfinal.push(tmp); |
|
|
jsonfinal.push(tmp); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
}); |
|
|
}); |
|
|
|
|
|
|
|
|
//Pagination
|
|
|
//Pagination
|
|
|