diff --git a/addons/account/controllers/mail.py b/addons/account/controllers/mail.py index 564856b909c..71c06faa44d 100644 --- a/addons/account/controllers/mail.py +++ b/addons/account/controllers/mail.py @@ -24,7 +24,7 @@ class MailController(MailController): except AccessError: if record_sudo.access_token and consteq(record_sudo.access_token, access_token): record_action = record_sudo.with_context( - force_website=True).get_access_action(uid) + force_website=True).get_access_action() if record_action['type'] == 'ir.actions.act_url': return werkzeug.utils.redirect(record_action['url']) return super(MailController, cls)._redirect_to_record(model, res_id, access_token=access_token) diff --git a/addons/account/models/account.py b/addons/account/models/account.py index cc303ec1309..7179b7f05f9 100644 --- a/addons/account/models/account.py +++ b/addons/account/models/account.py @@ -177,6 +177,8 @@ class AccountAccount(models.Model): @api.onchange('internal_type') def onchange_internal_type(self): self.reconcile = self.internal_type in ('receivable', 'payable') + if self.internal_type == 'liquidity': + self.reconcile = False @api.onchange('code') def onchange_code(self): diff --git a/addons/account/models/account_invoice.py b/addons/account/models/account_invoice.py index 4baac419a5f..249480c0ee4 100644 --- a/addons/account/models/account_invoice.py +++ b/addons/account/models/account_invoice.py @@ -1475,7 +1475,7 @@ class AccountInvoiceLine(models.Model): ondelete='set null', index=True, oldname='uos_id') product_id = fields.Many2one('product.product', string='Product', ondelete='restrict', index=True) - product_image = fields.Binary('Product Image', related="product_id.image", store=False) + product_image = fields.Binary('Product Image', related="product_id.image", store=False, readonly=True) account_id = fields.Many2one('account.account', string='Account', required=True, domain=[('deprecated', '=', False)], default=_default_account, diff --git a/addons/account/views/account_view.xml b/addons/account/views/account_view.xml index 40f01b1e1bc..c0aa8478ca1 100644 --- a/addons/account/views/account_view.xml +++ b/addons/account/views/account_view.xml @@ -22,8 +22,8 @@ -