[Zope-CMF] Changing Object Creator

Rolander, Dan Dan.Rolander@marriott.com
Thu, 10 May 2001 13:17:21 -0400


Thanks for the info Flynt, but I'm afraid I don't possess enough zen to
comprehend this yet. I've created an external method but I'm getting errors
when trying to call it. What should the value of user be? Does it need to be
the id of my user object? If so, how should I obtain that? (A little more
code would help me).

Thanks,
Dan

> -----Original Message-----
> From: Flynt [mailto:rhess@bic.ch]
> Sent: Thursday, May 10, 2001 12:09 PM
> To: zope-cmf@zope.org
> Subject: Re: [Zope-CMF] Changing Object Creator
> 
> 
> "Rolander, Dan" wrote:
> > 
> > Is it possible to change the creator of an object? I have 
> inadvertently
> > created some things as Zope manager, and I'd like them to 
> be listed as
> > created by my CMF login. How do I do this?
> > 
> > Thanks,
> > Dan
> >
> The same question was answered yesterday by Tim and Dieter
> on the dev list. I just copy and paste it here:
> 
> tim@bcswebservices.net (Tim McLaughlin):
> --SNIP----
> Magnus,
> No, changeOwnership is not exposed for TTW calling.  But you 
> can expose
> it
> through an external method...  I used this one on a ZClass.
> 
> def set_owner(self, user):
>     self.changeOwnership(user)
>     return
> 
> --Tim
> --SNIP--------------
> 
> and Dieter Maurer (dieter@handshake.de):
> 
> --SNIP-------------
> 
> You do not look good enough or do not use the right tools, such
> as e.g.
> 
>   URL:http://www.dieter.handshake.de/pyprojects/zope/DocFinder.html
> 
> "DocFinder" revealed:
> 
>   Methods to manage ownership are in "AccessControl.Owned.Owned".
> 
>   There is "getOwner" and "changeOwnership". Both are private
>   (i.e. can be used only in Products and external methods).
> 
> 
> 
> Dieter
> ---SNIP--------------
> 
> 
> 
> HTH
> Flynt
> 
> 
> Regards
> Flynt
> 
> _______________________________________________
> Zope-CMF maillist  -  Zope-CMF@zope.org
> http://lists.zope.org/mailman/listinfo/zope-cmf
> 
> See http://www.zope.org/Products/PTK/Tracker for bug reports 
> and feature requests
>