You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

36 lines
811 B

{% extends "base.html" %}
{% load crispy_forms_tags %}
{% block content %}
<div class="row">
<div class="col-sm-12">
<div class="panel panel-{% if reasons %}danger{%else%}default{%endif%}">
<div class="panel-heading">Delete {{ object }}?</div>
<div class="panel-body">
{% if reasons %}
<p>
You cannot delete this object, as other objects in the database depend on it!
</p>
<p>
<ul>
{% for reason in reasons %}
<li>{{ reason }}</li>
{% endfor %}
</ul>
{% else %}
<p>
Are you sure you want to delete {{ object }}?
</p>
<form method="post" action="#">
{% csrf_token %}
<button type="submit" class="btn btn-primary">Delete {{ object }}</button>
</form>
{% endif %}
</div>
</div>
</div>
</div>
{% endblock %}