cubicweb/hooks/test/data/hooks.py
author Denis Laxalde <denis.laxalde@logilab.fr>
Wed, 17 Feb 2016 13:45:34 +0100
changeset 11129 97095348b3ee
parent 11084 hooks/test/data/hooks.py@ffd615e626f9
child 12355 c703dc95c82e
permissions -rw-r--r--
Merge with 3.22 branch The merge was clean, just dropped cubicweb/web/data/cubicweb.goa.js.

from cubicweb.predicates import is_instance
from cubicweb.hooks import notification


class FolderUpdateHook(notification.EntityUpdateHook):
    __select__ = (notification.EntityUpdateHook.__select__ &
                  is_instance('Folder'))
    order = 100  # late trigger so that metadata hooks come before.