From 7f953d9aa0e7d4fcbe3c366c7f9f0b3f847f12bd Mon Sep 17 00:00:00 2001 From: hdw <hdw@192.168.137.1> Date: 星期六, 19 一月 2019 09:16:08 +0800 Subject: [PATCH] Merge branch 'dev_lxw' of https://gitlab.com/whyclxw1/gx_tieta.git into dev_lxw --- gx_tieta/WebRoot/mobil/index.html | 81 ++++++++++++++++++++++++++++++++++++---- 1 files changed, 72 insertions(+), 9 deletions(-) diff --git a/gx_tieta/WebRoot/mobil/index.html b/gx_tieta/WebRoot/mobil/index.html index dbb34c6..212df11 100644 --- a/gx_tieta/WebRoot/mobil/index.html +++ b/gx_tieta/WebRoot/mobil/index.html @@ -1,3 +1,4 @@ + <!doctype html> <html> <head> @@ -22,7 +23,7 @@ <a href="machineroomM.html" target="_top" data-i18n="main.index">娴嬭瘯鏁版嵁</a> </li> <li> - <a href="testControl.html" target="_top" data-i18n="main.warningmanagement">鐢垫睜瀹夎鐢宠</a> + <a href="ele-param2.html" target="_top" data-i18n="main.warningmanagement">bts瀹夎鐢宠</a> </li> <li> <a href="auditDetail.html" target="_top" data-i18n="main.warningmanagement">瀹℃壒璇︽儏</a> @@ -43,12 +44,15 @@ <li> <a href="indexctM.html" target="_top" data-i18n="main.usermanagement">浣滀笟绠$悊</a> </li> - <li> - <a href="home-info.html" target="_top" data-i18n="main.usermanagement">鏈烘埧瀹氫綅</a> + <!-- <li> + <a href="map.html" target="_top" id="LocationCR" data-i18n="main.usermanagement">鏈烘埧瀹氫綅</a> + </li> --> + <li> + <a href="checkAccept-index.html" id="check_Accept" target="_top" data-i18n="main.usermanagement">bts瀹夎瀹℃壒鍜岄獙鏀�</a> </li> - <li> + <!-- <li> <a href="batt-home-info.html" target="_top" data-i18n="main.usermanagement">鏈烘埧淇℃伅</a> - </li> + </li> --> </ul> </div> @@ -58,25 +62,46 @@ <script type="text/javascript" src="mobilJs/base.js"></script> <script> - $(document).bind("mobileinit", function(){ - - + $(document).bind("mobileinit", function(){ // enable i18n $.mobile.i18nEnabled = false; //$.mobile.i18nFolder = "i18n" $.mobile.ignoreContentEnabled = true; - // $(document).delegate("#btn", "vclick", function(){ // alert( $.trim( $("#tpl").html() ) ); // }); + /*cleanCookie("wapproval"); + cleanCookie("happroval"); + cleanCookie("batt"); + cleanCookie("station"); */ }); $(function(){ + var user = getCookie("user"); + var user_logo = getCookie("user_logo"); + //user = JSON.parse(user); + console.info(user); + console.info(user_logo); + judgeOpen(); delCookie("pages"); delCookie("stationId"); + delCookie("wapproval"); + delCookie("happroval"); + delCookie("batt"); + delCookie("station"); + delCookie("eleparm"); + delCookie("eleparm1"); + delCookie("happroval"); $(document.body).css( "visibility", "visible") ; }); + + //鎷︽埅瀹夊崜鍥為��鎸夐挳 + history.pushState(null, null, location.href); + window.addEventListener('popstate', function(event) { + history.pushState(null, null, location.href ); + //姝ゅ鍔犲叆鍥為��鏃朵綘瑕佹墽琛岀殑浠g爜 + }); //瀹夊叏閫�鍑� function exitUser(){ @@ -85,6 +110,44 @@ window.location.replace("loginm.html"); }); } + function judgeOpen(){ + $.ajax({ + type: 'post', + async: false, + url: 'User_permitgroup_dataAction!FromSessiongetPermits', + data: null, + dataType: 'json', + success:function(data) { + data = JSON.parse(data.result); + data = JSON.parse(data); + console.info(data); + if(isHasPermit("install_look_permit",data)){ + }else{ + document.getElementById("check_Accept").style.display="none"; + document.getElementById("LocationCR").style.display="none"; + } + } + }); + } + + //鏍规嵁鏉冮檺鍚嶅垽鏂槸鍚﹀叿鏈夋煇涓潈闄� + function isHasPermit(_permitName,_permitList) + { + //console.info(_permitList); + var _isHasPermit=false; + //閬嶅巻_permitList鏍规嵁_permitName鎵惧埌璇ユ潈闄愭槸鍚﹀叿鏈� + for(var i=0;i<_permitList.length;i++) + { + //console.info(_permitList[i].permit_item_name); + //console.info(_permitList[i].permit_item_value); + if(_permitList[i].permit_item_name == _permitName && _permitList[i].permit_item_value == 1) + { + _isHasPermit = true; + return _isHasPermit; + } + } + return _isHasPermit; + } </script> </div> -- Gitblit v1.9.1