1 | from gheat.models import *
|
---|
2 | from django.contrib import admin
|
---|
3 |
|
---|
4 | class AccespointAdmin(admin.ModelAdmin):
|
---|
5 | list_display = ['ssid','mac', 'organization']
|
---|
6 | search_fields = ['ssid', 'mac', 'organization']
|
---|
7 | ordering = ['ssid']
|
---|
8 | admin.site.register(Accespoint, AccespointAdmin)
|
---|
9 |
|
---|
10 | class MeetBestandInline(admin.TabularInline):
|
---|
11 | model = MeetBestand
|
---|
12 | class MeetRondjeAdmin(admin.ModelAdmin):
|
---|
13 | inlines = [ MeetBestandInline, ]
|
---|
14 | admin.site.register(MeetRondje, MeetRondjeAdmin)
|
---|
15 |
|
---|
16 | class NodeAdmin(admin.ModelAdmin):
|
---|
17 | list_display = ['name','latitude', 'longitude', 'organization']
|
---|
18 | ordering = ['name']
|
---|
19 | admin.site.register(Node, NodeAdmin)
|
---|
20 |
|
---|
21 | class OrganizationAdmin(admin.ModelAdmin):
|
---|
22 | list_display = ['name', 'fullname']
|
---|
23 | ordering = ['name']
|
---|
24 | admin.site.register(Organization, OrganizationAdmin)
|
---|
25 |
|
---|
26 | class MeetBestandAdmin(admin.ModelAdmin):
|
---|
27 | list_display = ['meetrondje', 'bestand', 'is_imported']
|
---|
28 | admin.site.register(MeetBestand, MeetBestandAdmin)
|
---|
29 |
|
---|
30 | admin.site.register(Apparatuur)
|
---|
31 | admin.site.register(Gebruiker)
|
---|
32 |
|
---|
33 | class MetingAdmin(admin.ModelAdmin):
|
---|
34 | list_display = ['accespoint', 'latitude', 'longitude', 'signaal']
|
---|
35 | search_fields = ['accespoint__ssid']
|
---|
36 | admin.site.register(Meting, MetingAdmin)
|
---|