docstring for where()
This commit is contained in:
parent
13afead9fb
commit
81b69648ef
1 changed files with 4 additions and 0 deletions
|
|
@ -1398,6 +1398,10 @@ class QuerySet(object):
|
||||||
return db.eval(code, *fields)
|
return db.eval(code, *fields)
|
||||||
|
|
||||||
def where(self, where_clause):
|
def where(self, where_clause):
|
||||||
|
"""Filter ``QuerySet`` results with a ``$where`` clause (a Javascript
|
||||||
|
expression). Performs automatic field name substitution like
|
||||||
|
:meth:`mongoengine.queryset.Queryset.exec_js`.
|
||||||
|
"""
|
||||||
where_clause = self._sub_js_fields(where_clause)
|
where_clause = self._sub_js_fields(where_clause)
|
||||||
self._where_clause = where_clause
|
self._where_clause = where_clause
|
||||||
return self
|
return self
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue