2015-11-18 08:44:06 +00:00
|
|
|
from django.contrib import admin
|
2016-11-25 12:47:09 +00:00
|
|
|
from ajax_select import make_ajax_form
|
2016-08-10 03:48:06 +00:00
|
|
|
from core.models import User, Page, RealGroup, SithFile
|
2016-01-28 16:42:22 +00:00
|
|
|
from django.contrib.auth.models import Group as AuthGroup
|
2015-11-18 08:44:06 +00:00
|
|
|
|
|
|
|
|
|
|
|
admin.site.register(User)
|
2016-01-28 16:42:22 +00:00
|
|
|
admin.site.unregister(AuthGroup)
|
2016-03-29 10:45:10 +00:00
|
|
|
admin.site.register(RealGroup)
|
2015-11-20 14:47:01 +00:00
|
|
|
admin.site.register(Page)
|
2015-11-18 08:44:06 +00:00
|
|
|
|
2016-11-25 12:47:09 +00:00
|
|
|
@admin.register(SithFile)
|
|
|
|
class SithFileAdmin(admin.ModelAdmin):
|
|
|
|
form = make_ajax_form(SithFile, {
|
|
|
|
'parent': 'files', # ManyToManyField
|
|
|
|
})
|