Zhiqim Admin(简版的管理台)是从知启蒙管理台分离出来,保留系统参数表、系统菜单表、操作员、操作日志,去除组织、部门、角色等复杂权限功能,仅保留操作员独立权限功能。系统设计时保留ZmrSessionUser和ZmrOperator类,方便以后升级到知启蒙管理台。

森中灵 最后提交于2月前 修复cache显示错误,增加移动不带条件方法,增加操作日志不带说明方法
menu.zml5KB
${zhiqim_manager_breadcrumb("系统菜单")}
${zhiqim_manager_content()}

<#-- 显示子菜单,并递归显示下级子菜单 -->
<#function showChildMenu(self, parent)>
<table class="z-table z-bordered z-h30-tr zi-bd-t-none z-bg-white">
<tr class="z-pointer" ${zhiqim_manager_tr_onmouse()} ${zhiqim_manager_tr_click_radio()}>
    <td width="50" class="z-text-center">
    <#if ZmrAdminRule.check(request)>
        <input name="menuCode" type="radio" data-role="z-radio" data-class="${zmr_color_class}" value="${self.self().getMenuCode()}">
    </#if>
    </td>
    <td width="20%" class="zi-pd-l6">
    <#var level = self.self().getMenuLevel()/>
    <#for i : 1..(level-1)>
    <#if self.isLastNode(level-i)>
        <i class="z-ico z-tree z-30 z-normal z-blank"></i>
    <#else>
        <i class="z-ico z-tree z-30 z-normal z-vertline"></i>
    </#if>
    </#for>
    <#if self.hasChildren()>
        <a href="javascript:Zmr.treeExpand('${self.self().getMenuCode()}')"><i id="ico-${self.self().getMenuCode()}" class="z-ico z-tree z-30 z-normal <#if self.isLastNode()>z-mlastnode<#else>z-mnode</#if>"></i></a>
    <#else>
        <i class="z-ico z-tree z-30 z-normal <#if self.isLastNode()>z-lastnode<#else>z-node</#if>"></i>
    </#if>
        <i class="z-ico z-tree z-item z-mg-r3"></i>
        #{self.self().getMenuName()}
    </td>
    <td width="80" class="zi-pd-l6">#{self.self().getMenuNameAbbr()}</td>
    <td width="180" class="zi-pd-l6">#{self.self().getMenuCode()}</td>
    <td width="60" class="z-text-center"><#if self.self().getMenuStatus()==0>显示<#elseif self.self().getMenuStatus()==1><span class="z-text-blue">隐藏</span><#else><span class="z-text-gray">关闭</span></#if></td>
    <td width="60" class="z-text-center">#{self.self().getMenuLevel()}</td>
    <td width="80" class="z-text-center"><#if self.self().getMenuType()==1>枝节点<#else>属性</#if></td>
    <td width="60" class="z-text-center"><i class="z-font #{self.self().getMenuIcon()}"></i></td>
    <#if ZmrSuperAdminRule.check(request)>
    <td width="*" class="zi-pd-l6">#{self.self().getMenuUrl()}</td>
    </#if>
</tr>
</table>
<#if self.hasChildren()>
<div id="menu-${self.self().getMenuCode()}">
<#for child : self.children()>
${showChildMenu(child, self)}
</#for>
</div>
</#if>
</#function>

<#-- 导航 -->
<div class="z-tabnav-main z-mg-b20 ${zmr_color_class}">
<nav>
<ul class="z-mg-r10">
    <li class="z-active">系统菜单</li>
    ${zhiqim_manager_tabnav("系统配置", "/"+zhiqim_manager+"/config.htm", true)}
    ${zhiqim_manager_tabnav("系统缓存", "/"+zhiqim_manager+"/cache.htm", true)}
    ${zhiqim_manager_tabnav("系统参数", "/"+zhiqim_manager+"/param.htm", true)}
    ${zhiqim_manager_tabnav("首页主题", "/"+zhiqim_manager+"/themeIndex.htm", true)}
    ${zhiqim_manager_tabnav("主页主题", "/"+zhiqim_manager+"/themeMain.htm", true)}
    ${zhiqim_manager_tabnav("密钥对", "/"+zhiqim_manager+"/keys.htm", true)}
    ${zhiqim_manager_tabnav("进程信息", "/"+zhiqim_manager+"/process.htm", true)}
</ul>
<div class="z-float-right z-mg-t10 z-mg-r5">
<#if ZmrSuperAdminRule.check(request)>
<button class="z-button ${zmr_color_class}" onclick="Z.L.check('menuAdd.htm', 'menuCode');"><i class="z-font z-add"></i>增加菜单</button>
</#if>
<#if ZmrAdminRule.check(request)>
<button class="z-button ${zmr_color_class}" onclick="Z.L.check('menuModify.htm', 'menuCode');"><i class="z-font z-modify"></i>修改菜单</button>
</#if>
<#if ZmrSuperAdminRule.check(request)>
<button class="z-button z-red" onclick="Z.L.confirm('menuDelete.htm', '确定删除该菜单', 'menuCode', zCallFrame);"><i class="z-font z-delete"></i>删除菜单</button>
</#if>
</div>
</nav>
</div>

<#-- 列表 -->
<table class="z-table z-bordered z-h30-tr z-bg-white">
<tr class="zi-h40" bgcolor="${zmr_thead_bgcolor}">  
    <td width="50" class="z-text-center">选择</td>
    <td width="20%" class="zi-pd-l6">菜单目录</td>
    <td width="80" class="zi-pd-l6">菜单简称</td>
    <td width="180" class="zi-pd-l6">菜单编码</td>
    <td width="60" class="z-text-center">状态</td>
    <td width="60" class="z-text-center">级别</td>
    <td width="80" class="z-text-center">菜单类型</td>
    <td width="60" class="z-text-center">图标</td>
    <#if ZmrSuperAdminRule.check(request)>
    <td width="*" class="zi-pd-l6">URL</td>
    </#if>
</tr>
<tr class="z-pointer" ${zhiqim_manager_tr_onmouse()} ${zhiqim_manager_tr_click_radio()}>
    <td class="z-text-center">
    <#if ZmrSuperAdminRule.check(request)>
        <input name="menuCode" type="radio" data-role="z-radio" data-class="${zmr_color_class}" value="${tree.self().getMenuCode()}">
    </#if>
    </td>
    <td class="zi-pd-l6"><i class="z-ico z-tree z-30 z-normal z-root z-mg-r3"></i>系统功能根菜单</td>
    <td class="zi-pd-l6">#{tree.self().getMenuNameAbbr()}</td>
    <td class="zi-pd-l6">#{tree.self().getMenuCode()}</td>
    <td class="z-text-center"><#if tree.self().getMenuStatus()==0>显示<#elseif tree.self().getMenuStatus()==1><span class="z-text-blue">隐藏</span><#else><span class="z-text-gray">关闭</span></#if></td>
    <td class="z-text-center">#{tree.self().getMenuLevel()}</td>
    <td class="z-text-center">根节点</td>
    <td class="z-text-center"><i class="z-font #{tree.self().getMenuIcon()}"></i></td>
    <#if ZmrSuperAdminRule.check(request)>
    <td class="zi-pd-l6">#{tree.self().getMenuUrl()}</td>
    </#if>
</tr>
</table>
<#for child : tree.children()>
${showChildMenu(child, tree)}
</#for>
${zhiqim_manager_list(tree.size())}
${zhiqim_manager_content_end()}