add table headers to podcast list
[mygpo.git] / mygpo / share / templates / list.html
blobcb8965c44fa219505b2bd3b0b54df118a624ae8f
1 {% extends "base.html" %}
3 {% load i18n %}
4 {% load podcasts %}
5 {% load charts %}
6 {% load math %}
7 {% load utils %}
9 {% load menu %}
11 {% block mainmenu %}
12 {% if is_own %}
13 {{ "/share/"|main_menu }}
14 {% else %}
15 {{ "/directory/"|main_menu }}
16 {% endif %}
17 {% endblock %}
19 {% block sectionmenu %}
20 {% if is_own %}
21 {{ "/share/lists/"|section_menu }}
22 {% else %}
23 {{ "/lists/"|section_menu }}
24 {% endif %}
25 {% endblock %}
27 {% block title %}
28 {% blocktrans with podcastlist.title as list_title and owner.username as ownername %}"{{ list_title }}" by {{ ownername }}{% endblocktrans %}
29 {% endblock %}
31 {% block content %}
32 <h1>{{ podcastlist.title }}</h1>
33 {% url lists-user owner.username as user-lists-url %}
34 <small class="description">{% blocktrans with owner.username as ownername %}a podcast list by <a href="{{ user-lists-url }}">{{ ownername }}</a>{% endblocktrans %}</small>
35 <hr />
37 <table class="list">
38 <tr>
39 <th></th>
40 <th>{% trans "Podcast" %}</th>
41 <th>{% trans "Subscribers" %}</th>
42 </tr>
44 {% for podcast in podcastlist.podcasts %}
46 <tr>
47 <td>
48 {{ podcast|podcast_logo }}
49 </td>
50 <td>
51 {% podcast_group_link podcast %}
52 </td>
53 <td>{{ podcast.subscriber_count|vertical_bar:max_subscribers }}</td>
55 {% if is_own %}
56 <td>
57 <form action="{% url list-remove-podcast owner.username podcastlist.slug podcast.get_id %}" method="post" target="_parent">
58 {% csrf_token %}
59 <input type="submit" class="remove" value="" />
60 </form>
61 </td>
62 {% endif %}
63 </tr>
65 {% endfor %}
66 </table>
68 <div class="vote">
69 <form action="{% url list-rate owner.username podcastlist.slug %}?rate=1" method="post">
70 {% csrf_token %}
71 <input type="submit" value="{% trans "Like" %}" />
72 </form>
73 </div>
75 <div>
76 <a href="{% url list-opml owner.username podcastlist.slug %}">
77 <img src="/media/22x22/opml-icon.png" class="action-button" />
78 {% trans "Download as OPML" %}
79 </a>
80 </div>
82 {% if is_own %}
84 <hr />
86 <h2>Add Podcast</h2>
87 <form method="get" action="{% url list-search owner.username podcastlist.slug %}" class="search" target="results">
88 <input type="text" name="q" {% if q %}value="{{ q }}"{% endif %} >
89 <input type="submit" value="Search">
90 </form>
92 <iframe name="results" class="results">
93 </iframe>
95 {% endif %}
96 {% if not is_own and user.is_authenticated %}
98 <div class="info">
99 {% url lists-overview as create-url %}
100 {% blocktrans %}Create your own <a href="{{ create-url }}">podcast lists</a>.{% endblocktrans %}
101 </div>
103 {% endif %}
105 {% endblock %}