trytond-patches/multicompany_account_produc...

36 lines
1.5 KiB
Diff

diff -r dfbce32f79c5 product.py
--- a/trytond/trytond/modules/account_product/product.py Sun Mar 01 19:19:20 2015 +0100
+++ b/trytond/trytond/modules/account_product/product.py Wed Jul 12 12:42:53 2017 +0200
@@ -74,6 +74,7 @@
domain=[('parent', '=', None), ['OR',
('group', '=', None),
('group.kind', 'in', ['sale', 'both'])],
+ ('company', '=', Eval('context', {}).get('company', -1)),
],
states={
'invisible': (~Eval('context', {}).get('company')
@@ -85,6 +86,7 @@
domain=[('parent', '=', None), ['OR',
('group', '=', None),
('group.kind', 'in', ['purchase', 'both'])],
+ ('company', '=', Eval('context', {}).get('company', -1)),
],
states={
'invisible': (~Eval('context', {}).get('company')
@@ -225,6 +227,7 @@
domain=[('parent', '=', None), ['OR',
('group', '=', None),
('group.kind', 'in', ['sale', 'both'])],
+ ('company', '=', Eval('context', {}).get('company', -1)),
],
states={
'invisible': (~Eval('context', {}).get('company')
@@ -235,6 +238,7 @@
domain=[('parent', '=', None), ['OR',
('group', '=', None),
('group.kind', 'in', ['purchase', 'both'])],
+ ('company', '=', Eval('context', {}).get('company', -1)),
],
states={
'invisible': (~Eval('context', {}).get('company')