mirror of
https://github.com/inventree/InvenTree.git
synced 2026-10-06 18:31:16 +00:00
add stocktake data as tabular inline (admin)
This commit is contained in:
1 parent
be07b4b4df
commit
c47778603f
1 file changed
+9
@@ -104,6 +104,11 @@ class PartResource(InvenTreeResource):
|
||||
models.Part.objects.rebuild()
|
||||
|
||||
|
||||
class StocktakeInline(admin.TabularInline):
|
||||
"""Inline for part stocktake data"""
|
||||
model = models.PartStocktake
|
||||
|
||||
|
||||
class PartAdmin(ImportExportModelAdmin):
|
||||
"""Admin class for the Part model"""
|
||||
|
||||
@@ -122,6 +127,10 @@ class PartAdmin(ImportExportModelAdmin):
|
||||
'default_supplier',
|
||||
]
|
||||
|
||||
inlines = [
|
||||
StocktakeInline,
|
||||
]
|
||||
|
||||
|
||||
class PartPricingAdmin(admin.ModelAdmin):
|
||||
"""Admin class for PartPricing model"""
|
||||
|
||||
Reference in new issue
Block a user