diff options
Diffstat (limited to 'templates')
| -rw-r--r-- | templates/layout.html | 5 | ||||
| -rw-r--r-- | templates/news/list.html | 4 |
2 files changed, 7 insertions, 2 deletions
diff --git a/templates/layout.html b/templates/layout.html index 709daef..1aa6173 100644 --- a/templates/layout.html +++ b/templates/layout.html @@ -36,5 +36,10 @@ src="{{ url_for('static', filename='jquery.js')}}"></script> <script type="text/javascript" src="{{ url_for('static', filename='famille.js')}}"></script> + <script type="text/javascript" + src="{{ url_for('static', filename='jquery.timeago.js')}}"></script> + <script type="text/javascript" + src="{{ url_for('static', filename='jquery.timeago.fr.js')}}"> + </script> </body> </html> diff --git a/templates/news/list.html b/templates/news/list.html index c0d7e0a..d25715b 100644 --- a/templates/news/list.html +++ b/templates/news/list.html @@ -11,7 +11,7 @@ {% for user in users %} <tr> <td><a href="{{url_for('view_user', user_id=user.id)}}">{{user.user_name}}</a></td> - <td>{{user.last_seen|format_date('%a %d %b à %Hh%M')}}</td> + <td>{{user.last_seen|format_ago('%a %d %b à %Hh%M')|safe}}</td> </tr> {% endfor %} </table> @@ -20,7 +20,7 @@ <ul id="last-comments"> {% for comment in comments %} <li><a href="{{url_for('view_user', user_id=comment.user_id)}}">{{comment.user_name}}</a> - {{comment.date|format_date('%a %d %b à %Hh%M')}}<br/> + {{comment.date|format_ago('%a %d %b à %Hh%M')|safe}}<br/> {{comment.content_cache|shortify|safe}} <a href="{{url_for('show_news', news_id=comment.news_id)}}#comments">[…]</a> </li> {% else %} |
