判断
<#if value?is_number ></#if>
value类型是否为number
productType?eval
将字符串类型转换成数字类型
java 中数据格式
Map<String,List<Map<String,List<Map<String,Object>>>>>
Map<String,List<Map<String,Object>>>>
<#if (list?size >0)>
<#list list as firstMap>
<#assign productType="${firstMap.productType}"/>
<#if (firstMap.productList?size >0)>
<#list firstMap.productList as product>
${product.name}
<#if (productType?eval == 2)>
</#if>
</#list>
<#list firstMap.productList2 as product>
${product.price}
</#list>
</#if>
</#list>
</#if>
freemarker list嵌套map map再嵌套list list里面在嵌套一个map。list map 多重嵌套
<#list keyan as middleMap>
<#list middleMap?keys as itemKey>
<#assign keys=middleMap?keys/>
<#list keys as key>
key:${key}
<#if itemKey=="${key}">
<#list middleMap[itemKey] as cateMap>
数字:${cateMap.rid!}
</#list>
</#if>
</#list>
</#list>
</#list>
参考: https://blog.csdn.net/qq_34538575/article/details/79256195