Added all() method to get all document instances from a document. Extended the FileField's tests with testing on empty filefield.

This commit is contained in:
flosch
2010-07-25 19:02:15 +02:00
parent 9411b38508
commit 2f991ac6f1
2 changed files with 10 additions and 1 deletions

View File

@@ -238,6 +238,10 @@ class QuerySet(object):
"""An alias of :meth:`~mongoengine.queryset.QuerySet.__call__`
"""
return self.__call__(*q_objs, **query)
def all(self):
"""Returns all documents."""
return self.__call__()
@property
def _collection(self):