improve Budget template

This commit is contained in:
2023-04-25 10:37:41 +00:00
committed by Julien Fastré
parent 9918cf2d58
commit 1d2b6e167f
10 changed files with 81 additions and 123 deletions

View File

@@ -32,28 +32,21 @@
{% endif %}
{% endfor %}
<h3 class="subtitle">{{ 'Actual budget'|trans }}</h3>
{% if actualCharges|length > 0 or actualResources|length > 0 %}
{% include 'ChillBudgetBundle:Budget:_current_budget.html.twig' with {
{% include '@ChillBudget/Budget/_current_budget.html.twig' with {
'actualResources': actualResources,
'actualCharges': actualCharges,
'results': results,
'entity': entity
} %}
{% else %}
<div class="flex-table">
<div class="item-bloc">
<p><span class="chill-no-data-statement">{{ "There isn't any element recorded"|trans }}</span></p>
</div>
</div>
<p><span class="chill-no-data-statement">{{ "There isn't any element recorded"|trans }}</span></p>
{% endif %}
{% if pastCharges|length > 0 or pastResources|length > 0 %}
<h2 class="subtitle">{{ 'Past budget'|trans }}</h2>
{% include 'ChillBudgetBundle:Budget:_past_budget.html.twig' with {
<h3 class="subtitle">{{ 'Past budget'|trans }}</h3>
{% include '@ChillBudget/Budget/_past_budget.html.twig' with {
'pastCharges': pastCharges,
'pastResources': pastResources,
'entity': entity
@@ -61,9 +54,8 @@
{% endif %}
{% if futureCharges|length > 0 or futureResources|length > 0 %}
<h2 class="subtitle">{{ 'Future budget'|trans }}</h2>
{% include 'ChillBudgetBundle:Budget:_future_budget.html.twig' with {
<h3 class="subtitle">{{ 'Future budget'|trans }}</h3>
{% include '@ChillBudget/Budget/_future_budget.html.twig' with {
'futureResources': futureResources,
'futureCharges': futureCharges,
'entity': entity