PostService with job reply
This commit is contained in:
@ -3,8 +3,14 @@
|
||||
var connection = new signalR.HubConnectionBuilder().withUrl("/NotificationHub").build();
|
||||
|
||||
connection.on("NotifyAll", function (data) {
|
||||
var message = `${data.keyPressEvent.dateTime} - [${data.lastScanServiceResultValue}]`;
|
||||
document.getElementById("data").innerText = message;
|
||||
if (data.keyPressEvent && data.lastScanServiceResultValue) {
|
||||
var innerText = `${data.keyPressEvent.dateTime} - [${data.lastScanServiceResultValue}]`;
|
||||
document.getElementById("lastScanServiceResultValue").innerText = innerText;
|
||||
}
|
||||
else if (data.httpContentBody) {
|
||||
var innerText = `${data.httpContentBody}]`; //JSON.parse() // JSON.stringify()
|
||||
document.getElementById("httpContentBody").innerText = innerText;
|
||||
}
|
||||
});
|
||||
|
||||
connection.start().then(function () {
|
||||
|
Reference in New Issue
Block a user