// JavaScript Document $('#myModal').on('shown.bs.modal', function () { $('#myInput').focus() }); $('#myTabs a').click(function (e) { e.preventDefault() $(this).tab('show') }); $(document).ready(function(){ $(".subMenuContent").hide(); $(".subMenuTitle a").click(function(){ $(".subMenuTitle a").removeClass("sidebg"); $(this).addClass("sidebg"); $(this).parent().next().removeClass("menu-list"); $(".menu-list").slideUp(); $(this).parent().next().slideToggle(); $(this).parent().next().addClass("menu-list"); }); $(".leftWrapper").hover(function(){ timer = setTimeout(function(){ $(".leftWrapper").stop().animate({width:"200px"},500); $(".mainWrapper").stop().animate({marginLeft:"215px",marginRight:"-200px"},500); $(".subMenuText").fadeIn(500); $(".logoInfo").show(500); },300); },function(){ clearTimeout(timer); $(".leftWrapper").stop().animate({width:"56px"},500); $(".mainWrapper").stop().animate({marginLeft:"61px",marginRight:"15px",paddingRight:"0"},500); $(".subMenuText").fadeOut("fast"); $(".logoInfo").hide(); $(".subMenuContent").slideUp(); }); $(".logo").hover(function(){ $(".logoList").show(); },function(){ $(".logoList").hide(); }); $(".tablelist").tablesorter({widthFixed: true}); // $(".dropdown-toggleSF").click(function(){ // $(this).next().toggle(); // }); // $(document).bind("click",function(e){ // var target = $(e.target); // if(target.closest(".dropdown-toggleSF,.dropdown-list li").length == 0){/*.closest()沿 DOM 树向上遍历,直到找到已应用选择器的一个匹配为止,返回包含零个或一个元素的 jQuery 对象。*/ // $(".dropdown-list").hide(); // }; // e.stopPropagation(); // }); });