Commit 0efe7dbf authored by Kazuhiko Shiozaki's avatar Kazuhiko Shiozaki

allow extra parameters in fixConsistency() and checkConsistency().


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@34855 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 485f8e33
......@@ -101,17 +101,17 @@ class Constraint:
return 0 # a condition was defined and is False
return 1 # no condition or a True condition was defined
def checkConsistency(self, obj, fixit=0):
def checkConsistency(self, obj, fixit=0, **kw):
"""
Default method is to return no error.
"""
errors = []
return errors
def fixConsistency(self, obj):
def fixConsistency(self, obj, **kw):
"""
Default method is to call checkConsistency with
fixit set to 1
"""
return self.checkConsistency(obj, fixit=1)
return self.checkConsistency(obj, fixit=1, **kw)
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