summaryrefslogtreecommitdiffhomepage
path: root/libs
diff options
context:
space:
mode:
Diffstat (limited to 'libs')
-rw-r--r--libs/cbi/luasrc/view/cbi/nullsection.htm11
-rw-r--r--libs/cbi/luasrc/view/cbi/simpleform.htm22
-rw-r--r--libs/cbi/luasrc/view/cbi/ucisection.htm2
3 files changed, 29 insertions, 6 deletions
diff --git a/libs/cbi/luasrc/view/cbi/nullsection.htm b/libs/cbi/luasrc/view/cbi/nullsection.htm
index 9520b47cab..f1c715b408 100644
--- a/libs/cbi/luasrc/view/cbi/nullsection.htm
+++ b/libs/cbi/luasrc/view/cbi/nullsection.htm
@@ -20,4 +20,13 @@ $Id$
<% self:render_children(1, scope or {}) %>
</div>
<br />
- </fieldset> \ No newline at end of file
+ </fieldset>
+ <%-
+ if type(self.hidden) == "table" then
+ for k, v in pairs(self.hidden) do
+ -%>
+ <input type="hidden" id="<%=k%>" name="<%=k%>" value="<%=pcdata(v)%>" />
+ <%-
+ end
+ end
+ %>
diff --git a/libs/cbi/luasrc/view/cbi/simpleform.htm b/libs/cbi/luasrc/view/cbi/simpleform.htm
index d927660da4..a0bb0f02b5 100644
--- a/libs/cbi/luasrc/view/cbi/simpleform.htm
+++ b/libs/cbi/luasrc/view/cbi/simpleform.htm
@@ -33,17 +33,31 @@ $Id$
<%- end %>
<% if not self.embedded then %>
<div>
+<%-
+ if type(self.hidden) == "table" then
+ for k, v in pairs(self.hidden) do
+-%>
+ <input type="hidden" id="<%=k%>" name="<%=k%>" value="<%=pcdata(v)%>" />
+<%-
+ end
+ end
+%>
<%- if self.flow and self.flow.skip then %>
<input class="cbi-button cbi-button-skip" type="submit" name="cbi.skip" value="<%:Skip%>" />
<% end %>
<%- if self.submit ~= false then %>
- <input class="cbi-button-save" type="submit" value="
- <%- if not self.submit then -%><%-:submit-%><%-else-%><%=self.submit%><%end-%>
+ <input class="cbi-button-save" type="submit" value="
+ <%- if not self.submit then -%><%-:Submit-%><%-else-%><%=self.submit%><%end-%>
" />
<% end %>
<%- if self.reset ~= false then %>
- <input class="cbi-button-reset" type="reset" value="
- <%- if not self.reset then -%><%-:reset-%><%-else-%><%=self.reset%><%end-%>
+ <input class="cbi-button-reset" type="reset" value="
+ <%- if not self.reset then -%><%-:Reset-%><%-else-%><%=self.reset%><%end-%>
+ " />
+<% end %>
+<%- if self.cancel ~= false and self.on_cancel then %>
+ <input class="cbi-button-reset" type="submit" name="cbi.cancel" value="
+ <%- if not self.cancel then -%><%-:Cancel-%><%-else-%><%=self.cancel%><%end-%>
" />
<% end %>
<script type="text/javascript">cbi_d_update();</script>
diff --git a/libs/cbi/luasrc/view/cbi/ucisection.htm b/libs/cbi/luasrc/view/cbi/ucisection.htm
index fa083c68f4..b184908b0b 100644
--- a/libs/cbi/luasrc/view/cbi/ucisection.htm
+++ b/libs/cbi/luasrc/view/cbi/ucisection.htm
@@ -17,7 +17,7 @@ $Id$
if type(self.hidden) == "table" then
for k, v in pairs(self.hidden) do
-%>
- <input type="hidden" id="cbid.<%=self.config%>.<%=section%>.<%=k%>" name="cbid.<%=self.config%>.<%=section%>.<%=k%>" value="<%=pcdata(v)%>" />
+ <input type="hidden" id="<%=k%>" name="<%=k%>" value="<%=pcdata(v)%>" />
<%-
end
end