Pārlūkot izejas kodu

Z991239-4839 #comment feat: 修改关闭uos页面的逻辑

陈纪林80310970 2 gadi atpakaļ
vecāks
revīzija
68a255e06e

+ 3 - 3
Module/mod_healthmanager/mod_healthmanager.cpp

@@ -1958,15 +1958,14 @@ void CHealthManagerEntity::OnLog(const CAutoArray<CUUID>& SubIDs, const CUUID nL
 		m_dwTimeOfAuthSuc = GetTickCount64() / 1000;
 		GetFunction()->SetTimer(HEALTHMANAGER_WAIT_MAINPAGE_OPEN_TIMER_ID, this, m_maxWaitMainpageTime);
 
-		//信创暂不支持手动关闭弹窗,暂不进行告警
-		/*CSimpleStringA msg(true);
+		CSimpleStringA msg(true);
 		GetFunction()->GetSysVar("AuthErrMsg", msg);
 		Dbg("AuthErrMsg 在healthmanager的内容是: %s.", msg.GetData());
 
 		if (msg.GetLength() != 0)
 		{
 			StartManagerDesktopPage("warnPrompt.html");
-		}*/
+		}
 
 		break;
 	}	//oilyang@20210331 distinguish reasons of accessauth failed to decide what to do next
@@ -2185,6 +2184,7 @@ void CHealthManagerEntity::OnTimeout(DWORD dwTimeID)
 
 bool CHealthManagerEntity::StartManagerDesktopPage(CSimpleStringA pageName)
 {
+	Sleep(5000);
 	//升级重启弹窗提示
 	ChromiumSrv_ClientBase* chromiumClient = new ChromiumSrv_ClientBase(this);
 	ErrorCodeEnum error = chromiumClient->Connect();

+ 0 - 14
addin/res/ManagerDesktop/js/entityService.js

@@ -472,13 +472,11 @@ var AccessAuthService = {
     _methodID : {
         InitializeNew: 4,
         GetNetMsg: 6,
-        CloseTempWindow:7,
     },
             
     _methodSignature :{
         InitializeNew: 1851143282,
         GetNetMsg: 62776855,
-        CloseTempWindow: 1864857265
     },
     init:function(){
         //start session
@@ -514,18 +512,6 @@ var AccessAuthService = {
             callback(jsondata);
         });
     },
-    CloseTempWindow: function(req,callback){
-        req.entity = this._serviceBase.entityName;
-		req.class = this._serviceBase.className;
-		req.methodID = this._methodID.CloseTempWindow;
-        req.signature = this._methodSignature.CloseTempWindow;
-        console.log('CloseTempWindow startSession callback',req)
-
-		WebSocketBase.sendMsg(req, function(data) {
-            var jsondata = JSON.parse(data);
-            callback(jsondata);
-        });
-    },
 };
 
 //注册CenterSettingService

+ 1 - 15
addin/res/ManagerDesktop/js/getTerminalInfo.js

@@ -206,21 +206,7 @@ function chromiumClose(){
 		// req.messageType = 0;
 		// req.command = 'ChromiumClose';
 		// sendRequest(req); 
-	let req = new Request()
-	req.windowType = 1
-	let timeoutFn= setTimeout(function(){
-		let tips = '请求超时'
-		ModalPrompt(tips, 'pathN')
-	},60000)
-		
-	AccessAuthService.CloseTempWindow(req, function(ret) {
-		logEvent("CloseTempWindow ret: "+JSON.stringify(ret));
-		console.log("CloseTempWindow ret: "+JSON.stringify(ret));
-		if(ret){
-			clearTimeout(timeoutFn);
-		}
-		
-	})
+		open(location, '_self').close()
 }
 
 function sendRequest(request){