forked from mirror/Part-DB.Part-DB-server
Added a tab "Build" to project info page, where you can see how often you can build this project.
This commit is contained in:
parent
6423e52092
commit
76ec63e760
10 changed files with 386 additions and 2 deletions
8
templates/components/projects.macro.html.twig
Normal file
8
templates/components/projects.macro.html.twig
Normal file
|
@ -0,0 +1,8 @@
|
|||
{% macro project_bom_entry_with_missing_instock(project_bom_entry, number_of_builds = 1) %}
|
||||
{# @var \App\Entity\ProjectSystem\ProjectBOMEntry project_bom_entry #}
|
||||
<b><a href="{{ entity_url(project_bom_entry.part) }}">{{ project_bom_entry.part.name }}</a></b>
|
||||
{% if project_bom_entry.name %} ({{ project_bom_entry.name }}){% endif %}:
|
||||
<b>{{ project_bom_entry.part.amountSum | format_amount(project_bom_entry.part.partUnit) }}</b> {% trans %}project.builds.stocked{% endtrans %}
|
||||
/
|
||||
<b>{{ (project_bom_entry.quantity * number_of_builds) | format_amount(project_bom_entry.part.partUnit) }}</b> {% trans %}project.builds.needed{% endtrans %}
|
||||
{% endmacro %}
|
Loading…
Add table
Add a link
Reference in a new issue