X-Git-Url: https://git.archive.openwrt.org/?p=project%2Fluci.git;a=blobdiff_plain;f=libs%2Fcbi%2Fluasrc%2Fview%2Fcbi%2Ftblsection.htm;h=be7e723f7a5b41c99fc76378f32bb946120e8812;hp=7bb31caa1debdea2a5c3d62c24fb09116b694883;hb=d8282d382bc675eb1c930eed0fe65c41050400b8;hpb=8591d4e3963900082bc6468fe37eb08ce930faec diff --git a/libs/cbi/luasrc/view/cbi/tblsection.htm b/libs/cbi/luasrc/view/cbi/tblsection.htm index 7bb31caa1..be7e723f7 100644 --- a/libs/cbi/luasrc/view/cbi/tblsection.htm +++ b/libs/cbi/luasrc/view/cbi/tblsection.htm @@ -22,19 +22,25 @@ end
- <%=self.title%> + <% if self.title and #self.title > 0 then -%> + <%=self.title%> + <%- end %>
<%=self.description%>
<%- local count = 0 -%> <%- if not self.anonymous then -%> - + <%- end -%> <%- for i, k in pairs(self.children) do if not k.optional then -%> - + <%- count = count + 1; end; end; if self.extedit or self.addremove then -%> - + <%- count = count + 1; end -%> @@ -53,7 +59,7 @@ end isempty = false scope = { valueheader = "cbi/cell_valueheader", valuefooter = "cbi/cell_valuefooter" } -%> - + <% if not self.anonymous then -%> <%- end %> @@ -70,7 +76,13 @@ end <%- if self.extedit or self.addremove then -%> <%- end -%>
  <%=k.title%> + <%- if k.titleref then -%><%- end -%> + <%-=k.title-%> + <%- if k.titleref then -%><%- end -%> +   

<%=k%>

<%- if self.extedit then -%> - <%:edit%> + + <%=self.extedit:format(section)%> + <%- elseif type(self.extedit) == "function" then -%> + <%=self:extedit(section)%> + <%- end -%> + " title="<%:edit%>"><%:edit%> <%- end; if self.addremove then %> <%- end -%> @@ -85,6 +97,15 @@ end
+ + <% if self.error then %> +
+
    <% for _, c in pairs(self.error) do for _, e in ipairs(c) do -%> +
  • <%=luci.util.pcdata(e):gsub("\n","
    ")%>
  • + <%- end end %>
+
+ <% end %> + <%- if self.addremove then -%>
@@ -92,12 +113,12 @@ end <% if self.anonymous then %> <% else %> + <% if self.invalid_cts then -%>
<% end %> - <% end %> - - <% if self.err_invalid then %> -
<%:cbi_invalid%>
+ <% if self.invalid_cts then -%> +
<%:cbi_invalid%>
+ <%- end %> <% end %>