summaryrefslogtreecommitdiff
path: root/indoteknik_custom/models/manufacturing.py
diff options
context:
space:
mode:
Diffstat (limited to 'indoteknik_custom/models/manufacturing.py')
-rw-r--r--indoteknik_custom/models/manufacturing.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/indoteknik_custom/models/manufacturing.py b/indoteknik_custom/models/manufacturing.py
index 715d8513..aea01362 100644
--- a/indoteknik_custom/models/manufacturing.py
+++ b/indoteknik_custom/models/manufacturing.py
@@ -11,6 +11,9 @@ class Manufacturing(models.Model):
def action_confirm(self):
if self._name != 'mrp.production':
return super(Manufacturing, self).action_confirm()
+
+ if not self.env.user.is_purchasing_manager:
+ raise UserError("Hanya bisa di confirm oleh Purchasing Manager")
# if self.location_src_id.id != 75:
# raise UserError('Component Location hanya bisa di AS/Stock')