zhouna 3 лет назад
Родитель
Сommit
44b158ad6b
1 измененных файлов с 4 добавлено и 3 удалено
  1. 4 3
      src/js/utils.js

+ 4 - 3
src/js/utils.js

@@ -237,7 +237,8 @@ const post = function (url, data, opts) {
 function unloginPop(msg){
   /*const isOut = code === '10020011' || code === '10020012' || code === '10020013';
   if(isOut){*/
-    if(self != top&&parent&&parent.location.href.indexOf("qcScore.html")===-1){//子窗口并且不是病例列表
+  const isQcScore = parent&&parent.location.href.indexOf("qcScore.html")===-1;
+    if(self != top&&isQcScore){//子窗口并且不是病例列表
 	  const dialogmessage = {
 		iframemessage: 1,
 		data: msg
@@ -247,9 +248,9 @@ function unloginPop(msg){
     }else{
 	  console.log('父窗口')
 	  //失效后不点知道了直接刷新处理:跳回登录页
-      /*if(localStorage.getItem('toLogin')==='1'){
+      if(localStorage.getItem('toLogin')==='1'){
 		(parent||window).location.href='login.html';
-      }*/
+      }
 	  $.alerModal({
 		gobackBtn: true,
 		title: "提示",