Fixed: logic reversed

This commit is contained in:
Ray 2019-07-06 22:20:32 +01:00
parent 1ec4ecdec0
commit 906e1a267c

View File

@ -6,7 +6,7 @@ var BSDialog = {
Create: function(id, title, url, is_big, update_body) { Create: function(id, title, url, is_big, update_body) {
var a = this; var a = this;
var isBig = ((typeof(is_big) == "undefined") ? false : (is_big == true) ? true : false); var isBig = ((typeof(is_big) == "undefined") ? false : (is_big == true) ? true : false);
var updateBody = ((typeof(update_body) == "undefined") ? true : (update_body == true) ? true : false); var updateBody = ((typeof(update_body) == "undefined") ? false : (update_body == true) ? true : false);
if (!a.hasDialog(id)) { if (!a.hasDialog(id)) {
var html = a.generateModalHtml(id, title, null, isBig); var html = a.generateModalHtml(id, title, null, isBig);
@ -23,9 +23,9 @@ var BSDialog = {
{ {
if (updateBody) if (updateBody)
{ {
$("#dlg" + id).find(".modal-content").html(result);
} else {
a.updateContentBody(id, result); a.updateContentBody(id, result);
} else {
$("#dlg" + id).find(".modal-content").html(result);
} }
} else { } else {
a.updateContentBody(id, xhr.statusText + " (" + xhr.status + ")"); a.updateContentBody(id, xhr.statusText + " (" + xhr.status + ")");