From e4b39f4255aff6f974eb1a1e4e78fe01587814aa Mon Sep 17 00:00:00 2001 From: Natanael Copa Date: Mon, 28 Jul 2008 06:48:16 +0000 Subject: use <% %> instead of git-svn-id: svn://svn.alpinelinux.org/acf/core/trunk@1323 ab2d0c66-481e-0410-8bed-d214d4d58bed --- app/acf-util/logon-html.lsp | 14 ++++----- app/acf-util/logon-logout-html.lsp | 6 ++-- app/acf-util/logon-status-html.lsp | 10 +++---- app/acf-util/password-html.lsp | 14 ++++----- app/acf-util/password-status-html.lsp | 34 +++++++++++----------- app/acf-util/roles-editrole-html.lsp | 14 ++++----- app/acf-util/roles-html.lsp | 54 +++++++++++++++++------------------ app/acf-util/roles-viewroles-html.lsp | 42 +++++++++++++-------------- app/debug-html.lsp | 8 +++--- app/dispatcherror-html.lsp | 8 +++--- app/exception-html.lsp | 8 +++--- app/expert-html.lsp | 16 +++++------ app/filedetails-html.lsp | 32 ++++++++++----------- app/form-html.lsp | 10 +++---- app/startstop-html.lsp | 22 +++++++------- app/status-html.lsp | 8 +++--- app/template-html.lsp | 44 ++++++++++++++-------------- app/template-stream.lsp | 14 ++++----- app/welcome-html.lsp | 6 ++-- www/cgi-bin/acf | 4 +-- 20 files changed, 184 insertions(+), 184 deletions(-) diff --git a/app/acf-util/logon-html.lsp b/app/acf-util/logon-html.lsp index 22deb4d..3d131bc 100644 --- a/app/acf-util/logon-html.lsp +++ b/app/acf-util/logon-html.lsp @@ -1,12 +1,12 @@ - - - +<% require("viewfunctions") %> +<% --[[ io.write(html.cfe_unpack(form)) - --]] ?> + --]] %> -

-<%= form.label %> +<% form.value.password.type = "password" local order = { "userid", "password" } displayform(form, order) -?> +%> diff --git a/app/acf-util/logon-logout-html.lsp b/app/acf-util/logon-logout-html.lsp index b3e2f08..a658ea9 100644 --- a/app/acf-util/logon-logout-html.lsp +++ b/app/acf-util/logon-logout-html.lsp @@ -1,6 +1,6 @@ - +<% local view= ... %>

Log Out

- +<%= html.cfe_unpack(view) %> - +<%= view.logout.value %> diff --git a/app/acf-util/logon-status-html.lsp b/app/acf-util/logon-status-html.lsp index 661b588..5fb70c9 100644 --- a/app/acf-util/logon-status-html.lsp +++ b/app/acf-util/logon-status-html.lsp @@ -1,8 +1,8 @@ - - +<% --[[ io.write(html.cfe_unpack(view)) ---]] ?> +--]] %>

User Status

Below is your current Session id

- -

You are currently known to the system as .

+<%= view.value.sessionid.value %> +

You are currently known to the system as <%= view.value.username.value %>.

