From c4eacd7552781c58bdca11581d5a45a58e00799f Mon Sep 17 00:00:00 2001 From: "sylor_huang@126.com" Date: Mon, 22 Jun 2020 17:32:43 +0800 Subject: [PATCH 1/2] change --- src/AppConfig.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/AppConfig.js b/src/AppConfig.js index e0799627..81e5439c 100644 --- a/src/AppConfig.js +++ b/src/AppConfig.js @@ -100,7 +100,7 @@ export function initAxiosInterceptors(props) { // TODO 读取到package.json中的配置? var proxy = "http://localhost:3000" // proxy = "https://pre-newweb.educoder.net" - proxy = "https://testforgeplus.trustie.net/" + // proxy = "https://testforgeplus.trustie.net/" // 在这里使用requestMap控制,避免用户通过双击等操作发出重复的请求; From 7ba94ee0941980a0b87ac6914db90a5fb71c4477 Mon Sep 17 00:00:00 2001 From: "sylor_huang@126.com" Date: Mon, 22 Jun 2020 17:49:11 +0800 Subject: [PATCH 2/2] change header --- src/AppConfig.js | 2 +- src/modules/tpm/NewHeader.js | 8 ++++++++ 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/src/AppConfig.js b/src/AppConfig.js index 79caf0d7..12abacae 100644 --- a/src/AppConfig.js +++ b/src/AppConfig.js @@ -100,7 +100,7 @@ export function initAxiosInterceptors(props) { // TODO 读取到package.json中的配置? var proxy = "http://localhost:3000" // proxy = "https://pre-newweb.educoder.net" - // proxy = "https://testforgeplus.trustie.net/" + proxy = "https://testforgeplus.trustie.net/" // 在这里使用requestMap控制,避免用户通过双击等操作发出重复的请求; diff --git a/src/modules/tpm/NewHeader.js b/src/modules/tpm/NewHeader.js index 074b2b6c..1c290730 100644 --- a/src/modules/tpm/NewHeader.js +++ b/src/modules/tpm/NewHeader.js @@ -617,6 +617,8 @@ class NewHeader extends Component { return true } else if (url.startsWith('/statistics') && match.path.startsWith('/statistics')) { return true + } else if (url.startsWith('/users') && match.path.startsWith('/users')) { + return true } else { return false } @@ -812,6 +814,12 @@ class NewHeader extends Component { ) }) } + { + this.props.current_user && this.props.current_user.login && +
  • this.headtypesonClick(`/users/${this.props.current_user.login}`, true)} className={`${this.matchpaths(`/users/${this.props.current_user.login}`) === true ? 'pr active' : 'pr'}`} style={true ? { display: 'flex' } : { display: 'none' }}> + 项目 +
  • + } : ""