mirror of
https://github.com/node-red/node-red.git
synced 2023-10-10 13:36:53 +02:00
parent
0253dc9623
commit
4a4e7fc7cb
@ -1004,16 +1004,17 @@
|
|||||||
this.uiSelect.hide();
|
this.uiSelect.hide();
|
||||||
},
|
},
|
||||||
disable: function(val) {
|
disable: function(val) {
|
||||||
if(val === true) {
|
if(val === undefined || !!val === true) {
|
||||||
this.uiSelect.attr("disabled", "disabled");
|
this.uiSelect.attr("disabled", "disabled");
|
||||||
} else if (val === false) {
|
|
||||||
this.uiSelect.attr("disabled", null); //remove attr
|
|
||||||
} else {
|
} else {
|
||||||
this.uiSelect.attr("disabled", val); //user value
|
this.uiSelect.attr("disabled", null); //remove attr
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
enable: function() {
|
||||||
|
this.uiSelect.attr("disabled", null); //remove attr
|
||||||
|
},
|
||||||
disabled: function() {
|
disabled: function() {
|
||||||
return this.uiSelect.attr("disabled");
|
return this.uiSelect.attr("disabled") === "disabled";
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
})(jQuery);
|
})(jQuery);
|
||||||
|
Loading…
Reference in New Issue
Block a user