Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Zope: CMF

[dev] event handlers in CMFCatalogAware

 

 

Zope cmf RSS feed   Index | Next | Previous | View Threaded


y.2007- at wcm-solutions

Dec 26, 2007, 9:56 AM

Post #1 of 2 (886 views)
Permalink
[dev] event handlers in CMFCatalogAware

Hi!


Trying to polish the event handlers in CMFCatalogAware I changed their
behavior a bit. Thinking more about it, the changes seem to be bugfixes
that should go into the CMF 2.1 branch as well:

1.) CMF 2.0 did update the 'Owner' local role in manage_afterClone().
This was done for any object. In CMF 2.1 this is limited to IContentish
objects - I guess by mistake.

2.) Updating the 'Owner' local role has to be done *before* the
notifyWorkflowCreated() and indexObject() calls.

3.) IObjectMovedEvent should use indexObject(), not reindexObject(). No
need to call notifyModified() as reindexObject() does.

If there are no objections, I'll backport the changes to the 2.1 branch.


Cheers,

Yuppie

_______________________________________________
Zope-CMF maillist - Zope-CMF [at] lists
http://mail.zope.org/mailman/listinfo/zope-cmf

See http://collector.zope.org/CMF for bug reports and feature requests


wichert at wiggy

Dec 27, 2007, 5:27 AM

Post #2 of 2 (817 views)
Permalink
Re: [dev] event handlers in CMFCatalogAware [In reply to]

Previously yuppie wrote:
> Hi!
>
>
> Trying to polish the event handlers in CMFCatalogAware I changed their
> behavior a bit. Thinking more about it, the changes seem to be bugfixes
> that should go into the CMF 2.1 branch as well:
>
> 1.) CMF 2.0 did update the 'Owner' local role in manage_afterClone().
> This was done for any object. In CMF 2.1 this is limited to IContentish
> objects - I guess by mistake.
>
> 2.) Updating the 'Owner' local role has to be done *before* the
> notifyWorkflowCreated() and indexObject() calls.
>
> 3.) IObjectMovedEvent should use indexObject(), not reindexObject(). No
> need to call notifyModified() as reindexObject() does.
>
> If there are no objections, I'll backport the changes to the 2.1 branch.

+1

Wichert.

--
Wichert Akkerman <wichert [at] wiggy> It is simple to make things.
http://www.wiggy.net/ It is hard to make things simple.
_______________________________________________
Zope-CMF maillist - Zope-CMF [at] lists
http://mail.zope.org/mailman/listinfo/zope-cmf

See http://collector.zope.org/CMF for bug reports and feature requests

Zope cmf RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.