[FIX] website_slides: can edit frontend enroll message
The frontend enroll message was display as a `<small/>` tag, but it
seems that lxml HTMLParser parse it wrongly, for example:
html.tostring(html.fromstring('<small data-oe-model="test"><p></p></small>'))
returns:
'<div><small data-oe-model="test"></small><p></p></div>'
So branding attributes like data-oe-model that are on small tag are not
found on root node that has become a `div` tag after parsing => this causes
a traceback error when saving a change in this part.
Fix: use small as wrapper for `<div/>` tag that is treated correctly by
HTMLParser (span is also treated correctly but div makes more sense
here).
opw-2573955
closes odoo/odoo#72315
X-original-commit: 6334c7282c19362ca8bc79dbaefe3d38c055e746
Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
This commit is contained in:
@@ -269,7 +269,9 @@
|
||||
</small>
|
||||
</div>
|
||||
<div t-else="" class="o_wslides_enroll_msg">
|
||||
<small t-field="channel.enroll_msg"/>
|
||||
<small>
|
||||
<div t-field="channel.enroll_msg"/>
|
||||
</small>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user