From 631ee048e947449b0eaa4ea1152d776f4b0a33d3 Mon Sep 17 00:00:00 2001 From: tr4ck3ur Date: Mon, 23 Mar 2015 20:27:38 +0100 Subject: [PATCH] Fix Staff condition for non logged people --- jm2l/templates/list_tiers.mako | 4 ++-- jm2l/templates/view_tiers.mako | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/jm2l/templates/list_tiers.mako b/jm2l/templates/list_tiers.mako index 4797466..f96de76 100644 --- a/jm2l/templates/list_tiers.mako +++ b/jm2l/templates/list_tiers.mako @@ -39,7 +39,7 @@ ${entity.name} - % if request.user.Staff: + % if request.user and request.user.Staff: edit @@ -54,4 +54,4 @@ - \ No newline at end of file + diff --git a/jm2l/templates/view_tiers.mako b/jm2l/templates/view_tiers.mako index 1b9e584..95a5e23 100644 --- a/jm2l/templates/view_tiers.mako +++ b/jm2l/templates/view_tiers.mako @@ -16,7 +16,7 @@ ${The_entity_type.entity_subtype} %if entity.tiers_id: Link - %endif -% if (request.user.Staff or request.user in entity.members): +% if request.user and (request.user.Staff or request.user in entity.members): Editer % endif
@@ -93,4 +93,4 @@ ${The_entity_type.entity_subtype}
- \ No newline at end of file +