I am trying to convert a string in to an integer in a Jinja template without losing the decimal numbers
I tried the following code which partially works;
{{myfield|int}}
The problem is that I loose any decimal numbers (5.5 becomes 5 for example) is there a way to fix this?
You can use float instead of int:
{{myfield | float}}