FreeMarker boolean Issue

FreeMarker template error:
Can't convert boolean to string automatically, because the "boolean_format" setting was "true,false", which is the legacy default computer-language format, and hence isn't accepted.

----
Tip: If you just want "true"/"false" result as you are generting computer-language output, use "?c", like ${myBool?c}.
----
Tip: You can write myBool?string('yes', 'no') and like to specify boolean formatting in place.
----
Tip: If you need the same two values on most places, the programmers should set the "boolean_format" setting to something like "yes,no".
----

----
FTL stack trace ("~" means nesting-related):
- Failed at: ${isCopanyUser} [in template "sys_page/company_new/patent/register.html" at line 95, column 79]
----

没有什么比FreeMarker的提示更清楚的了。boolean_format在哪里配置,待查手册?

posted @ 2016-03-31 12:25  任国强  阅读(1438)  评论(0编辑  收藏  举报