From 05ded946624a39e54e95f7bda2da8384c216766d Mon Sep 17 00:00:00 2001 From: caishi <1149225589@qq.com> Date: Tue, 5 Jan 2021 14:27:35 +0800 Subject: [PATCH] save --- src/AppConfig.js | 9 ++++----- src/forge/Settings/Index.js | 16 ++++++++-------- 2 files changed, 12 insertions(+), 13 deletions(-) diff --git a/src/AppConfig.js b/src/AppConfig.js index a212448fb..1aaa23714 100644 --- a/src/AppConfig.js +++ b/src/AppConfig.js @@ -4,10 +4,10 @@ import { broadcastChannelOnmessage, isDev, queryString } from 'educoder'; import { notification } from 'antd'; import cookie from 'react-cookies'; import './index.css'; -let message501 = false; +let message501 = false; broadcastChannelOnmessage('refreshPage', () => { - window.location.reload() + window.location.reload(); }) function locationurl(list) { @@ -27,7 +27,7 @@ if (isDev) { } debugType = window.location.search.indexOf('debug=t') !== -1 ? 'teacher' : window.location.search.indexOf('debug=s') !== -1 ? 'student' : - window.location.search.indexOf('debug=a') !== -1 ? 'admin' : parsed.debug || 'student' + window.location.search.indexOf('debug=a') !== -1 ? 'admin' : parsed.debug || 'admin' } function clearAllCookie() { cookie.remove('_educoder_session', { path: '/' }); @@ -54,8 +54,7 @@ setpostcookie(); window._debugType = debugType; export function initAxiosInterceptors(props) { - initOnlineOfflineListener() - // TODO 避免重复的请求 https://github.com/axios/axios#cancellation + initOnlineOfflineListener(); var proxy = "http://localhost:3000"; proxy = "https://testforgeplus.trustie.net"; diff --git a/src/forge/Settings/Index.js b/src/forge/Settings/Index.js index 4a22b3d35..1e294b35d 100644 --- a/src/forge/Settings/Index.js +++ b/src/forge/Settings/Index.js @@ -43,8 +43,8 @@ class Index extends Component { const flag = pathname === `/projects/${owner}/${projectsId}/setting`; return ( -
@@ -101,9 +101,9 @@ class Index extends Component {