summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTed Trask <ttrask01@yahoo.com>2009-12-17 10:22:04 +0000
committerTed Trask <ttrask01@yahoo.com>2009-12-17 10:22:04 +0000
commit6d49c95dc3cc375cf1f7ea0e2d4350ef68f81268 (patch)
treec677ab4a87e0f386e4c2252bb3714875c9af988d
parentb8eaeac09c286888671770e4b5a325ef7cfa79fe (diff)
downloadacf-did-6d49c95dc3cc375cf1f7ea0e2d4350ef68f81268.tar.bz2
acf-did-6d49c95dc3cc375cf1f7ea0e2d4350ef68f81268.tar.xz
Use viewlibrary.check_permission from acf-core-0.9.0
-rw-r--r--did-html.lsp6
-rw-r--r--did-status-html.lsp2
2 files changed, 4 insertions, 4 deletions
diff --git a/did-html.lsp b/did-html.lsp
index 1ed5ecd..8b645ad 100644
--- a/did-html.lsp
+++ b/did-html.lsp
@@ -42,10 +42,10 @@ function newPopup(url) {
<TR>
<TD>
<%= html.link{value = "JavaScript:newPopup('editdefinition?did=" .. def.did.."');", label="Edit "} %>
- <% if session.permissions[page_info.controller].publish then %>
+ <% if viewlibrary.check_permission("publish") then %>
<%= html.link{value = "publish?did=" .. def.did, label="Publish "} %>
<% end %>
- <% if session.permissions[page_info.controller].deletedefinition then %>
+ <% if viewlibrary.check_permission("deletedefinition") then %>
<%= html.link{value = "deletedefinition?did=" .. def.did, label="Delete "} %>
<% end %>
</TD>
@@ -67,7 +67,7 @@ function newPopup(url) {
<p>No definitions found</p>
<% end %>
-<% if session.permissions[page_info.controller].publishall then %>
+<% if viewlibrary.check_permission("publishall") then %>
<form action="<%= html.html_escape(page_info.script .. page_info.prefix .. page_info.controller .. "/publishall") %>">
<DT>Publish All DIDs</DT>
<DD><input class="submit" type="submit" value="Publish"></DD>
diff --git a/did-status-html.lsp b/did-status-html.lsp
index 5ded042..470b26b 100644
--- a/did-status-html.lsp
+++ b/did-status-html.lsp
@@ -8,7 +8,7 @@ require("viewfunctions")
<DL>
<% local status
if viewlibrary and viewlibrary.dispatch_component then
- if session.permissions.postgresql and session.permissions.postgresql.status then
+ if viewlibrary.check_permission("postgresql/postgresql/status") then
status = viewlibrary.dispatch_component("postgresql/postgresql/status", nil, true)
end
end %>