]> git.0d.be Git - panikweb.git/blob - panikweb_templates/templates/grid.html
adjust width of grid page
[panikweb.git] / panikweb_templates / templates / grid.html
1 {% extends "emissions.html" %}
2 {% load paniktags i18n %}
3 {% block bodyID %}Grid{% endblock %}
4 {% block title %}{% trans 'Grid' %}{% endblock %}
5 {% block toptitle %}
6 <h1 class="top bg-title"><a href="{% url 'grid' %}">Grille</a></h1>
7 {% endblock %}
8 {% block nav %}
9 {% endblock %}
10 {% block main %}
11
12 <div id="grid">
13         <table>
14                 <tbody>
15                 <tr>
16                           <td style=""><br/></td>
17                           {% for weekday in weekdays %}
18                             <th class="day" width="13%">{{ weekday }}</th>
19                           {% endfor %}
20                           <td style=""><br/></td>
21                 </tr>
22                 {% for time_header, time_cells in times|zip:grid %}
23                 <tr>
24                           <th class="heure">{{ time_header }}</th>
25                           {% for cell in time_cells %}
26                           <td class="small cell {% if cell.schedules|length > 1 %}many {% endif %}{% if cell.schedules %}scheduled{% else %}nonstop musique-en-continu{% endif %}" {% if cell.w > 1 %}colspan="{{cell.w}}"{% endif %}
27                                       {% if cell.h > 1 %}rowspan="{{cell.h}}"{% endif %}>
28                                         {% if cell.time_label %}
29                                                 <div class="time-label">{{ cell.time_label }}</div>
30                                         {% endif %}
31                                       {% if cell.schedules %}
32                                         {% for schedule in cell.schedules %}
33                                         {% if forloop.first == False and cell.schedules|length > 1 %}<hr />{% endif %}
34                                         <div class="item {% for category in schedule.emission.categories.all %} {{ category|slugify }}{% endfor %}">
35                                         
36                                                 <strong>
37                                                         <a href="{% url 'emission-view' slug=schedule.emission.slug %}">
38                                                                 <span>{{ schedule.emission.title }}</span>                                                                                              
39                                                         </a>
40                                                 </strong>
41                                                 <br />
42                                                 {% if schedule.weeks_string or schedule.time_label %}
43                                                 {% spaceless %}
44                                                 <span>(</span>
45                                                   {% if schedule.time_label %}
46                                                   <span>{{ schedule.time_label }}</span>
47                                                     {% if schedule.weeks_string %}<span>, </span>{% endif %}
48                                                   {% endif %}
49                                                   {% if schedule.weeks_string %}
50                                                   <span>{{ schedule.weeks_string }}</span>
51                                                   {% endif %}
52                                                   {% if schedule.time_label_extra %}
53                                                   <span>{{ schedule.time_label_extra }}</span>
54                                                   {% endif %}
55                                                 <span>)</span>
56                                                 {% endspaceless %}
57                                                 {% endif %}
58                                                 
59                                         </div>
60                                         {% endfor %}
61                                       {% else %}
62                                       <div class="continu"><strong><a href="{% url 'emission-view' slug=cell.nonstop_slug %}">{{ cell }}</a></strong></div>
63                                         {% if cell.w > 1 and cell.h > 1%}<p>la musique en continu</p>{% endif %}
64                                       {% endif %}
65                           </td>
66                           {% endfor %}
67                           <th class="heure">{{ time_header }}</th>
68                 </tr>
69                 {% endfor %}
70                 </tbody>
71         </table>
72 </div>
73 {% endblock %}
74
75 {% block news %}
76 {% endblock %}
77