Commit 5236b659 authored by Levy--Falk Hugo's avatar Levy--Falk Hugo

Fix l'historique

parent d6091d11
...@@ -30,6 +30,7 @@ from django.contrib import admin ...@@ -30,6 +30,7 @@ from django.contrib import admin
from reversion.admin import VersionAdmin from reversion.admin import VersionAdmin
from .models import Facture, Article, Banque, Paiement, Cotisation, Vente from .models import Facture, Article, Banque, Paiement, Cotisation, Vente
from .models import CustomInvoice
class FactureAdmin(VersionAdmin): class FactureAdmin(VersionAdmin):
...@@ -37,6 +38,11 @@ class FactureAdmin(VersionAdmin): ...@@ -37,6 +38,11 @@ class FactureAdmin(VersionAdmin):
pass pass
class CustomInvoiceAdmin(VersionAdmin):
"""Admin class for custom invoices."""
pass
class VenteAdmin(VersionAdmin): class VenteAdmin(VersionAdmin):
"""Class admin d'une vente, tous les champs (facture related)""" """Class admin d'une vente, tous les champs (facture related)"""
pass pass
...@@ -69,3 +75,4 @@ admin.site.register(Banque, BanqueAdmin) ...@@ -69,3 +75,4 @@ admin.site.register(Banque, BanqueAdmin)
admin.site.register(Paiement, PaiementAdmin) admin.site.register(Paiement, PaiementAdmin)
admin.site.register(Vente, VenteAdmin) admin.site.register(Vente, VenteAdmin)
admin.site.register(Cotisation, CotisationAdmin) admin.site.register(Cotisation, CotisationAdmin)
admin.site.register(CustomInvoice, CustomInvoiceAdmin)
...@@ -24,6 +24,7 @@ with this program; if not, write to the Free Software Foundation, Inc., ...@@ -24,6 +24,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
{% endcomment %} {% endcomment %}
{% load i18n %} {% load i18n %}
{% load acl %} {% load acl %}
{% load logs_extra %}
<div class="table-responsive"> <div class="table-responsive">
{% if custom_invoice_list.paginator %} {% if custom_invoice_list.paginator %}
...@@ -86,9 +87,7 @@ with this program; if not, write to the Free Software Foundation, Inc., ...@@ -86,9 +87,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
</li> </li>
{% acl_end %} {% acl_end %}
<li> <li>
<a href="{% url 'cotisations:history' 'custominvoice' invoice.id %}"> {% history_button invoice text=True html_class=False %}
<i class="fa fa-history"></i> {% trans "Historique" %}
</a>
</li> </li>
</ul> </ul>
</div> </div>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment