2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-06-12 10:05:39 +00:00

Merge pull request #283 from SchrodingersGat/can-build

If a part has no bom items, the 'can_build' function now returns zero
This commit is contained in:
Oliver
2019-05-09 18:39:06 +10:00
committed by GitHub

View File

@ -284,7 +284,7 @@ class Part(models.Model):
# If this part does NOT have a BOM, result is simply the currently available stock
if not self.has_bom:
return self.available_stock
return 0
total = None