From b09b821ef36fd1ea979e9a5daa98e95732ac81d5 Mon Sep 17 00:00:00 2001
From: king <18310653075@163.com>
Date: 星期三, 16 七月 2025 18:16:00 +0800
Subject: [PATCH] 2025-07-16

---
 src/views/mkiframe/index.jsx |   39 +++++++++++++++++++++++++++++----------
 1 files changed, 29 insertions(+), 10 deletions(-)

diff --git a/src/views/mkiframe/index.jsx b/src/views/mkiframe/index.jsx
index b6e9761..cfd57df 100644
--- a/src/views/mkiframe/index.jsx
+++ b/src/views/mkiframe/index.jsx
@@ -1,6 +1,5 @@
 import React, {Component} from 'react'
-import { Spin, notification, ConfigProvider } from 'antd'
-import zhCN from 'antd/es/locale/zh_CN'
+import { Spin, notification } from 'antd'
 
 import Api from '@/api'
 import asyncComponent from '@/utils/asyncLoadComponent'
@@ -76,6 +75,7 @@
             } else {
               sessionStorage.clear()
               this.props.history.replace('/login')
+              window.location.reload()
             }
           })
         }
@@ -103,6 +103,7 @@
           sessionStorage.clear()
           sessionStorage.setItem('iframe', `/iframe/${menuId}/@loginuid@/${bid || ''}`)
           this.props.history.replace('/login')
+          window.location.reload()
         }
       })
     }
@@ -123,10 +124,22 @@
         configurable: true,
         enumerable: true,
         set(value) {
-          if (value + '' === 'false') {
-            window.GLOB.debugger = false
-          } else {
+          if (value === true) {
             window.GLOB.debugger = true
+          } else if (value === 0) {
+            if (window.backend) {
+              sessionStorage.setItem('systemRun', 'front')
+              window.location.reload()
+            } else {
+              window.mkInfo('绯荤粺褰撳墠鏈娇鐢ㄥ悗绔剼鏈紒')
+            }
+          } else if (value === false) {
+            if (sessionStorage.getItem('systemRun') === 'front') {
+              sessionStorage.removeItem('systemRun')
+              window.location.reload()
+            } else {
+              window.GLOB.debugger = false
+            }
           }
         }
       })
@@ -164,6 +177,14 @@
 
   reloadTabs = () => {
     if (this.reloading) return
+
+    let time = new Date().getTime()
+
+    let oldTime = sessionStorage.getItem('mk_reloadTabs')
+    
+    if (oldTime && time - oldTime < 180000) return
+
+    sessionStorage.setItem('mk_reloadTabs', time)
 
     this.reloading = true
 
@@ -267,11 +288,9 @@
 
     return (
       <div className="main-iframe">
-        <ConfigProvider locale={zhCN}>
-          {loading ? <Spin size="large" /> : null}
-          {!loading && type === 'CustomPage' ? <CustomPage MenuID={MenuId} param={{$BID: BID}} changeTemp={this.changeTemp}/> : null}
-          {!loading && type === 'BaseTable' ? <BaseTable MenuID={MenuId} param={{$BID: BID}} changeTemp={this.changeTemp}/> : null}
-        </ConfigProvider>
+        {loading ? <Spin size="large" /> : null}
+        {!loading && type === 'CustomPage' ? <CustomPage MenuID={MenuId} param={{$BID: BID}} changeTemp={this.changeTemp}/> : null}
+        {!loading && type === 'BaseTable' ? <BaseTable MenuID={MenuId} param={{$BID: BID}} changeTemp={this.changeTemp}/> : null}
         <ImgScale />
       </div>
     )

--
Gitblit v1.8.0