123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180 |
- <%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
- <%@page import="com.ccgj.platform.util.GlobalDefine"%>
- <%@page import="com.opensymphony.xwork2.ActionContext"%>
- <%@ page import="com.ccgj.database.beans.YHB"%>
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
- <html xmlns="http://www.w3.org/1999/xhtml">
- <head>
- <title>管理员---导航主页</title>
- <link href="../ligerui/lib/ligerUI/skins/Aqua/css/ligerui-all.css"
- rel="stylesheet" type="text/css" />
- <link href="css/all.css" rel="stylesheet" type="text/css" />
- <!-- ztree-css -->
- <link href="css/css/zTreeStyle/zTreeStyle.css" rel="stylesheet" type="text/css" />
- <script src="../ligerui/lib/jquery/jquery-1.5.2.min.js"
- type="text/javascript"></script>
- <!-- ztree-js -->
- <script src="js/jquery.ztree.core-3.5.js" type="text/javascript"></script>
- <script src="../ligerui/lib/ligerUI/js/ligerui.min.js"
- type="text/javascript"></script>
- <script src="../ligerui/indexdata.js" type="text/javascript"></script>
- <script src="../manage/js/json2.js" type="text/javascript"></script>
- <script type="text/javascript">
- var tab = null;
- var accordion = null;
- var tree = null;
- $(function() {
- //布局
- $("#layout1").ligerLayout( {
- leftWidth : 190,
- height : '100%',
- heightDiff : -34,
- space : 4,
- onHeightChanged : f_heightChanged
- });
- var height = $(".l-layout-center").height();
- //Tab
- $("#framecenter").ligerTab( {
- height : height
- });
- //面板
- $("#accordion1").ligerAccordion( {
- height : height - 24,
- speed : null
- });
- $(".l-link").hover(function() {
- $(this).addClass("l-link-over");
- }, function() {
- $(this).removeClass("l-link-over");
- });
-
- var setting = {
- view: {
- //dblClickExpand: false,
- expandSpeed: 100 //设置树展开的动画速度
- },
- //获取json数据
- async : {
- enable : true,
- url : "columns!init?extendFlag=false", // Ajax 获取数据的 URL 地址
- autoParam : [ "id", "name" ] //ajax提交的时候,传的是id值
- },
- data:{ // 必须使用data
- simpleData : {
- enable : true,
- idKey : "id", // id编号命名
- pIdKey : "pid", // 父id编号命名
- rootPId : 0
- }
- },
- // 回调函数
- //?????treeId
- callback : {
- onClick : function(event, treeId, treeNode, clickFlag) {
- if (!treeNode.jump){
- return;
- }
- if(true) {
- f_addTab(treeNode.id, treeNode.name, treeNode.jump);
- return;
- }
- },
- //捕获异步加载出现异常错误的事件回调函数 和 成功的回调函数
- onAsyncSuccess : function(event, treeId, treeNode, msg){
- }
- }
- };
-
- // 过滤函数
- function filter(treeId, parentNode, childNodes) {
- if (!childNodes)
- return null;
- for ( var i = 0, l = childNodes.length; i < l; i++) {
- childNodes[i].name = childNodes[i].name.replace(/\.n/g, '.');
- }
- return childNodes;
- }
-
- //
- $(document).ready(function() {
- $.fn.zTree.init($("#tree1"), setting );
- });
- tab = $("#framecenter").ligerGetTabManager();
- accordion = $("#accordion1").ligerGetAccordionManager();
- //tree = $("#tree1").ligerGetTreeManager();
- $("#pageloading").hide();
- });
- function f_heightChanged(options) {
- if (tab)
- tab.addHeight(options.diff);
- if (accordion && options.middleHeight - 24 > 0)
- accordion.setHeight(options.middleHeight - 24);
- }
- function f_addTab(tabid, text, url) {
- tab.addTabItem( {
- tabid : tabid,
- text : text,
- url : url
- });
- }
- function exit(){
- $.ajax({
- type:"post",
- url:'manage/login!exit',
- dataType:'json',
- success: function(success){
- if(success.msg == "1"){
- window.location.href = "login.jsp";
- }
- }
- });
- }
- </script>
- <%
- String id="";
- String name="";
- if(ActionContext.getContext().getSession().get(GlobalDefine.USER) != null){
- YHB yhbBean = (YHB) ActionContext.getContext().getSession().get(GlobalDefine.USER);
- id = yhbBean.getId().toString();
- name = yhbBean.getYhmc().toString().trim();
- }else{
- out.print("<script>alert('操作延时,请重新登陆!');parent.window.location.href='login.jsp'</script>");
- return;
- }
-
- %>
- </head>
- <body style="padding: 0px; background: #EAEEF5;">
- <div id="pageloading"></div>
- <div id="topmenu" class="l-topmenu">
- <div class="l-topmenu-logo">
- 管理员
- </div>
- <div class="l-topmenu-welcome">
- <a href="../main/80/index.html" class="l-link2" target="_blank">首页</a>
- <span class="space">|</span>
- <a href="javascript:f_addTab('superAdmin','个人中心','manageAdmin/manageAdmin!init?yhsx=3&id=<%=id%>')">个人中心</a>
- <span class="space">|</span>
- <a href="" class="l-link2" onclick="exit()">退出</a>
- </div>
- </div>
- <div id="layout1"
- style="width: 99.2%; margin: 0 auto; margin-top: 4px;">
- <div position="left" title="功能菜单" id="accordion1" style="overflow:auto;width:100%" >
- <ul id="tree1" style="margin-top: 3px;" class="ztree"></ul>
- <ul id="tree2" style="margin-top: 3px;"></ul>
- </div>
- <div position="center" id="framecenter">
- <div tabid="home" title="我的主页" style="height: 300px">
- <iframe frameborder="0" name="home" id="home" src="welcome.jsp"></iframe>
- </div>
- </div>
- </div>
- <div style="height: 32px; line-height: 32px; text-align: center;">
- <iframe frameborder="0" name="foot" id="foot" src="foot.jsp" width="400px" height="32px" scrolling="no"></iframe>
- </div>
- <div style="display: none"></div>
- </body>
- </html>
|