2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-09-13 14:11:37 +00:00

Ensure stock check task runs in the background worker (#10266)

This commit is contained in:
Oliver
2025-09-04 14:39:11 +10:00
committed by GitHub
parent c6f46c587d
commit a3f4cc9b88

View File

@@ -767,7 +767,9 @@ class Build(
from build.tasks import check_build_stock from build.tasks import check_build_stock
# Run checks on required parts # Run checks on required parts
InvenTree.tasks.offload_task(check_build_stock, self, group='build') InvenTree.tasks.offload_task(
check_build_stock, self, group='build', force_async=True
)
@transaction.atomic @transaction.atomic
def hold_build(self): def hold_build(self):