Bläddra i källkod

急诊科历史病历1931/1926/1924

liucf 5 år sedan
förälder
incheckning
da608d5569

+ 5 - 2
src/components/Banner/index.jsx

@@ -10,7 +10,7 @@ import {Notify} from '@commonComp';
 // import Emergency from '@components/Emergency';
 import Emergency from '@containers/Emergency';
 import {getAllHis} from '@store/async-actions/fetchModules.js';
-import {timestampToTime} from '@utils/tools.js';
+import {timestampToTime,getCurrentDate} from '@utils/tools.js';
 import {dragBox} from '@utils/drag';
 import {CLEAR_COMSYMPTOMS} from '@store/types/mainSuit';
 
@@ -75,8 +75,11 @@ class Banner extends Component {
   }*/
   showHisModal(){
     const {getAllRecord} = this.props;
+    // 进入时默认展示当天的病例
     const item = {
-      current:1
+      current:1,
+      startDate:getCurrentDate(false)+' 00:00:00',
+      endDate:getCurrentDate(false)+' 23:59:59'
     }
     getAllRecord&&getAllRecord(item);
     this.setState({

+ 4 - 2
src/components/Emergency/HisList/index.jsx

@@ -58,18 +58,20 @@ class HisList extends Component {
     handleFilter&&handleFilter(obj);
   }
   handleFilter(flag){
-    const {handleFilter} = this.props;
+    const {handleFilter,detail} = this.props;
     const {hasSecond} = this.state;
     if(flag == hasSecond){return}
     this.setState({
       hasSecond:flag,
       all:false,
-      select:[]
+      select:[],
+      index:0
     })
     const obj = {
       flag:flag
     }
     handleFilter&&handleFilter(obj);
+    detail&&detail(0);
   }
 
   handleGetMore(){

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

@@ -142,7 +142,7 @@ class EmergencyHis extends Component{
     let baseObj = data[index];
     let dataJson,dataStr;
     if(baseObj){
-        dataJson = JSON.stringify(baseObj) == "{}" ? {} : JSON.parse(baseObj.dataJson);
+        // dataJson = JSON.stringify(baseObj) == "{}" ? {} : JSON.parse(baseObj.dataJson);
         dataStr = JSON.stringify(baseObj) == "{}" ? [] : baseObj.detailList;
     }
     const getAllDataStringList = () =>{           //获取所有模块文本的数据

+ 3 - 2
src/store/async-actions/fetchModules.js

@@ -340,12 +340,13 @@ export function getAllHis(item){
     const {params} = state.emergencyHis;
     let param = {};
     if(JSON.stringify(params) == '{}'){
-      param = {
+      /*param = {
         "current": item.current,
         "hospitalDeptId": message.hospitalDeptId,
         "hospitalId": message.hospitalId,
         "size": 6,
-      }
+      }*/
+      param = Object.assign({},item,{hospitalDeptId:message.hospitalDeptId,hospitalId:message.hospitalId,size:6})
     }else{
       param = Object.assign({},params,{current:item.current})
     }

+ 2 - 2
src/utils/config.js

@@ -1,8 +1,8 @@
 // const host='http://192.168.3.1:5050';//赵
 // const host='http://192.168.3.100:5050';//王峰
-// const host='http://192.168.2.241:5050';//后端接口访问地址
+const host='http://192.168.2.236:5050';//后端接口访问地址
 // const host='http://192.168.2.121:5050';//后端接口访问地址
-const host='http://192.168.2.241:5050';//后端接口访问地址
+// const host='http://192.168.2.241:5050';//后端接口访问地址
 // const host='http://192.168.3.11:5050';//王宇
 //const host='http://192.168.2.164:8080';
 // const host='http://192.168.3.117:5050'; //周铁刚