mirror of
https://expo.survex.com/repositories/troggle/.git
synced 2026-02-08 12:51:11 +00:00
add 2 years before caves to recent page
This commit is contained in:
@@ -272,6 +272,13 @@ def caves_recent(request):
|
||||
caves_previous_year.append(c)
|
||||
caves_previous_year.sort(key=caveKey)
|
||||
|
||||
caves_previous2_year = []
|
||||
for c in allcaves:
|
||||
previous_year = str(int(current_expo()) - 3)
|
||||
if c.unofficial_number.startswith(previous_year):
|
||||
caves_previous2_year.append(c)
|
||||
caves_previous2_year.sort(key=caveKey)
|
||||
|
||||
return render(
|
||||
request,
|
||||
"caveindex.html",
|
||||
@@ -283,6 +290,7 @@ def caves_recent(request):
|
||||
"caves_this_year": caves_this_year,
|
||||
"caves_last_year": caves_last_year,
|
||||
"caves_previous_year": caves_previous_year,
|
||||
"caves_previous2_year": caves_previous2_year,
|
||||
"cavepage": True, "year": current_expo()},
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user