What is the proper syntax to determine whether the user has a role using zpt. ... ????????????????????????????????? <p tal:omit-tag=???"not:user/has_role/Manager"??? ????????????????????????????????? tal:content="structure here/managerContent.html"> <span tal:replace="structure here/content.html"></span> </p> ... --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.481 / Virus Database: 277 - Release Date: 5/13/2003
On Tue, May 13, 2003 at 01:38:48PM -0400, Jamie White wrote:
What is the proper syntax to determine whether the user has a role using zpt. ... ????????????????????????????????? <p tal:omit-tag=???"not:user/has_role/Manager"??? ?????????????????????????????????
tal path expressions don't allow you to pass arguments, you need a python expression for that. also, i think what you want is tal:condition, not tal:omit-tag. try this: <p tal:condition="python: user.has_role('Manager')" .... -- Paul Winkler home: http://www.slinkp.com "Muppet Labs, where the future is made - today!"
participants (2)
-
Jamie White -
Paul Winkler