from django.contrib import admin
from .models import Enquete


@admin.register(Enquete)
class EnqueteAdmin(admin.ModelAdmin):
    list_display = ['intitule', 'reunion', 'cible', 'lieu', 'periode', 'datesysteme', 'created_by']
    list_filter = ['intitule',  'cible', 'lieu', 'periode', 'datesysteme', 'created_by']
    search_fields = ['intitule',  'cible', 'lieu']
    raw_id_fields = ['reunion']
    date_hierarchy = 'datesysteme'
    ordering = ['reunion', 'datesysteme']
