更新时间:2023-11-29 08:04:10
更简单的方法是在FreeMarker中不要这样做:-)听起来像控制器(或模型上的方法)应该在做些事情,而不是在查看模板.也就是说,您有几种选择:
The simpler way is to not do it in FreeMarker :-) This sounds like something controller (or method on model) should be doing rather than view template. That said, you have a few options:
<#attempt>中内置的?number/<#recover>
块.