[Zope-CMF] permissions for new CMF type
Paul Winkler
pw_lists@slinkp.com
Fri, 15 Nov 2002 17:08:33 -0800
On Fri, Nov 15, 2002 at 04:22:44PM -0800, Fearless Froggie wrote:
> I created a new CMF type (CMFNewsICABC) for my portal,
> with a new permission "addCMFNewsICABC"
is this a filesystem product? zclass? "repurposed" content?
How exactly did you create this permission?
e.g. if it's a filesystem product, I do something like
this in __init__.py:
from Products.CMFCore import utils
utils.ContentInit(
'CMF Foo',
content_types = (CMFFooClass),
permission = 'Add portal content',
....
THe first arg is the portal_type, and the class itself
goes in content_types (I think; i just copied that from
other products and i confess i don't really understand
what the content_types argument does.)
Works for me.
--PW
--
Paul Winkler
http://www.slinkp.com
"Welcome to Muppet Labs, where the future is made - today!"