Refactor of History module #184

Merged
bema merged 25 commits from widlam/refactor/issue#162 into master 2023-05-19 13:10:48 +02:00
Showing only changes of commit c9ff56431b - Show all commits

View File

@@ -121,6 +121,7 @@ async function formatXML(xml) {
function showRequestBody(element){ function showRequestBody(element){
requestBody = ""; requestBody = "";
document.getElementById('code-highlight-content').innerText = "Loading...";
var historyRequestBody = historyJson[element.id].requestBody; var historyRequestBody = historyJson[element.id].requestBody;
switch(historyJson[element.id].headers["content-type"]){ switch(historyJson[element.id].headers["content-type"]){
case "application/json":{ case "application/json":{
@@ -132,7 +133,6 @@ function showRequestBody(element){
break; break;
} }
case "application/xml":{ case "application/xml":{
document.getElementById('code-highlight-content').innerText = "";
formatXML(historyRequestBody).then(function(result) { formatXML(historyRequestBody).then(function(result) {
if (result.status == "OK") { if (result.status == "OK") {
document.getElementById('code-highlight-content').innerText = result.result; document.getElementById('code-highlight-content').innerText = result.result;