The qu" /> The qu" /> The qu"/>

Odoo 13 How to edit field with Html widget from code?

1.5k Views Asked by At

I have field for description:

test_field = fields.Char(string='Test')

in XML form it looks like this:

<field name="test_field" widget="html" />

The question is How can I insert table row with some value from code to this field?

I tried to write html markup as a text like this:

enter image description here

but it wraps as paragraph and displays as ordinary text.

1

There are 1 best solutions below

0
kerbrose On BEST ANSWER

your field definition should be as following:

test_field = fields.Html(string='Test')