<#macro templateList filepath=''> <@tools.fileList path=filepath> <#list list as a> <#if !a.directory><@t.merge 'paths' filepath?has_content?then(filepath+'/','')+a.fileName/> <@sys.lock userId=admin.id itemType='template' itemIds=t.paths><#assign lockMap=map!/> <#if lockMap?has_content> <#list lockMap as k,lock> <#if lock.userId?has_content><@t.merge 'userIds' lock.userId/> <@sys.user ids=t.userIds><#assign userMap=map!/> <#list list as a> <#local currentPath=filepath?has_content?then(filepath+'/','')+a.fileName> <#if (path?has_content && path?starts_with(currentPath+'/'))> class="expand"<#else> _src="cmsTemplate/list.html?parent=${currentPath?url}"<#elseif path?has_content && path=currentPath> class="selected"> <@tools.metadata path=currentPath> <#if !a.directory && lockMap?has_content && lockMap[currentPath]?has_content> <#assign lockUser=(userMap[lockMap[currentPath].userId?string].nickname)!''/> ${(object.alias)?has_content?then(object.alias+' ('+a.fileName+')',a.fileName)} <#if a.directory && path?has_content && path?starts_with(currentPath+'/')> <#else>
  • <@t.page 'empty_directory'/>
  • <#if parent?has_content> <#else>
    <#if path?has_content> <#if editType?has_content&&'metadata'=editType> <#include "metadata.html"/> <#else> <#include "content.html"/> <#else> <#include "directory.html"/>