[Zope-CMF] permissions for new CMF type

Fearless Froggie fearless_froggie@yahoo.com
Fri, 15 Nov 2002 16:22:44 -0800 (PST)


Hi,

I created a new CMF type (CMFNewsICABC) for my portal,
with a new permission "addCMFNewsICABC". Now I created
a role so that only users with the "ICABC" role could
add CMFNewsICABC items. I gave the ICABC role all the
permissions of the "Member" role, plus the ability to
add "CMFNewsICABC" items.

I then created the following script so that only users
with the addCMFNewsICABC get the link to add
CMFNewsICABC items. ("vancouver_island" is the name of
the portal)

<dtml-let
icabcMgr="portal_membership.checkPermission('addCMFNewsICABC',vancouver_island)">
   <dtml-if icabcMgr>
      <br>* <a
href="&dtml-portal_url;/add_CMFNewsICABC">Add ICABC
News Item</a>
   </dtml-if>
</dtml-let>

I then created my new user with the "ICABC" role. When
I signed in with this userid, zope was not recognizing
that I had permission to add CMFNewsICABC items, ie I
didn't get the link to add them.

When I signed in with my Manager userid (defined in
the root), I had the ability to add CMFNewsICABC
items, ie the script above displayed the link. I went
into the security tab, turned off "acquire permission
settings" for the addCMFNewsICABC permission and made
sure the box wasn't ticked -- and I could still add
CMFNewsICABC items.

Basically, no matter what I do, I can't take away the
ability to add a CMFNewsICABC item from the Manager
user, and I can't give the ability to add a
CMFNewsICABC item to the ICABC user.

I exited and reran my browser for these tests. 

Can anybody possibly follow the gobbledy-gook above
and point me in the right direction? It seems pretty
straightforward to me, but I guess I'm missing
something.

Many Thanks!

Rita.

__________________________________________________
Do you Yahoo!?
Yahoo! Web Hosting - Let the expert host your site
http://webhosting.yahoo.com