<#if isRoot> [{ "text": "<@s.m "cmsDepartment.top"/>", "classes": "" <#if list?size gt 0>, "expanded": true, "children": [ <#list list as depart> { "id": "${depart.id}", "text": "${depart.name} ", "classes": "<#if depart.child?size gt 0><#else>", "hasChildren": <#if depart.child?size gt 0>true<#else>false }<#if depart_has_next>, ] }] <#else> [ <#list list as depart> { "id": "${depart.id}", "text": "${depart.name}", "classes": "<#if depart.child?size gt 0><#else>", "hasChildren": <#if depart.child?size gt 0>true<#else>false }<#if depart_has_next>, ]