Added "data_type" index
authorThierry Florac <thierry.florac@onf.fr>
Wed, 11 Jul 2018 15:23:03 +0200
changeset 835 746f1b2f277a
parent 834 208fa7e30ea1
child 836 f33d67c86cdd
Added "data_type" index
src/pyams_content/generations/__init__.py
--- a/src/pyams_content/generations/__init__.py	Wed Jul 11 15:22:38 2018 +0200
+++ b/src/pyams_content/generations/__init__.py	Wed Jul 11 15:23:03 2018 +0200
@@ -9,6 +9,7 @@
 # WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS
 # FOR A PARTICULAR PURPOSE.
 #
+from pyams_content.shared.common.interfaces.types import IWfTypedSharedContent
 
 __docformat__ = 'restructuredtext'
 
@@ -96,6 +97,8 @@
 REQUIRED_INDEXES = [
     ('content_type', FieldIndexWithInterface, {'interface': IBaseContent,
                                                'discriminator': 'content_type'}),
+    ('data_type', FieldIndexWithInterface, {'interface': IWfTypedSharedContent,
+                                            'discriminator': 'data_type'}),
     ('role:owner', PrincipalsRoleIndex, {'role_id': OWNER_ROLE}),
     ('role:pilot', PrincipalsRoleIndex, {'role_id': PILOT_ROLE}),
     ('role:manager', PrincipalsRoleIndex, {'role_id': MANAGER_ROLE}),