On Mon, Apr 27, 2009 at 5:15 AM, Gustavo Narea <m...@gustavonarea.net> wrote: > Hola, Jorge. > > > You have two options to do that, which are also simpler (from my point of > view): > http://code.gustavonarea.net/repoze.what-pylons/Manual/Misc.html#predicate-evaluators > http://code.gustavonarea.net/repoze.what-pylons/Manual/Misc.html#boolean-predicates > > let me expand my request a little it seems to me there is no simple way of querying the system to see who you are and what you can do. Consider the following case.
#controller def index(self): if in_group('guests').is_met(request.environ): return dict(...) if in_group('clients').is_met(request.environ): return dict(...) #template <div py:choose=""> <span py:when=""tg.predicates.is_user('guests').is_met(request.environ)"">0</span> <span py:when=""tg.predicates.is_user('clients').is_met(request.environ)"">1</span> </div> _______________________________________________ Repoze-dev mailing list Repoze-dev@lists.repoze.org http://lists.repoze.org/listinfo/repoze-dev