Browse Source

主诉输入文字点击清除后再聚焦文字又出现的bug

liucf 6 years ago
parent
commit
beee05de43
1 changed files with 3 additions and 2 deletions
  1. 3 2
      src/components/MainSuit/index.jsx

+ 3 - 2
src/components/MainSuit/index.jsx

@@ -68,7 +68,8 @@ class MainSuit extends Component{
       if(!innerText.trim()){//有内容就走搜索接口
         getCommonSymptoms && getCommonSymptoms();
         this.setState({
-          symptom:true
+          symptom:true,
+          inpText:innerText
         })    
       }else{
         this.setState({
@@ -169,7 +170,7 @@ class MainSuit extends Component{
   handleChange(e){
     const ev = e || window.event;
     const data = ev.target.innerText;
-    const {getSearchData,searchData,datas,pushMessage,reTotalHide} = this.props;
+    const {getSearchData,searchData,datas,pushMessage,reTotalHide,saveText} = this.props;
     const {overFlag,inpText} = this.state;
     reTotalHide && reTotalHide();//重置homePage中的控制项
     const that = this;