[Zope] Acquisition / proxying object
Joerg Baach
lists at baach.de
Mon Feb 25 17:52:26 EST 2008
Hi *,
> But somehow I have the feeling it has more to do with the 'and the
> container is not wrapped' part of the message. Not that I can make sense
> of it ;-)
Mmm, after even more searching, and not understanding I found
http://www.mail-archive.com/zope-dev@zope.org/msg11438.html
and changed my code to:
def __of__(self, parent):
'''foo'''
if not hasattr(parent,'aq_base'):
return self
folder,id = self.remoteid.split(':')
acl = parent.unrestrictedTraverse(folder)
remote = acl.getUser(id)
return Acquisition.ImplicitAcquisitionWrapper(aq_base(self),
aq_base(remote).__of__(parent))
Now, this actually seems to work. If only I knew why....
Cheers,
Joerg
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 252 bytes
Desc: OpenPGP digital signature
Url : http://mail.zope.org/pipermail/zope/attachments/20080225/e3c76687/signature.bin
More information about the Zope
mailing list