diff options
author | Ted Trask <ttrask01@yahoo.com> | 2014-04-11 02:17:19 +0000 |
---|---|---|
committer | Ted Trask <ttrask01@yahoo.com> | 2014-04-11 02:17:19 +0000 |
commit | 7c43e1e53cb1f9bd0d47be6095ab34d462a27cbb (patch) | |
tree | f0fe3251da379397b24c73d6410ee286d3bf60ef /opennhrp-listinterfaces-html.lsp | |
parent | a3b838873fd04b83285fe3f955d012d5a0da71c5 (diff) | |
download | acf-opennhrp-7c43e1e53cb1f9bd0d47be6095ab34d462a27cbb.tar.bz2 acf-opennhrp-7c43e1e53cb1f9bd0d47be6095ab34d462a27cbb.tar.xz |
Changes to use new htmlviewfunctions functions
Diffstat (limited to 'opennhrp-listinterfaces-html.lsp')
-rw-r--r-- | opennhrp-listinterfaces-html.lsp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/opennhrp-listinterfaces-html.lsp b/opennhrp-listinterfaces-html.lsp index a684c2d..68ad0c6 100644 --- a/opennhrp-listinterfaces-html.lsp +++ b/opennhrp-listinterfaces-html.lsp @@ -23,7 +23,7 @@ html = require("acf.html") <% htmlviewfunctions.displaycommandresults({"editinterface"}, session) %> -<h1><%= html.html_escape(view.label) %></h1> +<% local header_level = htmlviewfunctions.displaysectionstart(view, page_info) %> <table id="list" class="tablesorter"><thead> <tr> <th>Action</th> @@ -32,10 +32,13 @@ html = require("acf.html") <th>Comment</th> </tr> </thead><tbody> +<% local interface = cfe({ type="hidden", value="" }) %> +<% local redir = cfe({ type="hidden", value=page_info.orig_action }) %> <% for i,intf in ipairs(view.value) do %> <tr> <td> - <% io.write(html.link{value = "editinterface?interface="..intf.interface.."&redir="..page_info.orig_action, label="Edit " }) %> + <% interface.value = intf.interface %> + <% htmlviewfunctions.displayitem(cfe({type="link", value={interface=interface, redir=redir}, label="", option="Edit", action="editinterface"}), page_info, -1) %> </td> <td><%= html.html_escape(intf.interface) %></td> <td><%= html.html_escape(intf.type) %></td> @@ -43,3 +46,4 @@ html = require("acf.html") </tr> <% end %> </tbody></table> +<% htmlviewfunctions.displaysectionend(header_level) %> |