[FIX] mrp: mrp user w/h inventory right

This commit is contained in:
Arnold Moyaux
2018-11-27 11:58:02 +00:00
parent 7206b385b5
commit 1efc2e9ad9
2 changed files with 4 additions and 3 deletions
+1 -1
View File
@@ -4,7 +4,7 @@
<record id="group_mrp_user" model="res.groups">
<field name="name">User</field>
<field name="implied_ids" eval="[(4, ref('base.group_user'))]"/>
<field name="implied_ids" eval="[(4, ref('stock.group_stock_user'))]"/>
<field name="category_id" ref="base.module_category_manufacturing"/>
</record>
<record id="group_mrp_manager" model="res.groups">
+3 -2
View File
@@ -51,6 +51,7 @@ class TestMrpCommon(common2.TestStockCommon):
super(TestMrpCommon, cls).setUpClass()
# Fetch mrp-related user groups
user_group_stock_user = cls.env.ref('stock.group_stock_user')
user_group_mrp_user = cls.env.ref('mrp.group_mrp_user')
user_group_mrp_manager = cls.env.ref('mrp.group_mrp_manager')
@@ -66,13 +67,13 @@ class TestMrpCommon(common2.TestStockCommon):
'login': 'hilda',
'email': 'h.h@example.com',
'notification_type': 'inbox',
'groups_id': [(6, 0, [user_group_mrp_user.id])]})
'groups_id': [(6, 0, [user_group_mrp_user.id, user_group_stock_user.id])]})
cls.user_mrp_manager = Users.create({
'name': 'Gary Youngwomen',
'login': 'gary',
'email': 'g.g@example.com',
'notification_type': 'inbox',
'groups_id': [(6, 0, [user_group_mrp_manager.id])]})
'groups_id': [(6, 0, [user_group_mrp_manager.id, user_group_stock_user.id])]})
cls.workcenter_1 = cls.env['mrp.workcenter'].create({
'name': 'Nuclear Workcenter',