Dieter Maurer wrote:
[snip]
>  > Now replace the line "security.declarePublic('getTitle')" with something like
>  > "security.declareProtected('View', 'getTitle')", and suddenly nobody is
>  > allowed to call getTitle() on a Book object anymore.
> You must acquistion wrap your book objects. Otherwise, Zope's
> security code is unable to find the permission-role mapping.
> 
> Try:
> 
>       return books.__of__(self)

Aah, of course, makes sense. They should put this in the developer's guide!
The thing that tripped me up is that it works at all for declarePublic. :)

Thanks,

Martijn


_______________________________________________
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )

Reply via email to