summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--addons/account/models/account_analytic_line.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/addons/account/models/account_analytic_line.py b/addons/account/models/account_analytic_line.py
index b8756ac06ce..4e610fd6dcf 100644
--- a/addons/account/models/account_analytic_line.py
+++ b/addons/account/models/account_analytic_line.py
@@ -12,7 +12,8 @@ class AccountAnalyticLine(models.Model):
product_uom_id = fields.Many2one('uom.uom', string='Unit of Measure')
product_id = fields.Many2one('product.product', string='Product')
general_account_id = fields.Many2one('account.account', string='Financial Account', ondelete='restrict', readonly=True,
- related='move_id.account_id', store=True, domain=[('deprecated', '=', False)])
+ related='move_id.account_id', store=True, domain=[('deprecated', '=', False)],
+ compute_sudo=True)
move_id = fields.Many2one('account.move.line', string='Journal Item', ondelete='cascade', index=True)
code = fields.Char(size=8)
ref = fields.Char(string='Ref.')