mirror of
https://expo.survex.com/repositories/troggle/.git
synced 2025-12-13 09:17:06 +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()},
|
||||
)
|
||||
|
||||
|
||||
@@ -52,6 +52,13 @@ See <em><a href="/caves_undropped">Undropped Caves</a></em> for all unexplored c
|
||||
{% include 'cavelist_columns.html' %}
|
||||
{% endfor %}
|
||||
</div>
|
||||
|
||||
<h3>The year before's caves</h3>
|
||||
<div style="column-count: 3;-moz-column-count: 3">
|
||||
{% for cave in caves_previous2_year %}
|
||||
{% include 'cavelist_columns.html' %}
|
||||
{% endfor %}
|
||||
</div>
|
||||
<p>
|
||||
See <em><a href="/caves">All Caves</a></em> for all the caves in areas 1623, 1626, 1624, 1627
|
||||
|
||||
|
||||
Reference in New Issue
Block a user