control.html 4.43 KB
Newer Older
1
{% extends 'cotisations/sidebar.html' %}
2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25
{% comment %}
Re2o est un logiciel d'administration développé initiallement au rezometz. Il
se veut agnostique au réseau considéré, de manière à être installable en
quelques clics.

Copyright © 2017  Gabriel Détraz
Copyright © 2017  Goulven Kermarec
Copyright © 2017  Augustin Lemesle

This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License along
with this program; if not, write to the Free Software Foundation, Inc.,
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
{% endcomment %}

26 27
{% load bootstrap3 %}
{% load staticfiles%}
28
{% load i18n %}
29

30
{% block title %}{% trans "Invoice control" %}{% endblock %}
31 32

{% block content %}
33

34
<h2>{% trans "Invoice control and validation" %}</h2>
35

36
{% if facture_list.paginator %}
37
    {% include 'pagination.html' with list=facture_list %}
38
{% endif %}
39

40 41 42 43 44 45
<form class="form" method="post">
    {% csrf_token %}
    {{ controlform.management_form }}
    <table class="table table-striped">
        <thead>
            <tr>
46
                <th>{% trans "Profile" %}</th>
47 48 49 50 51 52 53 54 55
                <th>
                    {% trans "Last name" as tr_last_name %}
                    {% include 'buttons/sort.html' with prefix='control' col='name' text=tr_last_name %}
                </th>
                <th>
                    {% trans "First name" as tr_first_name %}
                    {% include 'buttons/sort.html' with prefix='control' col='surname' text=tr_first_name %}
                </th>
                <th>
56
                    {% trans "Invoice ID" as tr_invoice_id %}
57 58 59
                    {% include 'buttons/sort.html' with prefix='control' col='id' text=tr_invoice_id %}
                </th>
                <th>
60
                    {% trans "User ID" as tr_user_id %}
61 62 63 64 65 66 67 68 69 70
                    {% include 'buttons/sort.html' with prefix='control' col='user-id' text=tr_user_id %}
                </th>
                <th>{% trans "Designation" %}</th>
                <th>{% trans "Total price" %}</th>
                <th>
                    {% trans "Payment method" as tr_payment_method %}
                    {% include 'buttons/sort.html' with prefix='control' col='paiement' text=tr_payment_method %}
                </th>
                <th>
                    {% trans "Date" as tr_date %}
71
                    {% include 'buttons/sort.html' with prefix='control' col='date' text=tr_date %}
72
		    </th>
73 74
                <th>
                    {% trans "Validated" as tr_validated %}
75 76
                    {% include 'buttons/sort.html' with prefix='control' col='valid' text=tr_validated %}
		    </th>
77 78 79 80
                <th>
                    {% trans "Controlled" as tr_controlled %}
                    {% include 'buttons/sort.html' with prefix='control' col='control' text=tr_controlled %}
                </th>
81 82 83 84 85
            </tr>
        </thead>
        {% for form in controlform.forms %}
        {% bootstrap_form_errors form %}
        <tr>
86 87 88 89
            <td>
                <a href="{% url 'users:profil' form.instance.user.id%}" class="btn btn-primary btn-sm" role="button">
                    <i class="fa fa-user"></i>
                </a>
90 91 92
            </td>
            <td>{{ form.instance.user.name }}</td>
            <td>{{ form.instance.user.surname }}</td>
93 94 95
            <td>{{ form.instance.id }}</td>
            <td>{{ form.instance.user.id }}</td>
	    <td>{{ form.instance.name }}</td>
96 97 98 99 100 101 102 103 104 105 106
            <td>{{ form.instance.prix_total }}</td>
            <td>{{ form.instance.paiement }}</td>
            <td>{{ form.instance.date }}</td>
            <td>{{ form.valid }}</td>
            <td>{{ form.control }}</td>
            {% for hidden in form.hidden_fields %}
            {{ hidden }}
            {% endfor %}
        </tr>
        {% endfor %}
    </table>
107
    {% trans "Edit" as tr_edit %}
108
    {% bootstrap_button tr_edit button_type='submit' icon='ok' button_class='btn-success' %}
109 110 111
</form>

{% endblock %}
112
{% if facture_list.paginator %}
113
    {% include 'pagination.html' with list=facture_list %}
114
{% endif %}
115