diff --git a/app/acf-util/password-html.lsp b/app/acf-util/password-html.lsp index d845316..dca559d 100755 --- a/app/acf-util/password-html.lsp +++ b/app/acf-util/password-html.lsp @@ -1,16 +1,16 @@ - - - +<% require("viewfunctions") %> +<% --[[ DEBUG INFORMATION io.write("

DEBUGGING

DEBUG INFO: CFE

") io.write(html.cfe_unpack(form)) io.write(html.cfe_unpack(FORM)) io.write("
") --]] -?> +%> -

-<%= form.label %> +<% if form.value.password and form.value.password_confirm then form.value.password.type = "password" form.value.password_confirm.type = "password" @@ -21,4 +21,4 @@ io.write("") end local order = { "userid", "username", "roles", "password", "password_confirm" } displayform(form, order) -?> +%> diff --git a/app/acf-util/password-status-html.lsp b/app/acf-util/password-status-html.lsp index c16e0d6..26416ce 100755 --- a/app/acf-util/password-status-html.lsp +++ b/app/acf-util/password-status-html.lsp @@ -1,14 +1,14 @@ - - - +<% require("viewfunctions") %> +<% --[[ DEBUG INFORMATION io.write("

DEBUGGING

DEBUG INFO: CFE

") io.write(html.cfe_unpack(form)) io.write("
") --]] -?> +%> - +<% displaycommandresults({"deleteuser"}, session) %>

User Accounts

Create new account

@@ -17,26 +17,26 @@ io.write("")

Existing account

- -
+<% for name,user in pairs(form.value) do %> +
<%= name %>
- - + + - - + + - - + +
<%= user.value.userid.label %><%= user.value.userid.value %>
<%= user.value.username.label %><%= user.value.username.value %>
<%= user.value.roles.label %><%= table.concat(user.value.roles.value, " / ") %>
Option - [Edit this account] - [Delete this account] - [View roles for this account] + [Edit this account] + [Delete this account] + [View roles for this account]
- +<% end %>
diff --git a/app/acf-util/roles-editrole-html.lsp b/app/acf-util/roles-editrole-html.lsp index d0e1e3f..5f106fc 100644 --- a/app/acf-util/roles-editrole-html.lsp +++ b/app/acf-util/roles-editrole-html.lsp @@ -1,12 +1,12 @@ - - +<% local form, viewtable, page_info = ... %> +<% require("viewfunctions") %> - +--]] %> -

-<%= form.label %> +<% form.action = page_info.script .. page_info.prefix .. page_info.controller .. "/" .. page_info.action -- If editing existing role, disable role if page_info.action ~= "newrole" then @@ -14,4 +14,4 @@ end local order = { "role", "permissions" } displayform(form, order) -?> +%> diff --git a/app/acf-util/roles-html.lsp b/app/acf-util/roles-html.lsp index a5c89dc..16e4747 100644 --- a/app/acf-util/roles-html.lsp +++ b/app/acf-util/roles-html.lsp @@ -1,33 +1,33 @@ - - +<% --[[ io.write(html.cfe_unpack(view)) ---]] ?> +--]] %> - - -

Roles/Permission list for :

- -

Permission list for :

- +<% ---[[ %> +<% if view.value.userid then %> +

Roles/Permission list for <%= view.value.userid.value %>:

+<% elseif view.value.role then %> +

Permission list for <%= view.value.role.value %>:

+<% else %>

Complete permission list:

- +<% end %> - -

is valid in these roles

- +

<%= view.value.userid.value %> is valid in these roles

+ <% for a,b in pairs(view.value.roles.value) do print("
  • ",b,"
  • ") - end ?> - - + end %> +<% end %> +<% --]] %> - - - -

    's full permissions are

    - -

    's full permissions are

    - - +<% if view.value.permissions then %> + <% if view.value.userid then %> +

    <%= view.value.userid.value %>'s full permissions are

    + <% elseif view.value.role then %> +

    <%= view.value.role.value %>'s full permissions are

    + <% end %> + <% local controllers = {} -- It's nice to have it in alphabetical order for cont in pairs(view.value.permissions.value) do controllers[#controllers + 1] = cont @@ -49,6 +49,6 @@ io.write("") end io.write("") - ?> - - + %> +<% end %> +<% --]] %> diff --git a/app/acf-util/roles-viewroles-html.lsp b/app/acf-util/roles-viewroles-html.lsp index 23e7195..f5ca4d5 100644 --- a/app/acf-util/roles-viewroles-html.lsp +++ b/app/acf-util/roles-viewroles-html.lsp @@ -1,39 +1,39 @@ - - +<% local view, viewlibrary, page_info, session= ... %> +<% require("viewfunctions") %> - +--]] %> - +<% displaycommandresults({"deleterole"}, session) %>

    Roles

    Create new role

    -
    +

    Existing roles

    - +<% if view.value.default_roles then %>
    - -
    + <% for x,role in pairs(view.value.default_roles.value) do %> +
    <%= role %>
    - [View this role] + [View this role]
    - + <% end %>
    - - +<% end %> +<% if view.value.defined_roles then %>
    - - -
    + <% table.sort(view.value.defined_roles.value) %> + <% for x,role in pairs(view.value.defined_roles.value) do %> +
    <%= role %>
    - [View this role] - [Edit this role] - [Delete this role] + [View this role] + [Edit this role] + [Delete this role]
    - + <% end %>
    - +<% end %> diff --git a/app/debug-html.lsp b/app/debug-html.lsp index 775b102..d3db3b4 100644 --- a/app/debug-html.lsp +++ b/app/debug-html.lsp @@ -1,8 +1,8 @@ - +<% local data, viewlibrary, page_info, session = ... %>

    Debugging

    View Data:

    - +<%= html.cfe_unpack(data) %>

    Session:

    - +<%= html.cfe_unpack(session) %>

    Page Info:

    - +<%= html.cfe_unpack(page_info) %> diff --git a/app/dispatcherror-html.lsp b/app/dispatcherror-html.lsp index 66cfd5d..ce6b5c8 100644 --- a/app/dispatcherror-html.lsp +++ b/app/dispatcherror-html.lsp @@ -1,7 +1,7 @@ - - +<% --[[ io.write(html.cfe_unpack(view)) ---]] ?> +--]] %>