blob: ecf67dd80d11097aebe6484b4a087900c6d699a0 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
from django.contrib import admin
from .models import Organisation, Address, AddressType
class AddressTypeAdmin(admin.ModelAdmin):
pass
class AddressInLine(admin.StackedInline):
model = Address
class OrganisationAdmin(admin.ModelAdmin):
inlines = [AddressInLine,]
# Register your models here.
admin.site.register(Organisation, OrganisationAdmin)
admin.site.register(AddressType, AddressTypeAdmin)
|