2
0
mirror of https://expo.survex.com/repositories/troggle/.git synced 2024-11-26 01:01:53 +00:00

Sort people by notability

Better errors and tidy
Nicer date formats
This commit is contained in:
Sam Wenham 2019-04-02 02:04:38 +01:00
parent c4301cf6df
commit 05c5e26e99
5 changed files with 6 additions and 9 deletions

View File

@ -78,7 +78,7 @@ def EnterLogIntoDbase(date, place, title, text, trippeople, expedition, logtime_
""" saves a logbook entry and related persontrips """
trippersons, author = GetTripPersons(trippeople, expedition, logtime_underground)
if not author:
print(" - Skipping logentry: " + title + " no author for entry")
print(" - Skipping logentry: " + title + " - no author for entry")
return
#tripCave = GetTripCave(place)

View File

@ -176,9 +176,6 @@ def GetListDir(sdir):
return res
def LoadListScansFile(survexscansfolder):
gld = [ ]

View File

@ -69,7 +69,7 @@ an "S" for a survey trip. The colours are the same for people on the same trip.
{% regroup dateditems|dictsort:"date" by date as dates %}
{% for date in dates %}
<tr>
<td>{{date.grouper}}</td>
<td>{{date.grouper|date:"D d M Y"}}</td>
<td>{% for item in date.list %}
{% if item.isLogbookEntry %}<a href="{{ item.get_absolute_url }}">{{item.title|safe}}</a><br/>{% endif %}
{% endfor %}</td>

View File

@ -7,7 +7,7 @@
{% block related %}{% endblock %}
{% block nav %}{% endblock %}
<h2>{{logbookentry.title}}</h2>
<h2>{{logbookentry.title|safe}}</h2>
<div id="related">
<p><a href="{{ logbookentry.expedition.get_absolute_url }}">{{logbookentry.expedition.name}}</a></p>
@ -66,7 +66,7 @@
<div id="col1">
<div class="logbookentry">
<b>{{logbookentry.date}}</b>
<b>{{logbookentry.date|date:"D d M Y"}}</b>
{% if logbookentry.entry_type == "html" %}
<p>{{logbookentry.text|safe}}</p>
{% else %}

View File

@ -8,12 +8,12 @@
<h2>Notable expoers</h2>
<table class="searchable">
<tr><th>Person</th><th>First</th><th>Last</th><th>Notability</th></tr>
{% for person in notablepersons %}
{% for person in notablepersons|dictsortreversed:"notability" %}
<tr>
<td><a href="{{ person.get_absolute_url }}">{{person|wiki_to_html_short}}</a></td>
<td><a href="{{ person.first.get_absolute_url }}">{{ person.first.expedition.year }}</a></td>
<td><a href="{{ person.last.get_absolute_url }}">{{ person.last.expedition.year }}</a></td>
<td>{{person.notability}}</td>
<td>{{person.notability|floatformat:2}}</td>
</tr>
{% endfor %}
</table>