Added internal part number field to parts

This commit is contained in:
Jan Böhmer 2022-12-04 02:28:47 +01:00
parent 81abf36867
commit b1d359f538
12 changed files with 123 additions and 3 deletions

View file

@ -1,4 +1,5 @@
{{ form_row(form.needsReview) }}
{{ form_row(form.favorite) }}
{{ form_row(form.mass) }}
{{ form_row(form.ipn) }}
{{ form_row(form.partUnit) }}

View file

@ -9,7 +9,7 @@
{% trans with {'%name%': part.name} %}part.edit.card_title{% endtrans %}
<b><a href="{{ entity_url(part, 'info') }}" class="text-white">{{ part.name }}</a></b>
<div class="float-end">
{% trans %}id.label{% endtrans %}: {{ part.id }}
{% trans %}id.label{% endtrans %}: {{ part.id }} {% if part.ipn is not empty %}(<i>{{ part.ipn }}</i>){% endif %}
</div>
{% endblock %}

View file

@ -37,6 +37,11 @@
<td>{{ part.iD }}</td>
</tr>
<tr> {# ID #}
<td>{% trans %}part.edit.ipn{% endtrans %}</td>
<td>{{ part.ipn ?? 'part.ipn.not_defined'|trans }}</td>
</tr>
<tr> {# Favorite status #}
<td>{% trans %}part.isFavorite{% endtrans %}</td>
<td>{{ helper.boolean(part.favorite) }}</td>

View file

@ -21,7 +21,7 @@
<i>({{ timeTravel | format_datetime('short') }})</i>
{% endif %}
<div class="float-end">
{% trans %}id.label{% endtrans %}: {{ part.id }}
{% trans %}id.label{% endtrans %}: {{ part.id }} {% if part.ipn is not empty %}(<i>{{ part.ipn }}</i>){% endif %}
</div>
{% endblock %}