mirror of
https://github.com/eitchtee/WYGIWYH.git
synced 2026-04-25 01:58:54 +02:00
feat: automated replacement
This commit is contained in:
@@ -1,9 +1,9 @@
|
||||
{% load i18n %}
|
||||
<div class="container px-md-3 py-3 column-gap-5">
|
||||
<div class="tw:text-3xl fw-bold font-monospace tw:w-full mb-3">
|
||||
<div class="tw:container tw:px-md-3 tw:py-3 tw:column-gap-5">
|
||||
<div class="tw:text-3xl tw:font-bold tw:font-mono tw:w-full tw:mb-3">
|
||||
{% spaceless %}
|
||||
<div>{% translate 'Installment Plans' %}<span>
|
||||
<a class="text-decoration-none tw:text-2xl p-1 category-action"
|
||||
<a class="tw:no-underline tw:text-2xl tw:p-1 category-action"
|
||||
role="button"
|
||||
data-bs-toggle="tooltip"
|
||||
data-bs-title="{% translate "Add" %}"
|
||||
@@ -14,19 +14,15 @@
|
||||
{% endspaceless %}
|
||||
</div>
|
||||
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<ul class="nav nav-pills card-header-pills" id="myTab" role="tablist">
|
||||
<li class="nav-item" role="presentation">
|
||||
<button class="nav-link active" data-bs-toggle="tab" type="button" role="tab" aria-selected="true" hx-get="{% url 'active_installment_plans_list' %}" hx-trigger="load, click" hx-target="#installment-plans-table">{% translate 'All' %}</button>
|
||||
</li>
|
||||
<li class="nav-item" role="presentation">
|
||||
<button class="nav-link" hx-get="{% url 'finished_installment_plans_list' %}" hx-target="#installment-plans-table" data-bs-toggle="tab" type="button" role="tab" aria-selected="false">{% translate 'Finished' %}</button>
|
||||
</li>
|
||||
</ul>
|
||||
<div class="tw:card tw:bg-base-100 tw:shadow-xl">
|
||||
<div class="tw:card-header tw:bg-base-200 tw:p-4">
|
||||
<div role="tablist" class="tw:tabs tw:tabs-lifted">
|
||||
<button class="tw:tab tw:tab-active" data-bs-toggle="tab" type="button" role="tab" aria-selected="true" hx-get="{% url 'active_installment_plans_list' %}" hx-trigger="load, click" hx-target="#installment-plans-table">{% translate 'All' %}</button>
|
||||
<button class="tw:tab" hx-get="{% url 'finished_installment_plans_list' %}" hx-target="#installment-plans-table" data-bs-toggle="tab" type="button" role="tab" aria-selected="false">{% translate 'Finished' %}</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="card-body">
|
||||
<div class="tw:card-body">
|
||||
<div id="installment-plans-table"></div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -8,22 +8,22 @@
|
||||
{% if installment_plans %}
|
||||
<c-config.search></c-config.search>
|
||||
|
||||
<div class="table-responsive">
|
||||
<table class="table table-hover align-middle">
|
||||
<div class="tw:overflow-x-auto">
|
||||
<table class="tw:table tw:table-zebra">
|
||||
<thead>
|
||||
<tr>
|
||||
<th scope="col" class="col-auto"></th>
|
||||
<th scope="col" class="col">{% translate 'Name' %}</th>
|
||||
<th scope="col" class="col">{% translate 'Account' %}</th>
|
||||
<th scope="col" class="col">{% translate 'Amount' %}</th>
|
||||
<th scope="col" class="tw:w-auto"></th>
|
||||
<th scope="col">{% translate 'Name' %}</th>
|
||||
<th scope="col">{% translate 'Account' %}</th>
|
||||
<th scope="col">{% translate 'Amount' %}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for installment_plan in installment_plans %}
|
||||
<tr class="installment-plan">
|
||||
<td class="col-auto text-center">
|
||||
<div class="btn-group" role="group" aria-label="{% translate 'Actions' %}">
|
||||
<a class="btn btn-secondary btn-sm"
|
||||
<td class="tw:w-auto tw:text-center">
|
||||
<div class="tw:join" role="group" aria-label="{% translate 'Actions' %}">
|
||||
<a class="tw:btn tw:btn-secondary tw:btn-sm tw:join-item"
|
||||
role="button"
|
||||
data-bs-toggle="tooltip"
|
||||
data-bs-title="{% translate "Edit" %}"
|
||||
@@ -31,7 +31,7 @@
|
||||
hx-swap="innerHTML"
|
||||
hx-target="#generic-offcanvas">
|
||||
<i class="fa-solid fa-pencil fa-fw"></i></a>
|
||||
<a class="btn btn-secondary btn-sm"
|
||||
<a class="tw:btn tw:btn-secondary tw:btn-sm tw:join-item"
|
||||
role="button"
|
||||
data-bs-toggle="tooltip"
|
||||
data-bs-title="{% translate "Installments" %}"
|
||||
@@ -39,7 +39,7 @@
|
||||
hx-swap="innerHTML"
|
||||
hx-target="#persistent-generic-offcanvas-left">
|
||||
<i class="fa-solid fa-eye fa-fw"></i></a>
|
||||
<a class="btn btn-secondary btn-sm text-info"
|
||||
<a class="tw:btn tw:btn-secondary tw:btn-sm tw:join-item tw:text-info"
|
||||
role="button"
|
||||
data-bs-toggle="tooltip"
|
||||
data-bs-title="{% translate "Refresh" %}"
|
||||
@@ -52,7 +52,7 @@
|
||||
data-confirm-text="{% translate "Yes, refresh it!" %}"
|
||||
_="install prompt_swal">
|
||||
<i class="fa-solid fa-arrows-rotate fa-fw"></i></a>
|
||||
<a class="btn btn-secondary btn-sm text-danger"
|
||||
<a class="tw:btn tw:btn-secondary tw:btn-sm tw:join-item tw:text-error"
|
||||
role="button"
|
||||
data-bs-toggle="tooltip"
|
||||
data-bs-title="{% translate "Delete" %}"
|
||||
@@ -65,16 +65,16 @@
|
||||
_="install prompt_swal"><i class="fa-solid fa-trash fa-fw"></i></a>
|
||||
</div>
|
||||
</td>
|
||||
<td class="col">
|
||||
<td>
|
||||
<div class="{% if installment_plan.type == 'EX' %}tw:text-red-400{% else %}tw:text-green-400{% endif %}">
|
||||
{{ installment_plan.description }}
|
||||
</div>
|
||||
<div class="tw:text-sm tw:text-gray-400">{{ installment_plan.notes|linebreaksbr }}</div>
|
||||
<div class="tw:text-sm tw:text-base-content/60">{{ installment_plan.notes|linebreaksbr }}</div>
|
||||
</td>
|
||||
<td class="col-auto">
|
||||
<td class="tw:w-auto">
|
||||
{% if installment_plan.account.group %}{{ installment_plan.account.group }} • {% endif %}{{ installment_plan.account }}
|
||||
</td>
|
||||
<td class="col-auto">
|
||||
<td class="tw:w-auto">
|
||||
<c-amount.display
|
||||
:amount="installment_plan.installment_amount"
|
||||
:prefix="installment_plan.account.currency.prefix"
|
||||
|
||||
Reference in New Issue
Block a user