123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121 |
- <div class="author-nav">
- <ul id="tree-tt">
- </ul>
- </div>
- <div class="author-nav-sidebar">隐藏菜单</div>
- <div class="bif-con">
-
- <div id="weaMonitorTabs" class="easyui-tabs" data-options="fit:true">
- <div title="熏蒸作业" style="padding-bottom:30px;" class="div-wrap-table">
- <!--#include file="/pages/intelligentControl/jobManage/fumigationJob.html"-->
- </div>
-
-
- <div title="通风作业" style="padding-bottom:30px;" class="div-wrap-table">
- <!--#include file="/pages/intelligentControl/jobManage/ventilationJob.html"-->
- </div>
- </div>
- </div>
- <style>
- .bif-nav-item {
- width: 97px;
- text-align: center;
- }
- .author-nav-sidebar {
- box-sizing: border-box;
- padding-top: 227px;
- float: left;
- height: 554px;
- line-height: 25px;
- width: 25px;
- cursor: pointer;
- text-align: center;
- /*writing-mode: vertical-rl;*/
- /*writing-mode:tb-rl;*/
- /* -webkit-transform:rotate(90deg);
- -moz-transform:rotate(90deg);
- -o-transform: rotate(90deg);*/
- /*white-space:nowrap;*/
- /*text-indent: 7px;*/
- margin-top: 10px;
- color: #fff;
- background-color: #ccc;
- }
- </style>
- <script>
- /*获取到链接首页的url*/
- $(function(){
- $.ajax({
- type: "post",
- dataType: 'json',
- url: config.baseUrl + "/sys/jump",
- success: function(e) {
- $('.nav-prov').attr('href','/'+e.defaultHome);
- },
- error: function(e) {
- console.log(e);
- }
- });
- });
- $(function() {
- base.getTree();
- base.listAllTypeRemote();
- $(document).on('click','[data-fun]',function( e ) {
- // console.log(e);
- //获取当前激活状态的函数名称
- var activeFunc = $('.bif-nav .active').data('fun'),
- //获取当前点击目标的函数名
- fun = $(this).data('fun');
- //比较其是否为同一目标,防止重复点击
- if (activeFunc === fun) {
- return false;
- }
- $(this).addClass('active').siblings().removeClass('active');
- if(typeof funs[fun] == 'function') {
- funs[fun]($(this),e);
- //删除多余的dom结构
- $('.panel,.window-shadow, .window-mask').remove();
- } else {
- console.info('not found function '+fun);
- }
- });
- // var showCount = 0,
- // hideCount = 0;
- //隐藏
- $('.author-nav-sidebar').on('click',function(e){
- e.preventDefault();
- var wid = $('.bif-con').css('width');
- // var li = $('.tabs-selected').index();
- if( wid !== '1172px' ) {
- $(this).text('显示菜单');
- $('.author-nav').hide();
- $('.bif-con').css('width','1172px');
- // if( showCount == 0 ) {
- // showCount++;
- $.parser.parse('.bif-con');
- //再次加载当前页面
- $('[data-fun].active').removeClass('active').trigger('click');
- } else {
- $(this).text('隐藏菜单');
- $('.author-nav').show();
- $('.bif-con').css('width','970px');
- // if( hideCount == 0 ) {
- // hideCount++;
- $.parser.parse('.bif-con');
- //再次加载当前页面
- $('[data-fun].active').removeClass('active').trigger('click');
- // }
- }
- })
- });
- </script>
- <script type="text/javascript" src="/src/intelligentControl/jobManage.js"></script>
- <script type="text/javascript">
- $(function() {
- intelligentControl.init();
- });
- </script>
|