Browse Source

接口返回参数修改

luolei 4 years ago
parent
commit
34430d316a

+ 1 - 1
src/components/DiagnosticList/index.jsx

@@ -303,7 +303,7 @@ class DiagnosticList extends Component {
                                        onMouseLeave = {this.handleMouseLeaveDrug.bind(this)}
                                     >
                                       <span title={item.name} className={style['diag-name-box']} style={{'max-width': '300px'}}>
-                                        {item.name}ss
+                                        {item.name}
                                       </span>
                                       {/* <img className={`${style['info-img']}`}
                                           title='点击i图标可查看详细说明'

+ 9 - 7
src/store/async-actions/diagnosticSearch.js

@@ -41,13 +41,15 @@ export const getSearchList = (val,flag) => {
                 const data = res.data.data;let curDate=[];
 
                 let arr = data.diseaseNames||[];
-                    for (var key in arr) {
-                        let obj = {}
-                        obj['name'] = arr[key];
-                        obj['uniqueName'] = arr[key];
-                        obj['conceptId'] = '';
-                        curDate.push(obj)
-                    }
+                for(let i = 0;i < arr.length;i++){
+                    let tmp = arr[i]
+                    let obj = {}
+                    obj['name'] = tmp.name;
+                    obj['uniqueName'] = tmp.name;
+                    obj['conceptId'] = '';
+                    obj['icd10Code'] = tmp.icd10Code;
+                    curDate.push(obj)
+                }
                 if(flag){ 
                     dispatch({
                         type: GET_SEARCH,