<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="courseclasstree.aspx.cs" Inherits="Us.Web.Extend.admin.extcourse.courseclasstree" %>



<!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>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /><meta http-equiv="X-UA-Compatible" content="IE=EmulateIE8,chrome=1" />
<title>班级课程选择</title>
<link href="../style/default/style.css" rel="stylesheet" type="text/css" />
<script language="javascript" src="/admin/js/System.js" type="text/javascript"></script>
<%--<link rel="StyleSheet" href="/admin/js/tree/dtree.css" type="text/css" />
<script type="text/javascript" src="/admin/js/tree/dtree.js"></script>--%>
 <script src="../js/jquery/jquery.js" type="text/javascript"></script>
 <%=ImportScriptStr %>
<link rel="stylesheet" href="../mtree/css/zTreeStyle/zTreeStyle.css" type="text/css">

<script type="text/javascript" src="../mtree/js/jquery.ztree.core-3.5.js"></script>
<script type="text/javascript" src="../mtree/js/jquery.ztree.excheck-3.5.js"></script>
<script type="text/javascript" src="../mtree/js/jquery.ztree.exedit-3.5.js"></script>

    <script type="text/javascript">
		<!--
    var setting = {

        view: {
            dblClickExpand: false,
            showLine: true,
            fontCss: getFontCss
        },
        data: {
            simpleData: {
                enable: true
            }
        },
        callback: {
            onClick: onClick,
            onRightClick: OnRightClick
        }
    };

   <% =TreeHTML %>

        function onClick(e, treeId, treeNode) {
            if (treeNode.id != "0") {
                var zTree = $.fn.zTree.getZTreeObj("treeDemo");
                //zTree.expandNode(treeNode);
                //OnRightClick(e, treeId, treeNode);
            }
        }

        var rMenu, zTree;
        function OnRightClick(e, treeId, treeNode) {
            if (!treeNode && event.target.tagName.toLowerCase() != "button" && $(event.target).parents("a").length == 0) {
                zTree.cancelSelectedNode();
                //showRMenu("root", event.clientX, event.clientY);
            } else if (treeNode && !treeNode.noR) {
                zTree.selectNode(treeNode);
                //showRMenu("node", event.clientX, event.clientY);
            }
        }
        $(document).ready(function () {
            $.fn.zTree.init($("#treeDemo"), setting, zNodes);
            zTree = $.fn.zTree.getZTreeObj("treeDemo");
            rMenu = $("#rMenu");
            ztreeinitsearch("treeDemo", "txtUserName");
            //$("#callbackTrigger").bind("change", {}, setTrigger);
        });



        function showRMenu(type, x, y) {
           
            
        }
        function hideRMenu() {
           
        }
        function onBodyMouseDown(event) {
           
        }

        var addCount = 1;
       

        function listTreeNode() {
            hideRMenu();
            //rightGoURL("/admin/extexam/extbookinfolist.aspx?TypeID=" + zTree.getSelectedNodes()[0].id + "&TypeName=" + zTree.getSelectedNodes()[0].name);
        }
        function checkTreeNode(checked) {
            var nodes = zTree.getSelectedNodes();
            if (nodes && nodes.length > 0) {
                zTree.checkNode(nodes[0], checked, true);
            }
            hideRMenu();
        }
        function resetTree() {
            hideRMenu();
            $.fn.zTree.init($("#treeDemo"), setting, zNodes);
        }

        function rightGoURL(url) {
            //$("#iframe1").attr("src", url);
            CareffArtOpenB2(url);
        }

        //-->
	</script>

    <style type="text/css">
.ztree li span.button.switch.level0 {visibility:hidden; width:1px;}
.ztree li ul.level0 {padding:0; background:none;}
	</style>

 <script language="javascript" type="text/javascript" >
     function AutoHeight() {
         var h = $(window).height() - 110;
         $("#ScroLeft").height(h);
         $("#iframe1").height($(window).height() - 20);
     }
     $(window).resize(function () {
         AutoHeight();
     });

     $(document).ready(function () {
         AutoHeight();
     });
</script>

   
<style type="text/css">
div#rMenu {position:absolute; visibility:hidden; top:0;text-align: left;
padding:1px;
margin:0px;
background-color: #fff;
border: 1px solid #999;
width:120px;
}

div#rMenu ul li{
	color:#000;
	display:block;
	cursor: default;
	padding:3px;
	border: 1px solid #fff;
	background-color: transparent;
	
}
div#rMenu ul li a:hover{
	border: 1px solid #0a246a;
	background-color: #b6bdd2;
}
img{ padding-right:5px; vertical-align:middle; width:16px; height:16px;}
#rMenu li.h_nav_over{border: 1px solid #0a246a;	background-color: #b6bdd2;} 
#rMenu li.h_nav_over a{color:#fff;} 

	</style>
<script type="text/javascript">
    $(function () {
        $("#rMenu>ul>li").mouseover(function () {
            $("#rMenu>ul>li").each(function (i) {
                $(this).removeClass("h_nav_over");
            });
            $(this).addClass("h_nav_over");
        }).mouseout(function () {
            $(this).addClass("h_nav_over");
        });
    });
</script> 


</head>
<body>
<form id="Form1" method="post" runat="server">
  <table width="100%" border="0" cellpadding="0" cellspacing="0" height="100%">
    <tr>
      <td width="220" valign="top"><div class="divTbg">
          <div class="divTbgL"></div>
          <div class="divTbgInfo">
            <div class="divTbgTitle">班级课程选择</div>
          </div>
        </div>
        <div class="divTbgF"></div>
        <div class="divSearchBoth">
         <div class="divInfo careffdivheight" align="center">
                            点击班级名操作
                        </div>
            <div class="divInfo">

                            <div class="divSearch">
                                <div id="searchBox" class="clearsearch">
                                    <p>
                                        &nbsp;<input type="text" id="txtUserName" placeholder="搜索的班级名称" />
                                    </p>
                                </div>
                            </div>


                        </div>

          <div class="divInfo">
            <div class="divAutoHeight" id="ScroLeft">
                <ul id="treeDemo" class="ztree"></ul>
                </div>
            
            
          </div>
        </div></td>
      <td valign="top" height="100%">       
            
        <iframe id="iframe1" src="<%=sOneURL %>" width="100%" height="100%" id="frameright" name="frameright" frameborder="0"
                    scrolling="auto"></iframe></td>
    </tr>
  </table>

    <div id="rMenu">
	<ul>
		
	</ul>
</div>
</form>
</body>
</html>

