diff options
| author | William Henrotin <whe@odoo.com> | 2019-04-16 13:38:59 +0000 |
|---|---|---|
| committer | William Henrotin <whe@odoo.com> | 2019-04-16 13:38:59 +0000 |
| commit | 2b63b7e8edfd052682bb01be7a2b4f66c1f6e8fb (patch) | |
| tree | f66e967b1ba8b3727744bd88cbce8d87ba551ea2 /addons/stock/security | |
| parent | 3992b01de1420be0f57dac6a387e5005c329b37a (diff) | |
[FIX] stock: company_id on stock.move.line
Commit 240d191ba302e6df200f7c91898c83c08ced758a introduced the field
company_id on model stock.move.line and a python constraint that check
if the company is the same on the move line and on the related move.
In order to avoid performance issue, this commit replace the constraint
by a 'related' parameter on the company field.
As the company_id is not editable we suppose this change will not introduced
unwanted errors
Task : 1970012
closes odoo/odoo#32738
Signed-off-by: Simon Lejeune (sle) <sle@openerp.com>
Diffstat (limited to 'addons/stock/security')
| -rw-r--r-- | addons/stock/security/stock_security.xml | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/addons/stock/security/stock_security.xml b/addons/stock/security/stock_security.xml index e33e665842a..87c63386ca7 100644 --- a/addons/stock/security/stock_security.xml +++ b/addons/stock/security/stock_security.xml @@ -101,7 +101,7 @@ <field name="name">stock_move_line multi-company</field> <field name="model_id" search="[('model','=','stock.move.line')]" model="ir.model"/> <field name="global" eval="True"/> - <field name="domain_force">[('company_id','child_of',[user.company_id.id])]</field> + <field name="domain_force">['|',('company_id','=',False),('company_id','child_of',[user.company_id.id])]</field> </record> <record model="ir.rule" id="stock_quant_rule"> |
