media_overview.html 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. {% extends "base_generic.html" %}
  2. {% load tags %}
  3. {% block script %}
  4. {% endblock %}
  5. {% block content %}
  6. <div class="container-fluid">
  7. <h3 style="margin-top: 10px">{{Product.name}} Media </h3>
  8. <table class="table table-sm table-hover">
  9. {% for pic in media %}
  10. <tr class="" >
  11. <td scope="col"><img src="{{pic.image_small.url}}" width="50" height="50" alt="{{ pic.name_for }}"> </td>
  12. <td scope="col"> {{pic.name_for }} </td>
  13. <td scope="col"> <a href="{% url 'delete-media' pk=pic.pk %}"><button type="button" class="btn btn-default" style="font-family: bariol_iconsbasic">T </button> </a> </td>
  14. </tr>
  15. {% endfor %}
  16. {% for pic in video %}
  17. <tr class="" >
  18. <td scope="col"><img src="{{pic.image.url}}" width="50" height="50" alt="Video: {{ pic.name_for }}"> </td>
  19. <td scope="col"> {{pic.name_for }} </td>
  20. <td scope="col" > <a href="{% url 'delete-video' pk=pic.pk %}"><button type="button" class="btn btn-default" style="font-family: bariol_iconsbasic">T </button> </a></td>
  21. </tr>
  22. {% endfor %}
  23. </table>
  24. <a href="{% url 'add-Image' Product.pk %}"> <button class="btn border-dark rounded-0 mybtn" type="submit">Add Media </button> </a>
  25. </div>
  26. {% endblock %}