admin: add generic create and delete template
This commit is contained in:
11
passbook/admin/templates/generic/create_inheritance.html
Normal file
11
passbook/admin/templates/generic/create_inheritance.html
Normal file
@ -0,0 +1,11 @@
|
||||
{% extends "generic/create.html" %}
|
||||
|
||||
{% load i18n %}
|
||||
|
||||
{% block title %}
|
||||
{% blocktrans with type=request.GET.type %}Create {{ type }}{% endblocktrans %}
|
||||
{% endblock %}
|
||||
|
||||
{% block above_form %}
|
||||
<h1>{% blocktrans with type=request.GET.type %}Create {{ type }}{% endblocktrans %}</h1>
|
||||
{% endblock %}
|
||||
20
passbook/admin/templates/generic/delete.html
Normal file
20
passbook/admin/templates/generic/delete.html
Normal file
@ -0,0 +1,20 @@
|
||||
{% extends "administration/base.html" %}
|
||||
|
||||
{% load i18n %}
|
||||
{% load utils %}
|
||||
|
||||
{% block content %}
|
||||
<div class="container">
|
||||
{% block above_form %}
|
||||
<h1>{% trans 'Delete' %}</h1>
|
||||
{% endblock %}
|
||||
<div class="">
|
||||
<form method="post" class="form-horizontal">
|
||||
{% csrf_token %}
|
||||
<p>Are you sure you want to delete "{{ object }}"?</p>
|
||||
<a href="{% back %}" class="btn btn-default">{% trans 'Back' %}</a>
|
||||
<input type="submit" class="btn btn-danger" value="{% trans 'Delete' %}" />
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
{% endblock %}
|
||||
@ -1,7 +1,7 @@
|
||||
{% extends "administration/base.html" %}
|
||||
|
||||
{% load crispy_forms_tags %}
|
||||
{% load i18n %}
|
||||
{% load utils %}
|
||||
|
||||
{% block content %}
|
||||
<div class="container">
|
||||
@ -10,6 +10,7 @@
|
||||
<div class="">
|
||||
<form action="" method="post" class="form-horizontal">
|
||||
{% include 'blocks/form.html' with form=form %}
|
||||
<a class="btn btn-default" href="{% back %}">{% trans "Cancel" %}</a>
|
||||
<input type="submit" class="btn btn-primary" value="{% trans 'Create' %}" />
|
||||
</form>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user