mirror of
https://github.com/partitioncloud/partitioncloud-server.git
synced 2025-01-23 17:26:26 +01:00
Remove add-partition template
This commit is contained in:
parent
4e6421f9dc
commit
4c29460ab2
@ -229,7 +229,7 @@ def delete_album(uuid):
|
||||
return redirect("/albums")
|
||||
|
||||
|
||||
@bp.route("/<album_uuid>/add-partition", methods=["GET", "POST"])
|
||||
@bp.route("/<album_uuid>/add-partition", methods=["POST"])
|
||||
@login_required
|
||||
def add_partition(album_uuid):
|
||||
db = get_db()
|
||||
@ -240,9 +240,6 @@ def add_partition(album_uuid):
|
||||
flash("Vous ne participez pas à cet album.")
|
||||
return redirect(f"/albums/{album.uuid}")
|
||||
|
||||
if request.method == "GET":
|
||||
return render_template("albums/add-partition.html", album=album, user=user)
|
||||
|
||||
error = None
|
||||
|
||||
if "name" not in request.form:
|
||||
|
@ -1,22 +0,0 @@
|
||||
{% extends 'base.html' %}
|
||||
|
||||
{% block header %}
|
||||
<h1>{% block title %}Ajouter une partition à {{ album.name }}{% endblock %}</h1>
|
||||
{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<form action="/albums/{{ album.uuid }}/add-partition" method="post" enctype="multipart/form-data">
|
||||
Titre*
|
||||
<input name="name" type="text" required />
|
||||
Auteur
|
||||
<input name="author" type="text" />
|
||||
Paroles
|
||||
<textarea id="paroles" name="body" type="text"></textarea>
|
||||
{% if partition_uuid %}
|
||||
<input name="partition-uuid" value="{{ partition_uuid }}" type="hidden">
|
||||
{% else %}
|
||||
<input name="file" type="file" required />
|
||||
{% endif %}
|
||||
<input type="submit" value="Ajouter" />
|
||||
</form>
|
||||
{% endblock %}
|
Loading…
Reference in New Issue
Block a user