Commit 37b80134 authored by Ayush Tiwari's avatar Ayush Tiwari

erp5_catalog: Change inheritence order to restrict use of properties from ZCatalog

parent b684e8f2
......@@ -305,7 +305,7 @@ class RelatedBaseCategory(Method):
'RELATED_QUERY_SEPARATOR': RELATED_QUERY_SEPARATOR,
}
class CatalogTool (ZCatalog, CMFCoreCatalogTool, BaseTool):
class CatalogTool (BaseTool, ZCatalog, CMFCoreCatalogTool):
"""
This is a ZSQLCatalog that filters catalog queries.
It is based on ZSQLCatalog
......@@ -315,6 +315,8 @@ class CatalogTool (ZCatalog, CMFCoreCatalogTool, BaseTool):
meta_type = 'Catalog Tool'
portal_type = 'Catalog Tool'
allowed_types = ('Catalog',)
# Declarative security
security = ClassSecurityInfo()
default_result_limit = None
......@@ -327,6 +329,7 @@ class CatalogTool (ZCatalog, CMFCoreCatalogTool, BaseTool):
property_sheets = ( PropertySheet.Base
, PropertySheet.SimpleItem
, PropertySheet.Folder
, PropertySheet.CategoryCore
, PropertySheet.CatalogTool
)
......@@ -346,7 +349,7 @@ class CatalogTool (ZCatalog, CMFCoreCatalogTool, BaseTool):
def __init__(self):
ZCatalog.__init__(self, self.getId())
BaseTool.__init__(self, self.getId())
BaseTool.__init__(self, id)
# Filter content (ZMI))
def filtered_meta_types(self, user=None):
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment