<@_contentSourceList name=name 
            userId=userId 
            orderType=orderType pageIndex=pageNum pageSize=numPerPage>
<div class="pageHeader card">
    <form class="pagerForm" autocomplete="off" onsubmit="return navTabSearch(this);" method="post">
        <#include "../include_page/parameters.html"/>
        <div class="searchBar">
            <ul class="searchContent">
                <li>
                    <label><@t.page 'name'/>:</label>
                    <input type="text" name="name" value="${name!}"/>
                </li>
                <li>
                    <label><@t.page 'user'/>:</label>
                    <#include "../include_page/userId.html"/>
                </li>
            </ul>
            <div class="subBar">
                <ul>
                    <li>
                        <button type="submit" class="buttonActive"><@t.page 'button.search'/></button>
                    </li>
                </ul>
            </div>
        </div>
    </form>
</div>
<@_sysAuthorized roleIds=admin.roles urls='cmsContentSource/add,cmsContentSource/delete'><#assign authorizedMap=map/></@_sysAuthorized>
<div class="pageContent card">
    <div class="panelBar">
        <ul class="toolBar">
        <#if authorizedMap['cmsContentSource/add']>
            <li><a href="cmsContentSource/add.html" target="navTab" rel="cmsContentSource/add"><i class="icon-plus-sign-alt icon-large"></i> <@t.page 'button.add'/></a></li>
        </#if>
        <#if authorizedMap['cmsContentSource/delete']>
            <li><a href="cmsContentSource/delete?_csrf=<@_csrfToken admin=true/>" title="<@t.page 'confirm.batch_delete'/>" target="selectedTodo" rel="ids"><i class="icon-trash icon-large"></i> <@t.page 'button.batch_delete'/></a></li>
        </#if>
        </ul>
    </div>
    <table class="table" width="100%" layoutH orderField="" orderType="">
        <thead>
            <tr>
                <th width="20"><input type="checkbox" group="ids" class="checkboxCtrl"></th>
                <th><@t.page 'name'/></th>
                <th><@t.page 'url'/></th>
                <th><@t.page 'initial'/></th>
                <th><@t.page 'user'/></th>
                <th orderField="createDate"><@t.page 'create_date'/></th>
                <th><@t.page 'operate'/></th>
            </tr>
        </thead>
        <tbody>
            <#list page.list as a>
                <@t.merge 'userIds' a.userId!/>
            </#list>

            <@sys.user ids=t.userIds!><#assign userMap=map!/></@sys.user>

            <#list page.list as a>
            <tr target="sid" rel="${a.id}">
                <td class="center"><input name="ids" value="${a.id}" type="checkbox"></td>
                <td class="exclude-translate">${a.name!}</td>
                <td>${a.url!}</td>
                <td class="exclude-translate">${a.initial!}</td>
                <td class="exclude-translate">${(userMap[a.userId?string].nickname)!}</td>
                <td>${a.createDate!}</td>
                <td>
                <#if authorizedMap['cmsContentSource/add']>
                    <a href="cmsContentSource/add.html?id=${a.id}" class="edit btnText blue" target="navTab" rel="cmsContentSource/edit"><i class="icon-edit"></i> <@t.page 'button.edit'/></a>
                </#if>
                <#if authorizedMap['cmsContentSource/delete']>
                    <a href="cmsContentSource/delete?ids=${a.id}&_csrf=<@_csrfToken admin=true/>" class="btnText warn" title="<@t.page 'confirm.delete'/>"  target="ajaxTodo"><i class="icon-trash"></i> <@t.page 'button.delete'/></a>
                </#if>
                </td>
            </tr>
            </#list>
        </tbody>
    </table>
    <#include "../include_page/page.html"/>
</div>
</@_contentSourceList>