mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2026-01-09 03:39:34 +00:00
Added a part info tab to show in which projects the part is used.
This commit is contained in:
parent
d5b1c6be0a
commit
7f38095e82
4 changed files with 64 additions and 5 deletions
|
|
@ -91,6 +91,15 @@
|
|||
{% trans %}vendor.partinfo.history{% endtrans %}
|
||||
</a>
|
||||
</li>
|
||||
{% if part.projectBomEntries is not empty %}
|
||||
<li class="nav-item">
|
||||
<a class="nav-link" id="projects-tab" data-bs-toggle="tab" href="#projects" role="tab">
|
||||
<i class="fas fa-archive fa-fw"></i>
|
||||
{% trans %}device.labelp{% endtrans %}
|
||||
<span class="badge bg-secondary">{{ part.projectBomEntries | length }}</span>
|
||||
</a>
|
||||
</li>
|
||||
{% endif %}
|
||||
<li class="nav-item">
|
||||
<a class="nav-link" id="tools-tab" data-bs-toggle="tab" href="#tools" role="tab">
|
||||
<i class="fas fa-tools"></i>
|
||||
|
|
@ -130,6 +139,10 @@
|
|||
</div>
|
||||
{% endif %}
|
||||
|
||||
<div class="tab-pane fade" id="projects" role="tabpanel" aria-labelledby="projects-tab">
|
||||
{% include "Parts/info/_projects.html.twig" %}
|
||||
</div>
|
||||
|
||||
<div class="tab-pane fade" id="history" role="tabpanel" aria-labelledby="history-tab">
|
||||
{% include "Parts/info/_history.html.twig" %}
|
||||
</div>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue