[FIX]Docx Report Generation : fix return line to space

For better handling of some outside copy/paste.
This commit is contained in:
Fabien BOURGEOIS 2025-02-10 21:38:42 +01:00
parent 316437ccfc
commit 3b52c81b27
2 changed files with 3 additions and 3 deletions

View File

@ -14,7 +14,7 @@
"author": "RYDLAB, Yaltik",
"website": "https://rydlab.ru",
"category": "Technical",
"version": "16.0.2.2.2",
"version": "16.0.2.2.3",
"license": "LGPL-3",
"depends": ["base", "web", "custom_report_field", "report_monetary_helpers"],
"external_dependencies": {"python": ["docxcompose", "docxtpl", "beautifulsoup4"]},

View File

@ -469,8 +469,8 @@ class IrActionsReport(models.Model):
html_field = unescape(
str(field)
.replace('<br>', '')
.replace('\t', '')
.replace('\n', '')
.replace('\t', ' ')
.replace('\n', ' ')
).replace('&', '\uFF06')
xml_tree = etree.fromstring('<root>%s</root>' % html_field)
md = tpl.new_subdoc()