diff --git a/InvenTree/build/models.py b/InvenTree/build/models.py index 79bedd5616..0e0068fdaf 100644 --- a/InvenTree/build/models.py +++ b/InvenTree/build/models.py @@ -133,6 +133,9 @@ class Build(models.Model): for item in self.allocated_stock.all(): item.delete() + # Date of 'completion' is the date the build was cancelled + self.completion_date = datetime.now().date() + self.status = self.CANCELLED self.save()