From def300996ca04d852743c80467e328564f7fcaef Mon Sep 17 00:00:00 2001 From: qsm-odoo Date: Fri, 5 Aug 2016 14:37:29 +0200 Subject: [PATCH] [FIX] web_editor: adapt the forgotten rendering of updated contact fields The frontend allow the rendering of fields thanks to converters and their value_to_html and record_to_html methods. These methods were changed with https://github.com/odoo/odoo/commit/3407fb70e4a5b16174234d10d97710572b6f808c#diff-d5a9a5d91bd3171e30e7facd628bdf5cL411. The problem is that the web_editor also contains code which relies on these methods and it was not adapted. --- addons/web_editor/models/ir_qweb.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/addons/web_editor/models/ir_qweb.py b/addons/web_editor/models/ir_qweb.py index b1c0a165e44..35d0945dffe 100644 --- a/addons/web_editor/models/ir_qweb.py +++ b/addons/web_editor/models/ir_qweb.py @@ -159,10 +159,7 @@ class Contact(orm.AbstractModel): # helper to call the rendering of contact field @api.model def get_record_to_html(self, ids, options=None): - node = self.record_to_html('record', { - 'record': self.env['res.partner'].browse(ids[0])}, - options=options) - return node and node.__html__() + return self.value_to_html(self.env['res.partner'].browse(ids[0]), options=options) def parse_fuzzy(in_format, value):