mirror of
https://github.com/node-red/node-red.git
synced 2023-10-10 13:36:53 +02:00
Merge pull request #370 from jhr007/patch-2
Add checkbox support so config dialogs can save checkbox values
This commit is contained in:
commit
16048112c6
@ -587,7 +587,12 @@ RED.editor = (function() {
|
||||
configNode = RED.nodes.node(configId);
|
||||
for (d in configTypeDef.defaults) {
|
||||
if (configTypeDef.defaults.hasOwnProperty(d)) {
|
||||
configNode[d] = $("#node-config-input-"+d).val();
|
||||
var input = $("#node-config-input-"+d);
|
||||
if (input.attr('type') === "checkbox") {
|
||||
configNode[d] = input.prop('checked');
|
||||
} else {
|
||||
configNode[d] = input.val();
|
||||
}
|
||||
}
|
||||
}
|
||||
updateConfigNodeSelect(configProperty,configType,configId);
|
||||
|
Loading…
Reference in New Issue
Block a user