Commit f6bc28e1 authored by Ayush Tiwari's avatar Ayush Tiwari

erp5_catalog: Methods in portal_component extension should use default_erp5_catalog

parent 6a9a37ab
......@@ -4,17 +4,17 @@ def getTableIdsUnrestricted(self):
The reason we need it here is that we need to get the result from the
restricted environment which isn't possible from inside ERP5.
This is because we are moving SQL Catalog inside ERP5 and converting it to
This is because we are moving Catalog inside ERP5 and converting it to
Folder object.
"""
# Get portal object
portal = self.getPortalObject()
# Get current SQL Catalog objects
default_sql_catalog = portal.portal_catalog.getSQLCatalog()
# Get current ERP5 Catalog objects
default_erp5_catalog = portal.portal_catalog.getERP5Catalog()
return default_sql_catalog.getTableIds()
return default_erp5_catalog.getTableIds()
def getCatalogMethodIdsUnrestricted(self):
"""
......@@ -22,17 +22,17 @@ def getCatalogMethodIdsUnrestricted(self):
The reason we need it here is that we need to get the result from the
restricted environment which isn't possible from inside ERP5.
This is because we are moving SQL Catalog inside ERP5 and converting it to
This is because we are moving Catalog inside ERP5 and converting it to
Folder object.
"""
# Get portal object
portal = self.getPortalObject()
# Get current SQL Catalog objects
default_sql_catalog = portal.portal_catalog.getSQLCatalog()
# Get current ERP5 Catalog objects
default_erp5_catalog = portal.portal_catalog.getERP5Catalog()
return default_sql_catalog.getCatalogMethodIds()
return default_erp5_catalog.getCatalogMethodIds()
def getResultColumnIdsUnrestricted(self):
"""
......@@ -40,17 +40,17 @@ def getResultColumnIdsUnrestricted(self):
The reason we need it here is that we need to get the result from the
restricted environment which isn't possible from inside ERP5.
This is because we are moving SQL Catalog inside ERP5 and converting it to
This is because we are moving Catalog inside ERP5 and converting it to
Folder object.
"""
# Get portal object
portal = self.getPortalObject()
# Get current SQL Catalog objects
default_sql_catalog = portal.portal_catalog.getSQLCatalog()
# Get current ERP5 Catalog objects
default_erp5_catalog = portal.portal_catalog.getERP5Catalog()
return default_sql_catalog.getResultColumnIds()
return default_erp5_catalog.getResultColumnIds()
def getColumnIdsUnrestricted(self):
"""
......@@ -58,17 +58,17 @@ def getColumnIdsUnrestricted(self):
The reason we need it here is that we need to get the result from the
restricted environment which isn't possible from inside ERP5.
This is because we are moving SQL Catalog inside ERP5 and converting it to
This is because we are moving Catalog inside ERP5 and converting it to
Folder object.
"""
# Get portal object
portal = self.getPortalObject()
# Get current SQL Catalog objects
default_sql_catalog = portal.portal_catalog.getSQLCatalog()
# Get current ERP5 Catalog objects
default_erp5_catalog = portal.portal_catalog.getERP5Catalog()
return default_sql_catalog.getColumnIds()
return default_erp5_catalog.getColumnIds()
def getSortColumnIdsUnrestricted(self):
"""
......@@ -76,17 +76,17 @@ def getSortColumnIdsUnrestricted(self):
The reason we need it here is that we need to get the result from the
restricted environment which isn't possible from inside ERP5.
This is because we are moving SQL Catalog inside ERP5 and converting it to
This is because we are moving Catalog inside ERP5 and converting it to
Folder object.
"""
# Get portal object
portal = self.getPortalObject()
# Get current SQL Catalog objects
default_sql_catalog = portal.portal_catalog.getSQLCatalog()
# Get current ERP5 Catalog objects
default_erp5_catalog = portal.portal_catalog.getERP5Catalog()
return default_sql_catalog.getSortColumnIds()
return default_erp5_catalog.getSortColumnIds()
def getPythonMethodIdsUnrestricted(self):
"""
......@@ -94,17 +94,17 @@ def getPythonMethodIdsUnrestricted(self):
The reason we need it here is that we need to get the result from the
restricted environment which isn't possible from inside ERP5.
This is because we are moving SQL Catalog inside ERP5 and converting it to
This is because we are moving Catalog inside ERP5 and converting it to
Folder object.
"""
# Get portal object
portal = self.getPortalObject()
# Get current SQL Catalog objects
default_sql_catalog = portal.portal_catalog.getSQLCatalog()
# Get current ERP5 Catalog objects
default_erp5_catalog = portal.portal_catalog.getERP5Catalog()
return default_sql_catalog.getPythonMethodIds()
return default_erp5_catalog.getPythonMethodIds()
def getSQLCatalogIdListUnrestricted(self):
"""
......@@ -112,11 +112,11 @@ def getSQLCatalogIdListUnrestricted(self):
The reason we need it here is that we need to get the result from the
restricted environment which isn't possible from inside ERP5.
This is because we are moving SQL Catalog inside ERP5 and converting it to
This is because we are moving Catalog inside ERP5 and converting it to
Folder object.
"""
# Get portal object
portal = self.getPortalObject()
return portal.portal_catalog.getSQLCatalogIdList()
return portal.portal_catalog.getERP5CatalogIdList()
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