mirror of
https://github.com/inventree/InvenTree.git
synced 2025-07-01 11:10:54 +00:00
Add "upload date" field to fileattachment base class
This commit is contained in:
@ -0,0 +1,18 @@
|
||||
# Generated by Django 3.0.5 on 2020-05-12 10:54
|
||||
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('stock', '0037_stockitemattachment_user'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AddField(
|
||||
model_name='stockitemattachment',
|
||||
name='upload_date',
|
||||
field=models.DateField(auto_now_add=True, null=True),
|
||||
),
|
||||
]
|
@ -22,7 +22,7 @@
|
||||
<tr>
|
||||
<th data-field='file' data-searchable='true'>{% trans "File" %}</th>
|
||||
<th data-field='comment' data-searchable='true'>{% trans "Comment" %}</th>
|
||||
<th data-field='user' data-searchable='true'>{% trans "Uploaded By" %}</th>
|
||||
<th data-field='user' data-searchable='true'>{% trans "Uploaded" %}</th>
|
||||
<th></th>
|
||||
</tr>
|
||||
</thead>
|
||||
@ -32,7 +32,8 @@
|
||||
<td><a href='/media/{{ attachment.attachment }}'>{{ attachment.basename }}</a></td>
|
||||
<td>{{ attachment.comment }}</td>
|
||||
<td>
|
||||
{% if attachment.user %}{{ attachment.user.username }}{% else %}-{% endif %}
|
||||
{% if attachment.upload_date %}{{ attachment.upload_date }}{% endif %}
|
||||
{% if attachment.user %}<span class='badge'>{{ attachment.user.username }}</div>{% endif %}
|
||||
</td>
|
||||
<td>
|
||||
<div class='btn-group' style='float: right;'>
|
||||
|
Reference in New Issue
Block a user