aboutsummaryrefslogtreecommitdiff
path: root/pyaggr3g470r/templates/feed.html
blob: 9910ccf73b434aa222af262752bb3d800e67bc54 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
{% extends "layout.html" %}
{% block content %}
<div class="container">
    <div class="jumbotron">
        <h2>{{ feed.title }}</h2>
        {% if feed.description %} <p>{{ feed.description }}</p> {% endif %}
        <a href="/delete_feed/{{ feed.id }}"><i class="glyphicon glyphicon-remove" title="{{ _('Delete this feed') }}" onclick="return confirm('{{ _('You are going to delete this feed.') }}');"></i></a>
        <a href="/edit_feed/{{ feed.id }}"><i class="glyphicon glyphicon-edit" title="{{ _('Edit this feed') }}"></i></a>
    </div>
    <div class="jumbotron">
        <p>
        {{ _('This feed contains') }} {{ feed.articles.all()|count }} <a href="/articles/{{ feed.id }}/100">{{ _('articles') }}</a>
        {% if nb_articles != 0 %}
            ({{ ((feed.articles.all()|count * 100 ) / nb_articles) | round(2, 'floor') }}% {{ _('of the database') }})
        {% endif %}
        .<br />
        {% if feed.error_count > 2 %}
            <b>{{ _("That feed has encountered too much consecutive errors and won't be retreived anymore") }}</b>
        {% elif feed.error_count > 0 %}
            {{ _("That feed has encountered some errors but that counter will be reinitialized at the next successful retreiving") }}
        {% endif %}
        .<br />
        {% if feed.last_error %}
            {{ _("Here's the last error encountered while retreiving this feed:") }} <pre>{{ feed.last_error }}</pre>
        {% endif %}

        {{ _('Address of the feed') }}: <a href="{{ feed.link }}">{{ feed.link }}</a><br />
        {% if feed.site_link != "" %}
            {{ _('Address of the site') }}: <a href="{{ feed.site_link }}">{{ feed.site_link }}</a>
        {% endif %}
        <br />
        {% if feed.articles.all()|count != 0 %}
            {{ _('The last article was posted') }} {{ elapsed.days }} {{ _('day(s) ago.') }}<br />
            {{ _('Daily average') }}: {{ average }}, {{ _('between the') }} {{ first_post_date | datetime }} {{ _('and the') }} {{ end_post_date | datetime }}.
        {% endif %}
        </p>
    </div>
    <div class="jumbotron">
        {% if feed.articles.all()|count != 0 %}
            <div>{{ tag_cloud|safe }}</div>
        {% endif %}
    </div>
</div><!-- /.container -->
{% endblock %}
bgstack15