X-Git-Url: https://git.mdrn.pl/wolnelektury.git/blobdiff_plain/1f4c831ff6f96b3a34fcca497adfd16838abc569..1c9e2865ce8c6ab51b2fa3e43d3661089e7b7eb8:/src/stats/admin.py diff --git a/src/stats/admin.py b/src/stats/admin.py index 979f18022..9e5ab4744 100644 --- a/src/stats/admin.py +++ b/src/stats/admin.py @@ -2,4 +2,12 @@ from django.contrib import admin from . import models -admin.site.register(models.Visits) +class VisitsAdmin(admin.ModelAdmin): + list_display = ['book', 'date', 'views', 'unique_views'] + raw_id_fields = ['book'] + date_hierarchy = 'date' + + + +admin.site.register(models.Visits, VisitsAdmin) +admin.site.register(models.DayVisits, VisitsAdmin)