Skip to content

Commit 5562cee

Browse files
committed
Documented MongoDBManager.distinct(...).
1 parent 8795c14 commit 5562cee

File tree

3 files changed

+12
-1
lines changed

3 files changed

+12
-1
lines changed

django_mongodb_engine/contrib/__init__.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -153,4 +153,5 @@ def get_query_set(self):
153153
return MongoDBQuerySet(self.model, using=self._db)
154154

155155
def distinct(self, *args, **kwargs):
156+
""" Runs a :meth:`~pymongo.Collection.distinct` query against the database. """
156157
return self.get_query_set().distinct(*args, **kwargs)

docs/source/mongodbtheme/static/mongodb.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ h3 { margin-bottom: 0; }
158158
.section > div { margin-left: 1px; }
159159
.section > p, dl { margin-left: 3px; }
160160

161-
.section p, .section ul, .section .admonition, .section table,
161+
.section p, .section ul, .admonition, .section table,
162162
.sphinxsidebar p, .sphinxsidebar ul {
163163
font-size: 14px;
164164
line-height: 1.3;

docs/source/reference/lowerlevel.rst

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
.. the following warning is a 1:1 copy from topics/lowerlevel.rst
2+
.. warning::
3+
4+
These APIs are available for MongoDB only, so using any of these features
5+
breaks portability to other non-relational databases (Google App Engine,
6+
Cassandra, Redis, ...). For the sake of portability you should try to avoid
7+
database-specific features whenever possible.
8+
19
Lower-Level API
210
===============
311
::
@@ -18,3 +26,5 @@ Lower-Level API
1826
.. automethod:: MongoDBManager.raw_query
1927

2028
.. automethod:: MongoDBManager.raw_update
29+
30+
.. automethod:: MongoDBManager.distinct

0 commit comments

Comments
 (0)