Fix change detection for textareas in Config page
This commit is contained in:
parent
ef0c0b1e32
commit
e79e60f0bb
2 changed files with 10 additions and 4 deletions
|
@ -26,7 +26,10 @@ class ConfigStorage extends Class
|
|||
|
||||
deformatValue: (value, type) ->
|
||||
if type == "object" and typeof(value) == "string"
|
||||
return value.split("\n")
|
||||
if not value.length
|
||||
return value = null
|
||||
else
|
||||
return value.split("\n")
|
||||
if type == "boolean" and not value
|
||||
return false
|
||||
else
|
||||
|
|
|
@ -1336,7 +1336,11 @@
|
|||
|
||||
ConfigStorage.prototype.deformatValue = function(value, type) {
|
||||
if (type === "object" && typeof value === "string") {
|
||||
return value.split("\n");
|
||||
if (!value.length) {
|
||||
return value = null;
|
||||
} else {
|
||||
return value.split("\n");
|
||||
}
|
||||
}
|
||||
if (type === "boolean" && !value) {
|
||||
return false;
|
||||
|
@ -1496,7 +1500,6 @@
|
|||
}).call(this);
|
||||
|
||||
|
||||
|
||||
/* ---- plugins/UiConfig/media/js/ConfigView.coffee ---- */
|
||||
|
||||
|
||||
|
@ -1935,4 +1938,4 @@
|
|||
|
||||
window.Page.createProjector();
|
||||
|
||||
}).call(this);
|
||||
}).call(this);
|
||||
|
|
Loading…
Reference in a new issue