admin.py 463 Bytes
Newer Older
1
from django.contrib import admin
2
from members.models import Member
3

4
from .models import ListAlias, MailingList, VerbatimAddress
5
6
7
8
9
10
11
12
13
14
15
16


class VerbatimAddressInline(admin.TabularInline):
    model = VerbatimAddress


class ListAliasInline(admin.TabularInline):
    model = ListAlias


@admin.register(MailingList)
class GeneralMeetingAdmin(admin.ModelAdmin):
17
18
    model = Member
    filter_horizontal = ('members',)
19
    inlines = (VerbatimAddressInline, ListAliasInline)