now taking the parent if is td
This commit is contained in:
parent
7e70ceb67b
commit
136cbb18da
@ -37,7 +37,10 @@ class MailRenderMixin(models.AbstractModel):
|
|||||||
# anchor <a href odoo has a parent powered by that must be removed
|
# anchor <a href odoo has a parent powered by that must be removed
|
||||||
parent.getparent().remove(parent)
|
parent.getparent().remove(parent)
|
||||||
else:
|
else:
|
||||||
parent.remove(elem)
|
if parent.tag == 'td': # also here can be powerd by
|
||||||
|
parent.getparent().remove(parent)
|
||||||
|
else:
|
||||||
|
parent.remove(elem)
|
||||||
value = etree.tostring(tree, pretty_print=True, method="html")
|
value = etree.tostring(tree, pretty_print=True, method="html")
|
||||||
if type(value) is str:
|
if type(value) is str:
|
||||||
value = re.sub("[^(<)(</)]odoo", "", value, flags=re.IGNORECASE)
|
value = re.sub("[^(<)(</)]odoo", "", value, flags=re.IGNORECASE)
|
||||||
|
Loading…
Reference in New Issue
Block a user