25 lines
1.3 KiB
Twig
25 lines
1.3 KiB
Twig
{% embed '@AdminLTE/Widgets/box-widget.html.twig' %}
|
|
{% import "macros/progressbar.html.twig" as progress %}
|
|
{% block box_title %}{{ 'label.budget'|trans }}{% endblock %}
|
|
{% block box_attributes %}id="budget_box"{% endblock %}
|
|
{% block box_body %}
|
|
{% set params = {
|
|
'%project%': '<strong>' ~ project.name ~ '</strong>',
|
|
'%customer%': '<strong>' ~ project.customer.name ~ '</strong>',
|
|
'%records%': '<strong>' ~ stats.recordAmount ~ '</strong>',
|
|
'%activities%': '<strong>' ~ stats.activityAmount ~ '</strong>',
|
|
'%duration%': '<strong>' ~ stats.recordDuration|duration ~ '</strong>'
|
|
} %}
|
|
|
|
{% set currency = project.customer.currency %}
|
|
|
|
<p>
|
|
{{ 'admin_project.short_stats'|trans(params)|raw }}
|
|
{{ 'label.rate_internal'|trans }}: {{ stats.recordInternalRate|money(currency) }}.
|
|
</p>
|
|
|
|
{{ progress.progressbar(project.budget, stats.recordRate, 'label.budget'|trans, stats.recordRate|money(currency) ~ ' / ' ~ project.budget|money(currency) ) }}
|
|
{{ progress.progressbar(project.timeBudget, stats.recordDuration, 'label.timeBudget'|trans, stats.recordDuration|duration ~ ' / ' ~ project.timeBudget|duration ) }}
|
|
{% endblock %}
|
|
{% endembed %}
|