-
Notifications
You must be signed in to change notification settings - Fork 41
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[IMP] util/fields: update default when converting to html #156
base: master
Are you sure you want to change the base?
Conversation
cd5ce4c
to
e9d5416
Compare
src/util/fields.py
Outdated
SET json_value = REPLACE( | ||
REPLACE(json_value, '\n', '<br/>'), | ||
'\t', ' ' | ||
) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use pg_text2html
src/util/fields.py
Outdated
UPDATE ir_default AS d | ||
SET json_value = REPLACE( | ||
REPLACE(json_value, '\n', '<br/>'), | ||
'\t', ' ' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be part of pg_text2html
.
Instead of 4 spaces, we can use the  
entity (em space, U+2003)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we can use the
 
entity
Or just 	
.
1a8ffaa
to
595dd43
Compare
CI seems wrong to indicate a syntax error. |
You cannot use f-strings in the utils. It must be Python2 compatible. |
One could use Python escape sequences in text fields. When converting a field to HTML, they will no longer work, so replace them with HTML tags.
595dd43
to
84f0d0f
Compare
upgradeci retry |
One could use Python escape sequences in text fields. When converting a field to HTML, they will no longer work, so replace them with HTML tags.
Before:
After:
opw-4133947