diff --git a/bda/admin.py b/bda/admin.py index 07d082d1..0c991237 100644 --- a/bda/admin.py +++ b/bda/admin.py @@ -129,9 +129,16 @@ class SpectacleAdmin(admin.ModelAdmin): list_filter = ("location",) search_fields = ("title", "location__name") +class TirageAdmin(admin.ModelAdmin): + model = Tirage + list_display = ("title", "ouverture", "fermeture", "active") + readonly_fields = ("token", ) + list_filter = ("active", ) + search_fields = ("title", ) + admin.site.register(Spectacle, SpectacleAdmin) admin.site.register(Salle) admin.site.register(Participant, ParticipantAdmin) admin.site.register(Attribution, AttributionAdmin) admin.site.register(ChoixSpectacle, ChoixSpectacleAdmin) -admin.site.register(Tirage) +admin.site.register(Tirage, TirageAdmin)