[Zope] manage_beforeDelete, BeforeDeleteException and Redirect
Florent Guillaume
fg at nuxeo.com
Tue Aug 2 14:16:03 EDT 2005
Arthur Lutz <arthur.lutz at logilab.fr> wrote:
> I'm having a bit of struggle with OFS.ObjectManager in Zope 2.7.6-final.
> In a manage_beforeDelete I want to raise a Redirect but it gets eaten up
> by in ObjectManager by a log and pass (line 307).
>
> My question is: how do I get a Redirect through or how do I use the
> Exceptions that are actually caught (BeforeDeleteException or
> ConflictError - although the first seems more appropriate) ?
Raise BeforeDeleteException (or a subclass) in your code in
manage_beforeDelete.
Catch it and act on it from the code that calls manage_delObjects.
Florent
--
Florent Guillaume, Nuxeo (Paris, France) CTO, Director of R&D
+33 1 40 33 71 59 http://nuxeo.com fg at nuxeo.com
More information about the Zope
mailing list