diff options
Diffstat (limited to 'modules/luci-base/htdocs/luci-static/resources')
-rw-r--r-- | modules/luci-base/htdocs/luci-static/resources/ui.js | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/modules/luci-base/htdocs/luci-static/resources/ui.js b/modules/luci-base/htdocs/luci-static/resources/ui.js index 08196117b..08edaa147 100644 --- a/modules/luci-base/htdocs/luci-static/resources/ui.js +++ b/modules/luci-base/htdocs/luci-static/resources/ui.js @@ -1555,6 +1555,16 @@ var UIDynamicList = UIElement.extend({ for (var i = 0; i < values.length; i++) this.addItem(this.node, values[i], this.choices ? this.choices[values[i]] : null); + }, + + addChoices: function(values, labels) { + var dl = this.node.lastElementChild.firstElementChild; + L.dom.callClassMethod(dl, 'addChoices', values, labels); + }, + + clearChoices: function() { + var dl = this.node.lastElementChild.firstElementChild; + L.dom.callClassMethod(dl, 'clearChoices'); } }); |