On Tuesday 30 June 2009 02:44:30 pm cd34 wrote:
> The subject of the post versus the question posed within appear to be
> different. If you are truly talking about protecting a controller or
> action, then, you would need to look at root.py on a quickstarted
> project which shows you how a manager or editor can be handed limited
> access to an action within a controller:
I have authentication up and running. What I need is a way to tell whether a
user would have access to a given controller or action without them actively
trying to visit it. In pseudocode, I want to do something like:
for controller in controllerlist:
for action in controller:
if user.has_access_to(action):
print_link_to(action)
Imagine that pseudocode in the context of a navigation bar where you want to
display links to all the pages a user can access but none of the pages that
they don't have access to.
--
Kirk Strauser
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"TurboGears" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/turbogears?hl=en
-~----------~----~----~----~------~----~------~--~---