<% local view, viewlibrary, page_info, session = ... htmlviewfunctions = require("htmlviewfunctions") html = require("acf.html") %> <% htmlviewfunctions.displaycommandresults({"deleteparam", "editparam"}, session) %> <% htmlviewfunctions.displaycommandresults({"createparam"}, session, true) %> <% local header_level = htmlviewfunctions.displaysectionstart(view, page_info) %> <% local param_id = cfe({ type="hidden", value="" }) %> <% local redir = cfe({ type="hidden", value=page_info.orig_action }) %> <% for k,v in ipairs( view.value ) do %> <% end %>
Action Name Label Default Sequence
<% param_id.value = v.param_id %> <% if viewlibrary.check_permission("editparam") then %> <% htmlviewfunctions.displayitem(cfe({type="link", value={param_id=param_id, redir=redir}, label="", option="Edit", action="editparam"}), page_info, -1) %> <% end %> <% if viewlibrary.check_permission("deleteparam") then %> <% htmlviewfunctions.displayitem(cfe({type="form", value={param_id=param_id}, label="", option="Delete", action="deleteparam", class="deleteparam"}), page_info, -1) %> <% end %> <%= html.html_escape(v.name) %> <%= html.html_escape(v.label) %> <%= html.html_escape(v.value) %> <%= html.html_escape(v.seq) %>
<% if view.errtxt then %>

<%= html.html_escape(view.errtxt) %>

<% end %> <% if #view.value == 0 then %>

No parameters found

<% end %> <% htmlviewfunctions.displaysectionend(header_level) %> <% if viewlibrary and viewlibrary.dispatch_component and viewlibrary.check_permission("createparam") then viewlibrary.dispatch_component("createparam") end %>