summaryrefslogtreecommitdiff
path: root/docs/ref
diff options
context:
space:
mode:
Diffstat (limited to 'docs/ref')
-rw-r--r--docs/ref/contrib/databrowse.txt9
1 files changed, 7 insertions, 2 deletions
diff --git a/docs/ref/contrib/databrowse.txt b/docs/ref/contrib/databrowse.txt
index f8fedc4482..3d411bb7b4 100644
--- a/docs/ref/contrib/databrowse.txt
+++ b/docs/ref/contrib/databrowse.txt
@@ -33,13 +33,18 @@ How to use Databrowse
2. Register a number of models with the Databrowse site::
from django.contrib import databrowse
- from myapp.models import SomeModel, SomeOtherModel
+ from myapp.models import SomeModel, SomeOtherModel, YetAnotherModel
databrowse.site.register(SomeModel)
- databrowse.site.register(SomeOtherModel)
+ databrowse.site.register(SomeOtherModel, YetAnotherModel)
Note that you should register the model *classes*, not instances.
+ .. versionchanged:: 1.4
+
+ Since Django 1.4, it is possible to register several models in the same
+ call to :func:`~databrowse.site.register`.
+
It doesn't matter where you put this, as long as it gets executed at some
point. A good place for it is in your :doc:`URLconf file
</topics/http/urls>` (``urls.py``).