]> git.0d.be Git - panikdb.git/commitdiff
don't add "add to soma" link for fragments
authorFrédéric Péters <fpeters@0d.be>
Mon, 19 Aug 2019 14:04:45 +0000 (16:04 +0200)
committerFrédéric Péters <fpeters@0d.be>
Mon, 19 Aug 2019 14:04:45 +0000 (16:04 +0200)
panikdb/templates/emissions/episode_detail.html

index 4b9cce79792c0c5db454bf9017c99d476ecfbe47..9d3641fa54758b6f685200c369e94c58ceaa798f 100644 (file)
@@ -67,8 +67,12 @@ Tags :
 {% if can_manage and perms.emissions.delete_diffusion %}
 <a href="diffusion/{{ diffusion.id }}/remove" class="icon-remove-sign" title="Retirer"></a>
 {% endif %}
-{% if soundfiles and perms.nonstop.add_track and diffusion.datetime|date:"Y-m-d H:i" > now and not diffusion|is_already_in_soma %}
-<a href="{% url 'nonstop-add-diffusion' pk=diffusion.id %}">[programmer dans soma]</a>
+{% if soundfiles|integral and perms.nonstop.add_track and diffusion.datetime|date:"Y-m-d H:i" > now %}
+  {% if not diffusion|is_already_in_soma %}
+  <a href="{% url 'nonstop-add-diffusion' pk=diffusion.id %}">[programmer dans soma]</a>
+  {% else %}
+  (diffusion déjà programmée dans soma)
+  {% endif %}
 {% endif %}
 </li>
 {% endfor %}