Merge pull request #1801 from dibdot/adblock
[project/luci.git] / modules / luci-mod-admin-full / luasrc / view / admin_uci / changes.htm
1 <%#
2  Copyright 2008 Steven Barth <steven@midlink.org>
3  Copyright 2008-2018 Jo-Philipp Wich <jo@mein.io>
4  Licensed to the public under the Apache License 2.0.
5 -%>
6
7 <%+header%>
8
9 <%-
10         local node, redir_url = luci.dispatcher.lookup(luci.http.formvalue("redir"))
11
12         include("cbi/apply_widget")
13         include("admin_uci/changelog")
14
15         cbi_apply_widget(redir_url or url("admin/uci/changes"))
16 -%>
17
18 <h2 name="content"><%:Configuration%> / <%:Changes%></h2>
19
20 <% if changes then %>
21         <%- uci_changelog(changes) -%>
22 <% else %>
23         <p><strong><%:There are no pending changes!%></strong></p>
24 <% end %>
25
26 <div class="alert-message" id="cbi_apply_status" style="display:none"></div>
27
28 <div class="cbi-page-actions">
29         <% if redir_url then %>
30         <div style="float:left">
31                 <form class="inline" method="get" action="<%=luci.util.pcdata(redir_url)%>">
32                         <input class="cbi-button cbi-button-link" style="float:left; margin:0" type="submit" value="<%:Back%>" />
33                 </form>
34         </div>
35         <% end %>
36
37         <div style="text-align:right">
38                 <input class="cbi-button cbi-button-save" type="button" id="apply_button" value="<%:Save & Apply%>" onclick="uci_apply(true); this.blur()" />
39                 <form class="inline" method="post" action="<%=controller%>/admin/uci/revert">
40                         <input type="hidden" name="token" value="<%=token%>" />
41                         <input type="hidden" name="redir" value="<%=pcdata(luci.http.formvalue("redir"))%>" />
42                         <input class="cbi-button cbi-button-reset" type="submit" value="<%:Revert%>" />
43                 </form>
44         </div>
45 </div>
46
47 <%+footer%>