Ver código fonte

Clean up location templates

Colin Powell 1 ano atrás
pai
commit
abd07f3113

+ 2 - 2
vrobbler/templates/locations/geolocation_detail.html

@@ -1,7 +1,7 @@
 {% extends "base_list.html" %}
 {% load mathfilters %}
 {% load static %}
-{% load naturalduration %}
+{% load humanize %}
 
 {% block title %}{{object.title}}{% endblock %}
 
@@ -62,7 +62,7 @@
                 <tbody>
                     {% for scrobble in object.scrobble_set.all|dictsortreversed:"timestamp" %}
                     <tr>
-                        <td>{{scrobble.timestamp}}</td>
+                        <td>{{scrobble.timestamp|naturaltime}}</td>
                     </tr>
                     {% endfor %}
                 </tbody>

+ 2 - 0
vrobbler/templates/locations/geolocation_list.html

@@ -62,6 +62,7 @@
                 <thead>
                     <tr>
                         <th scope="col">Scrobbles</th>
+                        <th scope="col">Title</th>
                         <th scope="col">Point</th>
                     </tr>
                 </thead>
@@ -69,6 +70,7 @@
                     {% for location in object_list %}
                     <tr>
                         <td>{{location.scrobble_set.count}}</td>
+			<td>{{location.title}}</td>
                         <td><a href="{{location.get_absolute_url}}">{{location.lat}}x{{location.lon}}</a></td>
                     </tr>
                     {% endfor %}