2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-04-30 04:26:44 +00:00

Display attachment upload date

This commit is contained in:
Oliver 2021-06-30 17:44:23 +10:00
parent 9b4db43232
commit 30ac5dba55
5 changed files with 31 additions and 2 deletions

View File

@ -159,5 +159,10 @@ class BuildAttachmentSerializer(InvenTreeModelSerializer):
'pk', 'pk',
'build', 'build',
'attachment', 'attachment',
'comment' 'comment',
'upload_date',
]
read_only_fields = [
'upload_date',
] ]

View File

@ -157,6 +157,11 @@ class POAttachmentSerializer(InvenTreeModelSerializer):
'order', 'order',
'attachment', 'attachment',
'comment', 'comment',
'upload_date',
]
read_only_fields = [
'upload_date',
] ]
@ -359,4 +364,9 @@ class SOAttachmentSerializer(InvenTreeModelSerializer):
'order', 'order',
'attachment', 'attachment',
'comment', 'comment',
'upload_date',
]
read_only_fields = [
'upload_date',
] ]

View File

@ -61,7 +61,12 @@ class PartAttachmentSerializer(InvenTreeModelSerializer):
'pk', 'pk',
'part', 'part',
'attachment', 'attachment',
'comment' 'comment',
'upload_date',
]
read_only_fields = [
'upload_date',
] ]

View File

@ -270,6 +270,11 @@ class LocationSerializer(InvenTreeModelSerializer):
'parent', 'parent',
'pathstring', 'pathstring',
'items', 'items',
'upload_date',
]
read_only_fields = [
'upload_date',
] ]

View File

@ -51,6 +51,10 @@ function loadAttachmentTable(url, options) {
field: 'comment', field: 'comment',
title: '{% trans "Comment" %}', title: '{% trans "Comment" %}',
}, },
{
field: 'upload_date',
title: '{% trans "Upload Date" %}',
},
{ {
field: 'actions', field: 'actions',
formatter: function(value, row) { formatter: function(value, row) {