mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2025-12-21 18:39:31 +00:00
Show the creating or last editing user in part or structure info.
This commit is contained in:
parent
8a7b90d0ea
commit
73c2aa232d
7 changed files with 152 additions and 8 deletions
|
|
@ -7,11 +7,31 @@
|
|||
<td>{{ part.addedDate | format_datetime("long")}}</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>{% trans %}user.creating_user{% endtrans %}</td>
|
||||
<td>{% if is_granted('show_users', part) %}
|
||||
{{ getCreatingUser(part).fullName(true) ?? 'Unknown'|trans }}
|
||||
{% else %}
|
||||
{% trans %}accessDenied{% endtrans %}
|
||||
{% endif %}
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<tr> {# Last modified date #}
|
||||
<td>{% trans %}lastModified{% endtrans %}</td>
|
||||
<td>{{ part.lastModified | format_datetime("long")}}</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>{% trans %}user.last_editing_user{% endtrans %}</td>
|
||||
<td>{% if is_granted('show_users', part) %}
|
||||
{{ getLastEditingUser(part).fullName(true) ?? 'Unknown'|trans }}
|
||||
{% else %}
|
||||
{% trans %}accessDenied{% endtrans %}
|
||||
{% endif %}
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<tr> {# ID #}
|
||||
<td>{% trans %}id.label{% endtrans %}</td>
|
||||
<td>{{ part.iD }} ({{ part.iDString}})</td>
|
||||
|
|
|
|||
|
|
@ -2,11 +2,11 @@
|
|||
|
||||
<div class="mb-3">
|
||||
<span class="text-muted" title="{% trans %}lastModified{% endtrans %}">
|
||||
<i class="fas fa-history fa-fw"></i> {{ part.lastModified | format_datetime("short") }}
|
||||
<i class="fas fa-history fa-fw"></i> {{ helper.date_user_combination(part, true) }}
|
||||
</span>
|
||||
<br>
|
||||
<span class="text-muted mt-1" title="{% trans %}createdAt{% endtrans %}">
|
||||
<i class="fas fa-calendar-plus fa-fw"></i> {{ part.addedDate | format_datetime("short") }}
|
||||
<i class="fas fa-calendar-plus fa-fw"></i> {{ helper.date_user_combination(part, false) }}
|
||||
</span>
|
||||
</div>
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue