diff --git a/supysonic/frontend/playlist.py b/supysonic/frontend/playlist.py index a0cbeb4..4cd0418 100644 --- a/supysonic/frontend/playlist.py +++ b/supysonic/frontend/playlist.py @@ -40,6 +40,7 @@ def playlist_details(uid): return render_template("playlist.html", playlist=playlist) + @frontend.route("/playlist//export") def playlist_export(uid): try: @@ -57,9 +58,10 @@ def playlist_export(uid): return Response( render_template("playlist_export.m3u", playlist=playlist), mimetype="audio/mpegurl", - headers={"Content-disposition": f"attachment; filename={playlist.name}.m3u"} - ) - + headers={ + "Content-disposition": "attachment; filename={}.m3u".format(playlist.name) + }, + ) @frontend.route("/playlist/", methods=["POST"]) diff --git a/supysonic/static/js/supysonic.js b/supysonic/static/js/supysonic.js index e207c69..44c58b0 100644 --- a/supysonic/static/js/supysonic.js +++ b/supysonic/static/js/supysonic.js @@ -12,6 +12,6 @@ $(function () { $('[data-toggle="tooltip"]').tooltip() }); -$('#confirm-delete').on('show.bs.modal', function(e) { +$('.modal').on('show.bs.modal', function(e) { $(this).find('.btn-ok').attr('href', $(e.relatedTarget).data('href')); }); diff --git a/supysonic/templates/playlists.html b/supysonic/templates/playlists.html index 4949f15..8e5c479 100644 --- a/supysonic/templates/playlists.html +++ b/supysonic/templates/playlists.html @@ -32,8 +32,8 @@ aria-label="Public playlist">{% else %}{% endif %} - - + @@ -77,4 +77,24 @@ + {% endblock %}