aurweb/templates/pkgbase/delete.html
Kevin Morris 3f95ac7db3
fix: correct redirects for package actions & requests
For requests, we always pass a `next` of /requests, leading us
back to the requests page. For a standard package, we get redirected
to the involved pkgbase, or target pkgbase if a merge action was taken.

Signed-off-by: Kevin Morris <kevr@0cost.org>
2022-02-08 22:59:01 -08:00

75 lines
2.2 KiB
HTML

{% extends "partials/layout.html" %}
{% block pageContent %}
{% if errors %}
<ul class="errorlist">
{% for error in errors %}
<li>{{ error | tr }}</li>
{% endfor %}
</ul>
{% endif %}
<div class="box">
<h2>{{ "Delete Package" | tr }}: {{ pkgbase.Name }}</h2>
<p>
{{
"Use this form to delete the package base %s%s%s and "
"the following packages from the AUR: "
| tr | format("<strong>", pkgbase.Name, "</strong>") | safe
}}
</p>
<ul>
{% for package in pkgbase.packages.all() %}
<li>{{ package.Name }}</li>
{% endfor %}
</ul>
<p>
{{
"This action will close any pending package requests "
"related to it. If %sComments%s are omitted, a closure "
"comment will be autogenerated."
| tr | format("<em>", "</em>") | safe
}}
</p>
<p>
{{
"Deletion of a package is permanent. "
"Select the checkbox to confirm action." | tr
}}
</p>
<form action="/pkgbase/{{ pkgbase.Name }}/delete" method="post">
<fieldset>
<input type="hidden" name="next" value="{{ next }}" />
<p>
<label for="id_comments">{{ "Comments" | tr }}:</label>
<textarea id="id_comments" name="comments"
rows="5" cols="50"
placeholder="Related package request closure comments..."
></textarea>
</p>
<p>
<label class="confirmation">
<input type="checkbox" name="confirm" value="1" />
{{ "Confirm package deletion" | tr }}
</label>
</p>
<p>
<input class="button"
type="submit"
value="{{ 'Delete' | tr }}"
/>
</p>
</fieldset>
</form>
</div>
{% endblock %}