From d058bf152b75f51dee20b5a12a30ad3a7060d74d Mon Sep 17 00:00:00 2001 From: tangjiang <465264938@qq.com> Date: Mon, 30 Dec 2019 19:36:26 +0800 Subject: [PATCH] add --- public/react/src/AppConfig.js | 14 -------------- .../developer/components/knowledge/index.js | 7 ++++++- 2 files changed, 6 insertions(+), 15 deletions(-) diff --git a/public/react/src/AppConfig.js b/public/react/src/AppConfig.js index 055f6ae92..ba700794e 100644 --- a/public/react/src/AppConfig.js +++ b/public/react/src/AppConfig.js @@ -86,17 +86,6 @@ export function initAxiosInterceptors(props) { // 如果需要支持重复的请求,考虑config里面自定义一个allowRepeat参考来控制 const requestMap = {}; -<<<<<<< HEAD - window.railsgettimes = function(proxy) { - // $.ajax({url:`${proxy}/api/main/first_stamp.json`,async:false,success:function(data,status){ - // if(data.status===0){ - // return data.message; - // } - // }}); - } - -======= ->>>>>>> dev_aliyun window.setfalseInRequestMap = function(keyName) { requestMap[keyName] = false; } @@ -131,12 +120,9 @@ export function initAxiosInterceptors(props) { if(`${config[0]}`!=`true`){ let timestamp = Date.parse(new Date())/1000; if (window.location.port === "3007") { -<<<<<<< HEAD // let timestamp=railsgettimes(proxy); console.log(timestamp) -======= railsgettimes(`${proxy}/api/main/first_stamp.json`); ->>>>>>> dev_aliyun let newopens=md5(opens+timestamp) config.url = `${proxy}${url}`; if (config.url.indexOf('?') == -1) { diff --git a/public/react/src/modules/developer/components/knowledge/index.js b/public/react/src/modules/developer/components/knowledge/index.js index 5677d3630..491b9cb87 100644 --- a/public/react/src/modules/developer/components/knowledge/index.js +++ b/public/react/src/modules/developer/components/knowledge/index.js @@ -35,7 +35,12 @@ function KnowLedge (props) { } const handleSelectChange = (value) => { console.log('过滤结果Start=====》》》》》', selectOptions, value); - const _result = selectOptions.filter(item => item !== value.join('')); + const _result = selectOptions.filter(item => { + if (item === value) { + + } + return item !== value; + }); console.log('过滤结果=====》》》》》', _result, selectOptions); setSelectOptions(_result); }