From 3c794e7c2d75bc5995869f88def4a240b24d6dfc Mon Sep 17 00:00:00 2001 From: Andrew McMillan Date: Sat, 3 Oct 2009 22:57:44 +1300 Subject: [PATCH] Hopefully final fix to get_permissions during the lifetime of this modeHopefully final fix to get_permissions during the lifetime of this model --- dba/caldav_functions.sql | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/dba/caldav_functions.sql b/dba/caldav_functions.sql index b84752d8..6a8b1656 100644 --- a/dba/caldav_functions.sql +++ b/dba/caldav_functions.sql @@ -320,7 +320,8 @@ BEGIN SELECT rt1.confers INTO out_confers, tmp_confers1 FROM relationship r1 JOIN relationship_type rt1 ON ( r1.rt_id = rt1.rt_id ) LEFT OUTER JOIN relationship r2 ON ( rt1.rt_id = r2.rt_id ) WHERE r1.from_user = in_from AND r2.from_user = in_to AND r1.from_user != r2.from_user AND r1.to_user = r2.to_user - AND NOT EXISTS( SELECT 1 FROM relationship r3 WHERE r3.from_user = r1.to_user ) ; + AND NOT EXISTS( SELECT 1 FROM relationship r3 WHERE r3.from_user = r1.to_user ) + AND usr_is_role(r1.to_user,'Group'); IF FOUND THEN -- dbg := 'H-';