Compensation routes
* improves compensation routes
This commit is contained in:
parent
b962e22c04
commit
13a15e4f56
@ -95,7 +95,7 @@ class EcoAccountTable(BaseTable):
|
||||
def __init__(self, *args, **kwargs):
|
||||
super().__init__(*args, **kwargs)
|
||||
self.title = _("Eco Accounts")
|
||||
self.add_new_url = reverse("compensation:account-new")
|
||||
self.add_new_url = reverse("compensation:acc-new")
|
||||
|
||||
def render_ac(self, value, record):
|
||||
"""
|
||||
|
@ -13,15 +13,21 @@ app_name = "compensation"
|
||||
urlpatterns = [
|
||||
# Main compensation
|
||||
path("", index_view, name="index"),
|
||||
path('new/', new_view, name='new'),
|
||||
path('open/<id>', open_view, name='open'),
|
||||
path('edit/<id>', edit_view, name='edit'),
|
||||
path('remove/<id>', remove_view, name='remove'),
|
||||
path('new', new_view, name='new'),
|
||||
path('<id>', open_view, name='open'),
|
||||
path('<id>/edit', edit_view, name='edit'),
|
||||
path('<id>/remove', remove_view, name='remove'),
|
||||
|
||||
# Payment
|
||||
path('pay/new', new_view, name='pay-new'),
|
||||
path('pay/<id>', open_view, name='pay-open'),
|
||||
path('pay/<id>/edit', edit_view, name='pay-edit'),
|
||||
path('pay/<id>/remove', remove_view, name='pay-remove'),
|
||||
|
||||
# Eco-account
|
||||
path("account/", account_index_view, name="account-index"),
|
||||
path('account/new/', account_new_view, name='account-new'),
|
||||
path('account/open/<id>', account_open_view, name='account-open'),
|
||||
path('account/edit/<id>', account_edit_view, name='account-edit'),
|
||||
path('account/remove/<id>', account_remove_view, name='account-remove'),
|
||||
path("acc/", account_index_view, name="acc-index"),
|
||||
path('acc/new/', account_new_view, name='acc-new'),
|
||||
path('acc/<id>', account_open_view, name='acc-open'),
|
||||
path('acc/<id>/edit', account_edit_view, name='acc-edit'),
|
||||
path('acc/<id>/remove', account_remove_view, name='acc-remove'),
|
||||
]
|
@ -194,7 +194,7 @@
|
||||
</div>
|
||||
<div class="col-sm-6">
|
||||
<div class="d-flex justify-content-end">
|
||||
<a href="{% url 'compensation:new' %}" title="{% trans 'Add new payment' %}">
|
||||
<a href="{% url 'compensation:pay-new' %}" title="{% trans 'Add new payment' %}">
|
||||
<button class="btn btn-outline-default">
|
||||
{% fa5_icon 'plus' %}
|
||||
{% fa5_icon 'money-bill-wave' %}
|
||||
@ -218,7 +218,7 @@
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for pay in intervention.payments.all %}
|
||||
<a href="{% url 'payment:open' pay.id %}">
|
||||
<a href="{% url 'compensation:pay-open' pay.id %}">
|
||||
<tr>
|
||||
<td>{{ pay.amount }}</td>
|
||||
<td>{{ pay.comment }}</td>
|
||||
|
@ -88,7 +88,7 @@
|
||||
{% trans 'Eco-account' %}
|
||||
</h4>
|
||||
<div class="row">
|
||||
<a href="{% url 'compensation:account-index' %}">
|
||||
<a href="{% url 'compensation:acc-index' %}">
|
||||
<div class="col-sm-5">
|
||||
<div class="qs-box d-flex justify-content-center align-items-center">
|
||||
{% fa5_icon 'tree' %}
|
||||
@ -110,12 +110,12 @@
|
||||
<div class="col-sm-12 col-lg">
|
||||
<div class="col-sm">
|
||||
<div class="row my-1">
|
||||
<a href="{% url 'compensation:account-new' %}">
|
||||
<a href="{% url 'compensation:acc-new' %}">
|
||||
<button class="btn btn-default">{% fa5_icon 'plus' %} {% trans 'Create' %}</button>
|
||||
</a>
|
||||
</div>
|
||||
<div class="row my-1">
|
||||
<a href="{% url 'compensation:account-index' %}">
|
||||
<a href="{% url 'compensation:acc-index' %}">
|
||||
<button class="btn btn-default">{% fa5_icon 'eye' %} {% trans 'Show' %}</button>
|
||||
</a>
|
||||
</div>
|
||||
|
@ -29,7 +29,7 @@
|
||||
</a>
|
||||
</li>
|
||||
<li class=" menu-elem">
|
||||
<a class="nav-btn nav-link" href="{% url 'compensation:account-index' %}">
|
||||
<a class="nav-btn nav-link" href="{% url 'compensation:acc-index' %}">
|
||||
{% fa5_icon 'tree' %}
|
||||
{% trans 'Eco-account' %}
|
||||
</a>
|
||||
|
Loading…
Reference in New Issue
Block a user