From c8f010cfa3ee8836f73094d5f8dc83e2ee5a0e3d Mon Sep 17 00:00:00 2001 From: Jared Kipe Date: Tue, 24 Apr 2018 13:26:25 -0700 Subject: [PATCH] Fix: Only managers can finish stock moves. --- maintenance_repair/models/maintenance.py | 1 + 1 file changed, 1 insertion(+) diff --git a/maintenance_repair/models/maintenance.py b/maintenance_repair/models/maintenance.py index 2a1b0603..9c19152a 100644 --- a/maintenance_repair/models/maintenance.py +++ b/maintenance_repair/models/maintenance.py @@ -127,6 +127,7 @@ class MaintenanceRequestRepairLine(models.Model): 'origin': request.name, 'analytic_account_id': analytic_account_id, }) + move = move.sudo() move._action_confirm() move._action_assign() if move.state != 'assigned':