$Id$
-%>
+
<%+header%>
-<h1><%:config%></h1>
-<p><%:uci_applied%>:</p>
-<code><%=(changes or "-")%>
-
-<%
-local fp = reload()
-local line = fp:read()
-while line do
- write(line.."\n")
- line = fp:read()
-end
-fp:close()
-%></code>
-<%+footer%>
\ No newline at end of file
+
+<h2><a id="content" name="content"><%:Configuration / Apply%></a></h2>
+
+<% if changes then %>
+ <%+cbi/apply_xhr%>
+ <%+admin_uci/changelog%>
+
+ <%- cbi_apply_xhr('uci-apply', configs) -%>
+
+ <p><strong><%:The following changes have been comitted%>:</strong></p>
+ <%- uci_changelog(changes) -%>
+<% else %>
+ <p><strong><%:There are no pending changes to apply!%></strong></p>
+<% end %>
+
+<%+footer%>