podcast_detail.html 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. {% extends "base_list.html" %}
  2. {% load static %}
  3. {% block title %}{{object.name}}{% endblock %}
  4. {% block head_extra %}
  5. <style>
  6. .cover {float:left; width:412px; margin-right:10px; padding-bottom:15px;}
  7. .summary {float:left; width:600px; margin-left:10px;}
  8. .header {padding-bottom:15px;}
  9. .image-wrapper { contain: content; }
  10. </style>
  11. {% endblock %}
  12. {% block lists %}
  13. <div class="row header">
  14. <div class="cover image-wrapper">
  15. <img src="{% if object.cover_image %}{{object.cover_image.url}}{% else %}{% static 'images/no-video-cover.jpg' %}{% endif %}" width="400px" />
  16. </div>
  17. <div class="summary">
  18. {% if object.description %}<p>{{object.description|safe|linebreaks|truncatewords:160}}</p>{% endif %}
  19. <hr />
  20. {% if object.google_podcast_url %}
  21. <p style="float:right;">
  22. <a href="{{object.google_podcast_url}}"><img src="{% static " images/google-logo.png" %}" width=35></a>
  23. </p>
  24. {% endif %}
  25. </div>
  26. <div class="deets">
  27. </div>
  28. </div>
  29. <div class="row">
  30. <div class="col-md">
  31. <h3>Last scrobbles</h3>
  32. <div class="table-responsive">
  33. <table class="table table-striped table-sm">
  34. <thead>
  35. <tr>
  36. <th scope="col">Date</th>
  37. <th scope="col">Episode</th>
  38. </tr>
  39. </thead>
  40. <tbody>
  41. {% for scrobble in scrobbles.all %}
  42. <tr>
  43. <td>{{scrobble.timestamp}}</td>
  44. <td>{{scrobble.podcast_episode}}</td>
  45. </tr>
  46. {% endfor %}
  47. </tbody>
  48. </table>
  49. </div>
  50. </div>
  51. </div>
  52. {% endblock %}