Commit 26d5ef8d authored by Aurel's avatar Aurel

override some method so that predicate's criterion are not defined on

paysheet model cells when editing them though UI
parent f50553c1
...@@ -28,9 +28,9 @@ ...@@ -28,9 +28,9 @@
############################################################################## ##############################################################################
from AccessControl import ClassSecurityInfo from AccessControl import ClassSecurityInfo
from Products.ERP5Type import Permissions, PropertySheet, interfaces from Products.ERP5Type import Permissions
from Products.ERP5.Document.TradeModelCell import TradeModelCell from Products.ERP5.Document.TradeModelCell import TradeModelCell
import zope.interface from Products.ERP5Type.Core.Predicate import Predicate
class PaySheetModelCell(TradeModelCell): class PaySheetModelCell(TradeModelCell):
"""Trade Model Line """Trade Model Line
...@@ -49,3 +49,10 @@ class PaySheetModelCell(TradeModelCell): ...@@ -49,3 +49,10 @@ class PaySheetModelCell(TradeModelCell):
if not self.hasCellContent(base_id='variation'): if not self.hasCellContent(base_id='variation'):
result = self.getVariationRangeBaseCategoryList() # The current resource variation result = self.getVariationRangeBaseCategoryList() # The current resource variation
return result + ['trade_phase', 'quantity_unit'] return result + ['trade_phase', 'quantity_unit']
# Redefine some methods as we do not want to turn cells into predicate
def edit(self, **kw):
return super(Predicate, self).edit(**kw)
def setPredicateCategoryList(self, *args, **kw):
pass
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