Commit 3714fd86 authored by Aurel's avatar Aurel

call on query must return result

propagate params from call to asSQLExpression on Query


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@17851 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 5baf286b
...@@ -326,8 +326,8 @@ class Query(QueryMixin): ...@@ -326,8 +326,8 @@ class Query(QueryMixin):
self.type = type self.type = type
self.search_key = key self.search_key = key
def __call__(self): def __call__(self, **kw):
self.asSQLExpression() return self.asSQLExpression(**kw)
def getRange(self): def getRange(self):
return self.range return self.range
...@@ -384,7 +384,7 @@ class Query(QueryMixin): ...@@ -384,7 +384,7 @@ class Query(QueryMixin):
range_value = self.getRange() range_value = self.getRange()
format = self.getFormat() format = self.getFormat()
if ignore_key: if ignore_key:
pass pass
elif range_value is not None: elif range_value is not None:
if isinstance(value, (list, tuple)): if isinstance(value, (list, tuple)):
if format is None: if format is None:
...@@ -530,8 +530,8 @@ class ComplexQuery(QueryMixin): ...@@ -530,8 +530,8 @@ class ComplexQuery(QueryMixin):
# XXX: What is that used for ?! It's utterly dangerous. # XXX: What is that used for ?! It's utterly dangerous.
self.__dict__.update(kw) self.__dict__.update(kw)
def __call__(self): def __call__(self, **kw):
self.asSQLExpression() return self.asSQLExpression(**kw)
def getQueryList(self): def getQueryList(self):
return self.query_list return self.query_list
......
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