This allows creating UCI entries with a desired name, e.g.
config interface 'guestlan'

Signed-off-by: Rafał Miłecki <zaj...@gmail.com>
---
 luci2/htdocs/luci2/luci2.js | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/luci2/htdocs/luci2/luci2.js b/luci2/htdocs/luci2/luci2.js
index 2a2a359..040f1e5 100644
--- a/luci2/htdocs/luci2/luci2.js
+++ b/luci2/htdocs/luci2/luci2.js
@@ -974,7 +974,7 @@ function LuCI2()
                add: function(conf, type, name)
                {
                        var n = this.state.creates;
-                       var sid = this.createSID(conf);
+                       var sid = name || this.createSID(conf);
 
                        if (!n[conf])
                                n[conf] = { };
-- 
1.8.4.5
_______________________________________________
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel

Reply via email to