luci-base: allow optional default value for file browser

With this change we could set optional value for the file browser.

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
This commit is contained in:
Florian Eckert 2018-11-14 10:05:02 +01:00
parent e535ef5828
commit 1a52df6bdb

View file

@ -1,4 +1,4 @@
<% local v = self:cfgvalue(section) -%>
<% local v = self:cfgvalue(section) or self.default -%>
<%+cbi/valueheader%>
<input class="cbi-input-text" type="text"<%= attr("value", v) .. attr("name", cbid) .. attr("id", cbid) %> />
<script type="text/javascript">