trytond-patches/issue6341003_1.diff
Sergi Almacellas Abellana 07ba7ee5eb Add patch for bug3974
2014-06-05 16:47:35 +02:00

22 lines
1 KiB
Diff

Index: trytond/trytond/modules/account_asset/asset.xml
===================================================================
--- a/trytond/trytond/modules/account_asset/asset.xml
+++ b/trytond/trytond/modules/account_asset/asset.xml
@@ -130,6 +130,15 @@
<field name="name">asset_line_tree</field>
</record>
+ <record model="ir.rule.group" id="rule_group_asset_line">
+ <field name="model" search="[('model', '=', 'account.asset.line')]"/>
+ <field name="global_p" eval="True"/>
+ </record>
+ <record model="ir.rule" id="rule_asset_line1">
+ <field name="domain">[('asset.company', '=', user.company.id if user.company else None)]</field>
+ <field name="rule_group" ref="rule_group_asset_line"/>
+ </record>
+
<record model="ir.model.access" id="access_asset_line_account_admin">
<field name="model" search="[('model', '=', 'account.asset.line')]"/>
<field name="group" ref="account.group_account_admin"/>