forked from DGNum/gestioCOF
Merge branch 'Aufinal/reset_petitcours' into 'master'
Ajoute une fonction de remise à zéro des compteurs de petits cours fixes #45 See merge request !43
This commit is contained in:
commit
be5ba4090b
1 changed files with 7 additions and 0 deletions
|
@ -154,6 +154,13 @@ class PetitCoursAttributionCounterAdmin(admin.ModelAdmin):
|
|||
list_display = ('user','matiere','count',)
|
||||
list_filter = ('matiere',)
|
||||
search_fields = ('user__username', 'user__first_name', 'user__last_name', 'user__email', 'matiere__name')
|
||||
actions = ['reset',]
|
||||
actions_on_bottom = True
|
||||
|
||||
def reset(self, request, queryset):
|
||||
queryset.update(count=0)
|
||||
reset.short_description = u"Remise à zéro du compteur"
|
||||
|
||||
|
||||
class PetitCoursDemandeAdmin(admin.ModelAdmin):
|
||||
list_display = ('name','email','agrege_requis','niveau','created','traitee','processed')
|
||||
|
|
Loading…
Reference in a new issue