global.js 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. // JavaScript Document
  2. $('#myModal').on('shown.bs.modal', function () {
  3. $('#myInput').focus()
  4. });
  5. $('#myTabs a').click(function (e) {
  6. e.preventDefault()
  7. $(this).tab('show')
  8. });
  9. $(document).ready(function(){
  10. $(".subMenuContent").hide();
  11. $(".subMenuTitle a").click(function(){
  12. $(".subMenuTitle a").removeClass("bg");
  13. $(this).addClass("bg");
  14. $(this).parent().next().removeClass("menu-list");
  15. $(".menu-list").slideUp();
  16. $(this).parent().next().slideToggle();
  17. $(this).parent().next().addClass("menu-list");
  18. });
  19. $(".leftWrapper").hover(function(){
  20. timer = setTimeout(function(){
  21. $(".leftWrapper").stop().animate({width:"200px"},500);
  22. $(".mainWrapper").stop().animate({marginLeft:"215px",marginRight:"-200px"},500);
  23. $(".subMenuText").fadeIn(500);
  24. $(".logoInfo").show(500);
  25. },300);
  26. },function(){
  27. clearTimeout(timer);
  28. $(".leftWrapper").stop().animate({width:"60px"},500);
  29. $(".mainWrapper").stop().animate({marginLeft:"71px",marginRight:"15px",paddingRight:"0"},500);
  30. $(".subMenuText").fadeOut("fast");
  31. $(".logoInfo").hide();
  32. $(".subMenuContent").slideUp();
  33. });
  34. $(".logo").hover(function(){
  35. $(".logoList").show();
  36. },function(){
  37. $(".logoList").hide();
  38. })
  39. });