Allow to create new customers in backend (#2367)

This commit is contained in:
Raphael Michel
2021-12-06 12:27:21 +01:00
committed by GitHub
parent bfd37af467
commit 5c55219d45
6 changed files with 61 additions and 8 deletions

View File

@@ -2,15 +2,23 @@
{% load i18n %}
{% load bootstrap3 %}
{% block title %}
{% blocktrans trimmed with id=customer.identifier %}
Customer #{{ id }}
{% endblocktrans %}
{% endblock %}
{% block inner %}
<h1>
{% if not customer.id %}
{% trans "New customer" %}
{% else %}
{% blocktrans trimmed with id=customer.identifier %}
Customer #{{ id }}
{% endblocktrans %}
{% endif %}
{% endblock %}
{% block inner %}
<h1>
{% if not customer.id %}
{% trans "New customer" %}
{% else %}
{% blocktrans trimmed with id=customer.identifier %}
Customer #{{ id }}
{% endblocktrans %}
{% endif %}
</h1>
<form class="form-horizontal" action="" method="post">
{% csrf_token %}

View File

@@ -15,6 +15,8 @@
No customer accounts have been created yet.
{% endblocktrans %}
</p>
<a href="{% url "control:organizer.customer.create" organizer=request.organizer.slug %}"
class="btn btn-primary btn-lg"><i class="fa fa-plus"></i> {% trans "Create a new customer" %}</a>
</div>
{% else %}
<div class="panel panel-default">
@@ -41,6 +43,10 @@
</div>
</form>
</div>
<p>
<a href="{% url "control:organizer.customer.create" organizer=request.organizer.slug %}"
class="btn btn-default"><i class="fa fa-plus"></i> {% trans "Create a new customer" %}</a>
</p>
<div class="table-responsive">
<table class="table table-condensed table-hover">
<thead>