Add language settings in UI
This commit is contained in:
@ -55,7 +55,7 @@ html, body {
|
||||
.progBar {
|
||||
appearance: none;
|
||||
height: 100%;
|
||||
width: 80%;
|
||||
width: 0%;
|
||||
border-radius: 0px;
|
||||
background-color: darkcyan;
|
||||
}
|
||||
|
@ -50,6 +50,19 @@ $(function () {
|
||||
jsonview.expand(tree2);
|
||||
})
|
||||
|
||||
$("#applyLang").on("click", function (event) {
|
||||
const lang = $("#lang").val()
|
||||
saveOption("/api/ui/v1/lang/set?lang=" + lang, function handleLangSelect(event, xmlHttp) {
|
||||
const temp = JSON.parse(xmlHttp.responseText)
|
||||
if(temp.status == "error") {
|
||||
alert("Request failed reason: " + temp.reason)
|
||||
} else {
|
||||
location.reload()
|
||||
}
|
||||
console.log(JSON.parse(xmlHttp.responseText))
|
||||
})
|
||||
})
|
||||
|
||||
$("#addRow").on("click", function (event) {
|
||||
const tableEntryDom = document.getElementById("tableCopySource").cloneNode(true)
|
||||
let temp = tableEntryDom.innerHTML
|
||||
|
Reference in New Issue
Block a user