[Zope3-Users] Principal annotations

Tom Dossis td at yoma.com.au
Thu Mar 9 01:44:24 EST 2006


Shane Hathaway wrote:
> Shane Hathaway wrote:
>> Was this an accident?  Did it work at one time?  Are there plans to make
>> principal annotation views work again?  And how can I edit user
>> annotations in the meanwhile?
> 
> No one knows, I guess.  After spending many days on a seemingly simple
> problem, I've drawn a blank.

Not that I've tried this myself (yet).

Re: the ZopeBook example, I'd change the annotation adapter from
IPrincipal to IInternalPrincipal..

<adapter
   factory=".info.PrincipalInformation"
   provides=".interfaces.IPrincipalInformation"
   for="zope.app.authentication.principalfolder.IInternalPrincipal"
   permission="zope.ManageServices"
   />

I guess you'd also need to make the InternalPrincipal class annotatable,
  in your application configure.zcml, add...

<content
  class="zope.app.authentication.principalfolder.InternalPrincipal">
  <implements
    interface="zope.app.annotation.IAttributeAnnotatable"
    />
</content>

Also in the example the browser:editform directive should be changed
from IPrincipal to IInternalPrincipal.

Good luck.
-Tom



More information about the Zope3-users mailing list