Add version information into UI (#35)

This commit adds the tool version into the UI in the top bar.
This commit is contained in:
Lior Noy
2022-10-25 16:08:28 +03:00
committed by GitHub
parent 91df9392c0
commit be6666373b
2 changed files with 13 additions and 0 deletions

View File

@@ -21,6 +21,12 @@ $(function () {
$("#upgradeModal .btn-scan").hide()
}
})
$.get("/status").fail(function (xhr) {
reportError("Failed to get tool version", xhr)
}).done(function (data) {
fillToolVersion(data)
})
})
function initView() {
@@ -195,4 +201,8 @@ function isNewerVersion(oldVer, newVer) {
if (a < b) return false
}
return false
}
function fillToolVersion(data) {
$("#toolVersion").append($('<a>' + data + '</a>'))
}