]> git.0d.be Git - panikweb.git/commitdiff
use get_public_label when creating grid time cells
authorFrédéric Péters <fpeters@0d.be>
Sun, 25 Oct 2020 17:45:46 +0000 (18:45 +0100)
committerFrédéric Péters <fpeters@0d.be>
Sun, 25 Oct 2020 17:45:46 +0000 (18:45 +0100)
panikweb/templates/grid.html
panikweb/views.py

index bdb0b8b3476bc872bc9afd2dfcdb8e66194d18a1..0ea270be43a5d5c979bea23322077b0dadf66d40 100644 (file)
@@ -61,7 +61,7 @@
                                        {% endfor %}
                                      {% else %}
                                       <div class="continu"><strong><a
-                                          href="{% if cell.redirect_path %}{{ cell.redirect_path }}{% else %}{% url 'emission-view' slug=cell.nonstop_slug %}{% endif %}">{{ cell.get_public_label }}</a></strong></div>
+                                          href="{% if cell.redirect_path %}{{ cell.redirect_path }}{% else %}{% url 'emission-view' slug=cell.nonstop_slug %}{% endif %}">{{ cell }}</a></strong></div>
                                        {% if cell.w > 1 and cell.h > 1%}<p>la musique en continu</p>{% endif %}
                                      {% endif %}
                          </td>
index bf3c04c2bffcdb432e840db32d5eb6b16ce2ac84..37049b8ddf5242c17ce3efc46683954f0936536b 100644 (file)
@@ -303,15 +303,15 @@ class Grid(TemplateView):
             if nonstop.start < nonstop.end:
                 nonstops.append([nonstop.start.hour + nonstop.start.minute/60.,
                                  nonstop.end.hour + nonstop.end.minute/60.,
-                                 nonstop.title, nonstop.slug, nonstop])
+                                 nonstop.get_public_label(), nonstop.slug, nonstop])
             else:
                 # crossing midnight
                 nonstops.append([nonstop.start.hour + nonstop.start.minute/60.,
                                  24,
-                                 nonstop.title, nonstop.slug, nonstop])
+                                 nonstop.get_public_label(), nonstop.slug, nonstop])
                 nonstops.append([0,
                                  nonstop.end.hour + nonstop.end.minute/60.,
-                                 nonstop.title, nonstop.slug, nonstop])
+                                 nonstop.get_public_label(), nonstop.slug, nonstop])
         nonstops.sort()
 
         for i in range(nb_lines):