Matteo Balduccio
09/30/2024, 1:31 PMCeligo AI
09/30/2024, 1:31 PMAI generated answer (using internal Slack threads):In Freemarker, you can round a number to two decimal places using the
?string
built-in function. This function formats a number to a string using a given pattern. The pattern "0.00"
will round your number to two decimal places.
Here is an example of how to use it:
freemarker
${yourNumber?string("0.00")}
In the context of your question, if you want to round a currency field to two decimal places, you can do it like this:
freemarker
${field.currency?string("0.00")}
******
Disclaimer:
This response was generated by an artificial intelligence assistant based on previous conversations from multiple Slack channels, and may contain inaccuracies or mistakes.
******Celigo AI
09/30/2024, 1:32 PMSlack thread 1: here (available only if the original thread was posted in the last 90 days)
Similarity score: 0.870437562
Slack thread 2: here (available only if the original thread was posted in the last 90 days)
Similarity score: 0.837454617
Slack thread 3: here (available only if the original thread was posted in the last 90 days)
Similarity score: 0.828569412
Celigo AI
09/30/2024, 1:32 PM