Change stats years to 2000 up to current year

This commit is contained in:
Lukáš Kucharczyk 2023-11-12 07:50:12 +01:00
parent 8a433616c4
commit 200819ceb0
1 changed files with 6 additions and 1 deletions

View File

@ -32,7 +32,12 @@ def model_counts(request):
def stats_dropdown_year_range(request): def stats_dropdown_year_range(request):
return {"stats_dropdown_year_range": range(2018, 2024)} result = {
"stats_dropdown_year_range": range(
datetime.now(ZoneInfo(settings.TIME_ZONE)).year, 1999, -1
)
}
return result
def add_session(request, purchase_id=None): def add_session(request, purchase_id=None):