header.html 6.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128
  1. <!-- Logo -->
  2. <a href="javascript:;" class="logo">
  3. <!-- 迷你模式下Logo的大小为50X50 -->
  4. <span class="logo-mini">{$site.name|mb_substr=0,4,'utf-8'|mb_strtoupper='utf-8'|htmlentities}</span>
  5. <!-- 普通模式下Logo -->
  6. <span class="logo-lg">{$site.name|htmlentities}</span>
  7. </a>
  8. <!-- 顶部通栏样式 -->
  9. <nav class="navbar navbar-static-top">
  10. <!--第一级菜单-->
  11. <div id="firstnav">
  12. <!-- 边栏切换按钮-->
  13. <a href="#" class="sidebar-toggle" data-toggle="offcanvas" role="button">
  14. <span class="sr-only">{:__('Toggle navigation')}</span>
  15. </a>
  16. <!--如果不想在顶部显示角标,则给ul加上disable-top-badge类即可-->
  17. <ul class="nav nav-tabs nav-addtabs disable-top-badge hidden-xs" role="tablist">
  18. {$navlist}
  19. </ul>
  20. <div class="navbar-custom-menu">
  21. <ul class="nav navbar-nav">
  22. <li class="hidden-xs">
  23. <a href="__PUBLIC__" target="_blank"><i class="fa fa-home" style="font-size:14px;"></i> {:__('Home')}</a>
  24. </li>
  25. <!-- 清除缓存 -->
  26. <li class="hidden-xs">
  27. <a href="javascript:;" data-toggle="dropdown" title="{:__('Wipe cache')}">
  28. <i class="fa fa-trash"></i> {:__('Wipe cache')}
  29. </a>
  30. <ul class="dropdown-menu wipecache">
  31. <li><a href="javascript:;" data-type="all"><i class="fa fa-trash fa-fw"></i> {:__('Wipe all cache')}</a></li>
  32. <li class="divider"></li>
  33. <li><a href="javascript:;" data-type="content"><i class="fa fa-file-text fa-fw"></i> {:__('Wipe content cache')}</a></li>
  34. <li><a href="javascript:;" data-type="template"><i class="fa fa-file-image-o fa-fw"></i> {:__('Wipe template cache')}</a></li>
  35. <li><a href="javascript:;" data-type="addons"><i class="fa fa-rocket fa-fw"></i> {:__('Wipe addons cache')}</a></li>
  36. <li><a href="javascript:;" data-type="browser"><i class="fa fa-chrome fa-fw"></i> {:__('Wipe browser cache')}
  37. <span data-toggle="tooltip" data-title="{:__('Wipe browser cache tips')}"><i class="fa fa-info-circle"></i></span>
  38. </a></li>
  39. </ul>
  40. </li>
  41. <!-- 多语言列表 -->
  42. {if $Think.config.lang_switch_on}
  43. <li class="hidden-xs">
  44. <a href="javascript:;" class="dropdown-toggle" data-toggle="dropdown"><i class="fa fa-language"></i></a>
  45. <ul class="dropdown-menu">
  46. <li class="{$config['language']=='zh-cn'?'active':''}">
  47. <a href="?ref=addtabs&lang=zh-cn">简体中文</a>
  48. </li>
  49. <li class="{$config['language']=='en'?'active':''}">
  50. <a href="?ref=addtabs&lang=en">English</a>
  51. </li>
  52. </ul>
  53. </li>
  54. {/if}
  55. <!-- 全屏按钮 -->
  56. <li class="hidden-xs">
  57. <a href="#" data-toggle="fullscreen"><i class="fa fa-arrows-alt"></i></a>
  58. </li>
  59. <!-- 账号信息下拉框 -->
  60. <li class="dropdown user user-menu">
  61. <a href="#" class="dropdown-toggle" data-toggle="dropdown">
  62. <img src="{$admin.avatar|cdnurl|htmlentities}" class="user-image" alt="">
  63. <span class="hidden-xs">{$admin.nickname|htmlentities}</span>
  64. </a>
  65. <ul class="dropdown-menu">
  66. <!-- User image -->
  67. <li class="user-header">
  68. <img src="{$admin.avatar|cdnurl|htmlentities}" class="img-circle" alt="">
  69. <p>
  70. {$admin.nickname|htmlentities}
  71. <small>{$admin.logintime|date="Y-m-d H:i:s",###}</small>
  72. </p>
  73. </li>
  74. <li class="user-body">
  75. <div class="visible-xs">
  76. <div class="pull-left">
  77. <a href="__PUBLIC__" target="_blank"><i class="fa fa-home" style="font-size:14px;"></i> {:__('Home')}</a>
  78. </div>
  79. <div class="pull-right">
  80. <a href="javascript:;" data-type="all" class="wipecache"><i class="fa fa-trash fa-fw"></i> {:__('Wipe all cache')}</a>
  81. </div>
  82. </div>
  83. </li>
  84. <!-- Menu Footer-->
  85. <li class="user-footer">
  86. <div class="pull-left">
  87. <a href="general/profile" class="btn btn-primary addtabsit"><i class="fa fa-user"></i>
  88. {:__('Profile')}</a>
  89. </div>
  90. <div class="pull-right">
  91. <a href="{:url('index/logout')}" class="btn btn-danger"><i class="fa fa-sign-out"></i>
  92. {:__('Logout')}</a>
  93. </div>
  94. </li>
  95. </ul>
  96. </li>
  97. <!-- 控制栏切换按钮 -->
  98. <li class="hidden-xs">
  99. <a href="javascript:;" data-toggle="control-sidebar"><i class="fa fa-gears"></i></a>
  100. </li>
  101. </ul>
  102. </div>
  103. </div>
  104. {if $Think.config.fastadmin.multiplenav}
  105. <!--第二级菜单,只有在multiplenav开启时才显示-->
  106. <div id="secondnav">
  107. <ul class="nav nav-tabs nav-addtabs disable-top-badge" role="tablist">
  108. {if $fixedmenu}
  109. <li role="presentation" id="tab_{$fixedmenu.id}" class="{:$referermenu?'':'active'}"><a href="#con_{$fixedmenu.id}" node-id="{$fixedmenu.id}" aria-controls="{$fixedmenu.id}" role="tab" data-toggle="tab"><i class="fa fa-dashboard fa-fw"></i> <span>{$fixedmenu.title}</span> <span class="pull-right-container"> </span></a></li>
  110. {/if}
  111. {if $referermenu}
  112. <li role="presentation" id="tab_{$referermenu.id}" class="active"><a href="#con_{$referermenu.id}" node-id="{$referermenu.id}" aria-controls="{$referermenu.id}" role="tab" data-toggle="tab"><i class="fa fa-list fa-fw"></i> <span>{$referermenu.title}</span> <span class="pull-right-container"> </span></a> <i class="close-tab fa fa-remove"></i></li>
  113. {/if}
  114. </ul>
  115. </div>
  116. {/if}
  117. </nav>