Closed uladkaminski closed 5 years ago
First of all, my apologies for this extremely late reply.
By the stack trace included in the report, it seems that the #locale argument is interpreted as an String.
However, I've tested the following expressions:
<p th:text="${#locale}">locale</p>
<p th:text="${#locale.getClass().getName()}">locale class</p>
<p th:text="${#temporals.format(#temporals.createNow(), #locale)}">time</p>
and got the expected results:
en_GB
java.util.Locale
24 November 2018, 22:00:52
If anyone encounters a similar issue, please include the type of the time class used (ticket.getDateTime() in the previous report) and the value of the locale argument.
During this operation
${#temporals.format(ticket.getDateTime(), #locale)}
there is an issue:
java.lang.IllegalArgumentException: Unknown pattern letter: U at java.time.format.DateTimeFormatterBuilder.parsePattern(DateTimeFormatterBuilder.java:1661) ~[na:1.8.0_131] at java.time.format.DateTimeFormatterBuilder.appendPattern(DateTimeFormatterBuilder.java:1570) ~[na:1.8.0_131] at java.time.format.DateTimeFormatter.ofPattern(DateTimeFormatter.java:560) ~[na:1.8.0_131]