diff options
author | Jo-Philipp Wich <jow@openwrt.org> | 2014-02-01 18:03:55 +0000 |
---|---|---|
committer | Jo-Philipp Wich <jow@openwrt.org> | 2014-02-01 18:03:55 +0000 |
commit | 1bcb587b9fbd9c513a7f60e6cb6de22eb564e79e (patch) | |
tree | 3da812e43055b4af2f3c2fbb7844dcca2edcfd7a | |
parent | 4bb42cc51fbf15038be9548c002c3a3d6b2a296f (diff) | |
download | luci2-ui-1bcb587b9fbd9c513a7f60e6cb6de22eb564e79e.tar.gz |
luci2: Add missing CSS classes to LuCI2.cbi.ComboBox widget, fix attaching of event handlers
-rw-r--r-- | luci2/htdocs/luci2/luci2.js | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/luci2/htdocs/luci2/luci2.js b/luci2/htdocs/luci2/luci2.js index 45584e7..c6c13a1 100644 --- a/luci2/htdocs/luci2/luci2.js +++ b/luci2/htdocs/luci2/luci2.js @@ -5660,17 +5660,19 @@ function LuCI2() .attr('id', this.id(sid)); var t = $('<input />') + .addClass('form-control') .attr('type', 'text') .hide() .appendTo(d); var s = $('<select />') + .addClass('form-control') .appendTo(d); var evdata = { self: this, - input: this.validator(sid, t), - select: this.validator(sid, s) + input: t, + select: s }; s.change(evdata, this._change); @@ -5680,6 +5682,9 @@ function LuCI2() t.val(this.ucivalue(sid)); t.blur(); + this.validator(sid, t); + this.validator(sid, s); + return d; }, |