source: products/quintagroup.plonegooglesitemaps/trunk/quintagroup/plonegooglesitemaps/events.py

Last change on this file was 3510, checked in by potar, 8 years ago

Merged sitemap_date branch into trunk

  • Property svn:eol-style set to native
File size: 945 bytes
RevLine 
[1593]1try:
2    from Products.DCWorkflow.events import AfterTransitionEvent
[3163]3    AfterTransitionEvent()
[1593]4except ImportError:
5    # Copy AfterTransitionEvent from Plone-3/Products.DCWorkflow.events
6    from zope.interface import implements
7    from zope.app.event.objectevent import ObjectEvent
[3163]8    from quintagroup.plonegooglesitemaps.interfaces import ITransitionEvent, \
9        IAfterTransitionEvent
[1593]10
11    class TransitionEvent(ObjectEvent):
12        implements(ITransitionEvent)
13
[3510]14        def __init__(self, obj, workflow, old_state, new_state, transition,
[3152]15                     status, kwargs):
[1593]16            ObjectEvent.__init__(self, obj)
17            self.workflow = workflow
18            self.old_state = old_state
19            self.new_state = new_state
20            self.transition = transition
21            self.status = status
22            self.kwargs = kwargs
23
24    class AfterTransitionEvent(TransitionEvent):
[3152]25        implements(IAfterTransitionEvent)
Note: See TracBrowser for help on using the repository browser.