diff options
| author | Alexander Lazarević <laza@e11bits.com> | 2024-11-13 09:01:57 +0100 |
|---|---|---|
| committer | Sarah Boyce <42296566+sarahboyce@users.noreply.github.com> | 2024-11-14 12:09:50 +0100 |
| commit | 8590d05d44a4f3df56d988229e43d66c37df79da (patch) | |
| tree | 4a6f7b45f37b930ff4001cef1a1aa9f76e24f87c /docs/topics | |
| parent | 512a2bad0574a3748cb2f141a761a286a67f0ae9 (diff) | |
Fixed #35887 -- Added imports and admin.site.register to non-partial admin inline doc examples.
Diffstat (limited to 'docs/topics')
| -rw-r--r-- | docs/topics/db/multi-db.txt | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/docs/topics/db/multi-db.txt b/docs/topics/db/multi-db.txt index be7e9953fa..11be913f4c 100644 --- a/docs/topics/db/multi-db.txt +++ b/docs/topics/db/multi-db.txt @@ -683,6 +683,10 @@ Once you've written your model admin definitions, they can be registered with any ``Admin`` instance:: from django.contrib import admin + from myapp.models import Author, Book, Publisher + + # Import our custom ModelAdmin and TabularInline from where they're defined. + from myproject.admin import MultiDBModelAdmin, MultiDBTabularInline # Specialize the multi-db admin objects for use with specific models. |
