prompt.html.twig 1.1KB

123456789101112131415161718192021222324252627282930313233343536
  1. <div class="create_playlist">
  2. <h2>{{ 'playlist.create_and_add'|trans({}, 'elements') }}</h2>
  3. <form action="{{ path('playlist_add_element_and_create', { 'element_id' : element_id }) }}" method="post">
  4. {% include 'MuzichPlaylistBundle:Show:form.html.twig' %}
  5. </form>
  6. </div>
  7. <div>
  8. {% if playlists|length %}
  9. <h2 class="nomargintop">{{ 'playlist.add_to'|trans({}, 'elements') }}</h2>
  10. <ul class="playlists_for_element">
  11. {% for playlist in playlists %}
  12. <li class="playlist">
  13. <a class="add_element_to_playlist"
  14. {% if playlist.owned(app.user) %}
  15. href="{{ path_token('playlists_add_element', {
  16. 'playlist_id' : playlist.id,
  17. 'element_id' : element_id
  18. }) }}"
  19. {% else %}
  20. href="{{ path_token('playlists_add_element_and_copy', {
  21. 'playlist_id' : playlist.id,
  22. 'element_id' : element_id
  23. }) }}"
  24. {% endif %}
  25. >
  26. {{ playlist.name }}
  27. </a>
  28. </li>
  29. {% endfor %}
  30. </ul>
  31. {% else %}
  32. {% endif %}
  33. </div>