2021-08-09 12:41:44 +02:00
|
|
|
from django.contrib import admin
|
2020-09-10 15:06:53 +02:00
|
|
|
|
2021-10-23 11:16:07 +02:00
|
|
|
from .models import Event, Participants
|
2020-09-10 15:06:53 +02:00
|
|
|
|
2022-03-15 01:04:01 +01:00
|
|
|
class ParticipantsAdmin(admin.ModelAdmin):
|
|
|
|
fields = ["event", "participant", "reponse", "instrument", "instrument_autre", "dont_play_main", "details", "creationDate", "updateDate" ]
|
|
|
|
readonly_fields = [ "creationDate", "updateDate" ]
|
|
|
|
list_display = ["participant", "event", "reponse", "creationDate", "updateDate" ]
|
|
|
|
|
2021-06-07 00:56:03 +02:00
|
|
|
# Add event by admin page return a 502 error
|
2021-08-09 12:41:44 +02:00
|
|
|
admin.site.register(Event)
|
2022-03-15 01:04:01 +01:00
|
|
|
admin.site.register(Participants, ParticipantsAdmin)
|