Skip to content

Commit

Permalink
ensure dropboax select multiple defaults to off
Browse files Browse the repository at this point in the history
  • Loading branch information
Dave Conway-Jones committed Oct 26, 2020
1 parent 44578af commit 570d15e
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion dist/dashboard.appcache
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
CACHE MANIFEST
# Time: Mon Oct 26 2020 21:17:31 GMT+0000 (Greenwich Mean Time)
# Time: Mon Oct 26 2020 22:02:56 GMT+0000 (Greenwich Mean Time)

CACHE:
i18n.js
Expand Down
3 changes: 3 additions & 0 deletions nodes/ui_dropdown.html
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,9 @@
label: function() { return this.name || (~this.label.indexOf("{{") ? null : this.label) || 'dropdown'; },
labelStyle: function() { return this.name?"node_label_italic":""; },
oneditprepare: function() {
if (this.multiple === undefined) {
$("#node-input-multiple").prop('checked', false);;
}
$("#node-input-size").elementSizer({
width: "#node-input-width",
height: "#node-input-height",
Expand Down
2 changes: 1 addition & 1 deletion nodes/ui_dropdown.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ module.exports = function(RED) {
function DropdownNode(config) {
RED.nodes.createNode(this, config);
this.pt = config.passthru;
this.multiple = config.multiple;
this.multiple = config.multiple || false;
this.state = [" "," "];
var node = this;
node.status({});
Expand Down

0 comments on commit 570d15e

Please sign in to comment.