plone.app.discussion/plone/app/discussion/subscribers.zcml
Timo Stollenwerk 52ebbe2e71 Fix #2494228: Remove comments as well when a content object is deleted.
svn path=/plone.app.discussion/trunk/; revision=34965
2010-03-16 15:06:43 +00:00

120 lines
3.6 KiB
XML

<configure
xmlns="http://namespaces.zope.org/zope"
xmlns:zcml="http://namespaces.zope.org/zcml"
i18n_domain="plone.app.discussion">
<!-- Plone 3 Event Subscribers -->
<configure zcml:condition="not-installed zope.app.container">
<subscriber
for="plone.app.discussion.interfaces.IComment
zope.lifecycleevent.interfaces.IObjectAddedEvent"
handler=".comment.notify_workflow"
/>
<subscriber
for="plone.app.discussion.interfaces.IComment
zope.lifecycleevent.interfaces.IObjectAddedEvent"
handler=".comment.notify_content_object"
/>
<subscriber
for="plone.app.discussion.interfaces.IComment
zope.lifecycleevent.interfaces.IObjectRemovedEvent"
handler=".comment.notify_content_object"
/>
<subscriber
for="plone.app.discussion.interfaces.IComment
zope.lifecycleevent.interfaces.IObjectAddedEvent"
handler=".tool.index_object"
/>
<subscriber
for="plone.app.discussion.interfaces.IComment
zope.lifecycleevent.interfaces.IObjectRemovedEvent"
handler=".tool.unindex_object"
/>
<!--
<subscriber
for="plone.app.discussion.interfaces.IComment
zope.lifecycleevent.interfaces.IObjectAddedEvent"
handler=".comment.notify_user"
/>
-->
<subscriber
for="plone.app.discussion.interfaces.IComment
zope.lifecycleevent.interfaces.IObjectAddedEvent"
handler=".comment.notify_moderator"
/>
<subscriber
for="Products.CMFCore.interfaces.IContentish
zope.lifecycleevent.interfaces.IObjectAddedEvent"
handler=".comment.notify_content_object_deleted"
/>
</configure>
<!-- Plone 4 Event Subscribers -->
<configure zcml:condition="installed zope.app.container">
<subscriber
for="plone.app.discussion.interfaces.IComment
zope.app.container.interfaces.IObjectAddedEvent"
handler=".comment.notify_workflow"
/>
<subscriber
for="plone.app.discussion.interfaces.IComment
zope.app.container.interfaces.IObjectAddedEvent"
handler=".comment.notify_content_object"
/>
<subscriber
for="plone.app.discussion.interfaces.IComment
zope.app.container.interfaces.IObjectRemovedEvent"
handler=".comment.notify_content_object"
/>
<subscriber
for="plone.app.discussion.interfaces.IComment
zope.app.container.interfaces.IObjectAddedEvent"
handler=".tool.index_object"
/>
<subscriber
for="plone.app.discussion.interfaces.IComment
zope.app.container.interfaces.IObjectRemovedEvent"
handler=".tool.unindex_object"
/>
<!--
<subscriber
for="plone.app.discussion.interfaces.IComment
zope.app.container.interfaces.IObjectAddedEvent"
handler=".comment.notify_user"
/>
-->
<subscriber
for="plone.app.discussion.interfaces.IComment
zope.app.container.interfaces.IObjectAddedEvent"
handler=".comment.notify_moderator"
/>
<subscriber
for="Products.CMFCore.interfaces.IContentish
zope.app.container.interfaces.IObjectRemovedEvent"
handler=".comment.notify_content_object_deleted"
/>
</configure>
</configure>