|
@@ -1,5 +1,5 @@
|
|
|
import {post,json} from '@utils/ajax.js';
|
|
|
-import {SETINITDATA} from '@store/types/homePage.js';
|
|
|
+import {SETINITDATA,MODI_LOADING} from '@store/types/homePage.js';
|
|
|
import {SET_CURRENT} from '@store/types/currentIll';
|
|
|
import {SET_MAINSUIT} from '@store/types/mainSuit';
|
|
|
import config from '@config/index.js';
|
|
@@ -27,7 +27,8 @@ function modulesParseJson(data){
|
|
|
export const getInitModules= (dispatch,getStore)=>{
|
|
|
const state = getStore();
|
|
|
const {message} = state.patInfo;
|
|
|
- return json(api.getModules,{age:message.patientAge,sexType:message.sex}).then((res) => {
|
|
|
+ return json(api.getModules,{age:message.patientAge,sexType:message.sex}).then((res) => {console.log("模板请求成功",res);
|
|
|
+ dispatch({type:MODI_LOADING});
|
|
|
if (res.data.code == '0') {
|
|
|
const newObj = modulesParseJson(res.data.data);
|
|
|
const initData = newObj.json;
|
|
@@ -73,7 +74,7 @@ export const initHis = (dispatch)=> {
|
|
|
dispatch(initHistoryDetails(baseDate.patInfo.message));
|
|
|
clearInterval(timer)
|
|
|
}
|
|
|
- },500)
|
|
|
+ },200)
|
|
|
}
|
|
|
|
|
|
// 埋点事件,点击保存时调用
|