2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-08-06 12:01:41 +00:00

Added stock status field

This commit is contained in:
Oliver Walters
2017-03-28 22:27:46 +11:00
parent 7bcea2f3ac
commit deda73a50f
4 changed files with 17 additions and 3 deletions

View File

@@ -4,7 +4,7 @@ from .models import PartCategory, Part
class PartAdmin(admin.ModelAdmin):
list_display = ('name', 'IPN', 'quantity', 'category')
list_display = ('name', 'IPN', 'stock', 'category')
# Custom form for PartCategory
class PartCategoryAdmin(admin.ModelAdmin):

View File

@@ -45,7 +45,7 @@ class Part(models.Model):
return self.stockitem_set.all()
@property
def quantity(self):
def stock(self):
""" Return the total stock quantity for this part.
Part may be stored in multiple locations
"""