Переглянути джерело

Merge remote-tracking branch 'origin/ChronicMag' into ChronicMag

zhouna 6 роки тому
батько
коміт
8fb1414590

BIN
src/common/images/chronic.png


BIN
src/common/images/close-icon.png


BIN
src/common/images/close-icon1.png


BIN
src/common/images/info-pic.png


BIN
src/common/images/info-pic1.png


BIN
src/common/images/级别1.png


BIN
src/common/images/级别2.png


BIN
src/common/images/级别3.png


BIN
src/common/images/级别4.png


BIN
src/common/images/级别5.png


Різницю між файлами не показано, бо вона завелика
+ 240 - 6
src/components/PushItems/index.jsx


+ 190 - 1
src/components/PushItems/index.less

@@ -176,7 +176,7 @@
   }
   .tips{
     border:1px solid #EAEDF1;
-    h1{
+    .tips-title,h1{
       font-size: 14px;
       color: #000;
       padding: 8px 15px;
@@ -188,6 +188,45 @@
         margin-right: 5px;
       }
     }
+    .tips-title{
+      .tips-name{
+        width: 255px;
+        display: inline-block;
+      }
+      h2{
+        display: inline-block;
+      }
+      .tips-btn{
+        display: inline-block;
+        float: right;
+      }
+      .redTips{
+        display: inline-block;
+        font-size: 12px;
+        -webkit-transform:scale(0.9);
+        color: red;
+        font-weight: normal;
+        white-space: nowrap;
+      }
+      .tipsDetails {
+        display: inline-block;
+        font-weight: normal;
+        width: 42px;
+        height: 20px;
+        border: 1px solid #262626;
+        border-radius: 4px;
+        text-align: center;
+        font-size: 12px;
+        // color: #3B9ED0;
+        color: #262626;
+        line-height: 18px;
+        margin: 0 0 -2px 10px;
+        cursor: pointer;
+      }
+    }
+    .chronic{
+      background: rgba(242,150,91,0.1);
+    }
     .content{
       font-size: 14px;
       padding:6px 15px;
@@ -229,6 +268,94 @@
         color: #979797;
         text-align: center;
       }
+      .list{
+        border-bottom: 1px solid #EAEDF1;
+        padding-bottom: 10px;
+        position: relative;
+        .infoPic{
+          vertical-align: middle;
+          margin: 0 5px;
+        }
+        >p{
+          margin-top: 10px;
+        }
+        .listName{
+          color:#3B9ED0;
+        }
+        .listResult{
+          float: right;
+          color: #000012;
+          i{
+            color: #F98F24;
+          }
+          img{
+            vertical-align: middle;
+          }
+        }
+        .infoBox{
+          position: absolute;
+          top:27px;
+          width: 388px;
+          background: #fff;
+          z-index: 66;
+          border: 1px solid #EAEDF1;
+          box-shadow: 0 5px 10px 0 rgba(0,0,0,0.10);
+          .infoTitle{
+            height: 40px;
+            line-height: 40px;
+            padding-left: 18px;
+            border-bottom: 1px solid #EAEDF1;
+            img{
+              vertical-align: middle;
+              float: right;
+            }
+          }
+          .infoCon{
+            padding: 15px 26px 25px;
+          }
+        }
+      }
+      .mainList{
+        .listBtn{
+          display: inline-block;
+          width: 96px;
+          height: 26px;
+          line-height: 26px;
+          text-align: center;
+          border: 1px solid #EAEDF1;
+          border-radius: 4px;
+        }
+        .listResult{
+          line-height: 26px;
+          i{
+            cursor: pointer;
+          }
+        }
+        .mainBox{
+          top: 65px;
+          .infoOption{
+            padding: 20px 0;
+          }
+          .infoConBtn{
+            text-align: right;
+            border-top: 1px solid #EAEDF1;
+            padding-top: 10px;
+            span{
+              color:#3B9ED0;
+              display: inline-block;
+              width: 66px;
+              height: 32px;
+              line-height: 32px;
+              text-align: center;
+              border: 1px solid #3B9ED0;
+              border-radius: 4px;
+            }
+          }
+        }
+      }
+      .list:last-child{
+        border-bottom:none;
+      }
     }
   }
   .modal {
@@ -353,3 +480,65 @@
   color: #979797;
   text-align: center;
 }
+
+.toast-title{
+  position: absolute;
+  top: 17px;
+  font-size: 16px;
+  // border-bottom: 1px solid #666;
+  width: 87%;
+  height: 25px;
+}
+.toast-cont{
+  line-height: 24px;
+  font-size: 14px;
+  // margin-top: 15px;
+  height: 222px;
+  overflow-y: auto;
+  border-top: 1px solid #979797;
+  padding: 10px 0 0 10px;
+  li{
+    margin-top: 10px;
+    cursor: pointer;
+  }
+}
+.tableBox{
+  // max-height: 700px;
+  height: 690px;
+  border-top: 1px solid #979797;
+  overflow-y: auto;
+  h1{
+    font-size: 16px;
+    font-weight: bold;
+    margin: 20px 0;
+    text-align: center;
+  }
+}
+.table{
+  width: 100%;
+  margin: 10px 0 10px;
+  tr{
+    border-bottom: 1px solid #979797;
+    td{
+      vertical-align: middle;
+      padding: 7px 0;
+    }
+  }
+}
+.tableBtn{
+    // position: absolute;
+    text-align: right;
+    color:#000;
+    padding: 15px 10px 0 0;
+    .confirmBtn{
+      display: inline-block;
+      color:#fff;
+      width: 80px;
+      height: 32px;
+      line-height: 32px;
+      border-radius: 4px;
+      background: #3B9ED0;
+      margin-left: 25px;
+      text-align: center;
+    }
+  }

+ 14 - 3
src/containers/PushItemsContainer.js

@@ -1,15 +1,19 @@
 import React from 'react';
 import {connect} from 'react-redux';
 import PushItems from '../components/PushItems'
-import {CHANGE_ASSAY, CHANGE_CHECK, ADD_BILLING, SHOW_TIPS_DETAILS, HIDE_TIPS_DETAILS} from '@store/types/pushMessage';
+import {CHANGE_ASSAY, CHANGE_CHECK, ADD_BILLING, SHOW_TIPS_DETAILS, HIDE_TIPS_DETAILS,SHOW_TABLE_LIST,HIDE_TABLE_LIST} from '@store/types/pushMessage';
 import { ADD_DIAGNOSTIC, GET_DIAGNOSTIC_STR } from '@store/types/diagnosticList';
-import {billing, getTips, getTipsDetails} from '../store/async-actions/pushMessage';
+import {billing, getTips, getTipsDetails,getTableList} from '../store/async-actions/pushMessage';
 import { isAddMainSuit } from '@store/async-actions/diagnosticList';
 
 function mapStateToProps(state) {
         return {
         pushMessage: state.pushMessage,
-        tipsDiscalimer:  state.copyRight.disContent
+        tipsDiscalimer:  state.copyRight.disContent,
+        chronicMagItem: state.diagnosticList.chronicMagItem,
+        questionId: state.diagnosticList.clickDiag,
+        tableList: state.pushMessage.tableList,
+        showList: state.pushMessage.showList,
     }
 }
 
@@ -55,6 +59,13 @@ function mapDispatchToProps(dispatch) {
             dispatch({
                 type: HIDE_TIPS_DETAILS
             })
+        },
+        getTableList(id){
+            dispatch(getTableList(id))
+            dispatch({type:SHOW_TABLE_LIST})
+        },
+        hideList(){
+            dispatch({type:HIDE_TABLE_LIST})
         }
     }
 }

+ 88 - 0
src/mock/chronicTable.js

@@ -0,0 +1,88 @@
+module.exports = {
+  data:{
+    "title":[
+        {
+            "name":"临床体格检查",
+            "column":"name"
+        },
+        {
+            "name":"临床症状",
+            "column":"detailName"
+        },
+        {
+            "name":"得分",
+            "column":"score"
+        },
+        {
+            "name":"推荐选项",
+            "column":""
+        }
+    ],
+    "result":[
+        {
+            "min":0,
+            "max":6,
+            "text":"无"
+        },
+        {
+            "min":7,
+            "max":12,
+            "text":"轻度"
+        },
+        {
+            "min":13,
+            "max":29,
+            "text":"中度"
+        },
+        {
+            "min":30,
+            "max":46,
+            "text":"重度"
+        }
+    ],
+    "details":[
+        {
+            "name":"右拇指振动觉",
+            "type":"1:radio,2:checkbox.....",
+            "details":[
+                {
+                    "detailName":"正常",
+                    "score":0,
+                    "state":"0:未选中,1-选中"
+                },
+                {
+                    "detailName":"减退",
+                    "score":1,
+                    "state":0
+                },
+                {
+                    "detailName":"消失",
+                    "score":2,
+                    "state":1
+                }
+            ]
+        },
+        {
+            "name":"左拇指振动觉",
+            "type":"1:radio,2:checkbox.....",
+            "details":[
+                {
+                    "detailName":"正常",
+                    "score":0,
+                    "state":"0:未选中,1-选中"
+                },
+                {
+                    "detailName":"减退",
+                    "score":1,
+                    "state":0
+                },
+                {
+                    "detailName":"消失",
+                    "score":2,
+                    "state":1
+                }
+            ]
+        }
+    ]
+  }
+}

+ 0 - 1
src/store/async-actions/homePage.js

@@ -104,7 +104,6 @@ export const getChronic = (dispatch,getState)=>{
  return json(api.getChronic,{}).then((res) => {
     const result = res.data;
     if (result.code == '0') {
-      console.log("请求成功",result);
       const chronic = JSON.stringify(result.data.chronic);
       storageLocal.set('chronic',chronic);
     }else{

+ 19 - 2
src/store/async-actions/pushMessage.js

@@ -1,12 +1,13 @@
 import { get, post, json } from "@utils/ajax";
-import { BILLING_ADVICE, SET_TIPS, SET_TIPS_DETAILS } from '../types/pushMessage';
+import { BILLING_ADVICE, SET_TIPS, SET_TIPS_DETAILS ,SET_CHRONIC_TABLELIST} from '../types/pushMessage';
 import { SET_CLICK_DIAG } from '../types/diagnosticList';
 import {storageLocal,getEMRParams} from '@utils/tools';
 import {SET_IMPORT_CHECKBODY_LABEL} from "../types/checkBody";
 
 const api={
   push:'/api/icss/push/pushInner',
-  textPush:'/api/icss/push/pushText'
+  textPush:'/api/icss/push/pushText',
+  getTableList:'/api/icss/scale/getList' //获取量表列表
 }
 
 //获取右侧推送信息
@@ -124,4 +125,20 @@ export const getTipsDetails = () => {
             console.log(e)
         })
     }
+}
+
+export const getTableList = (id)=>{
+    return (dispatch,getState)=>{
+        json(api.getTableList, {disId:id})
+        .then((res)=>{
+            if(res.data.code==0){
+                dispatch({
+                    type: SET_CHRONIC_TABLELIST,
+                    data: res.data.data
+                })
+            }
+        }).catch((e) => {
+            console.log(e)
+        })
+    }
 }

+ 14 - 3
src/store/reducers/pushMessage.js

@@ -1,4 +1,4 @@
-import {CHANGE_ASSAY, CHANGE_CHECK, BILLING_ADVICE, ADD_SCHEME, SET_TIPS,  SET_TIPS_DETAILS, SET_CHANGE_ADVICE_TREATMENT, SET_CHANGE_ADVICE_ASSAY, SET_CHANGE_ADVICE_CHECK, ADD_BILLING,CLEAR_ALL_PUSH_MESSAGE,SHOW_TIPS_DETAILS, HIDE_TIPS_DETAILS, SET_COMMONTREATMENT, IS_FIRST_MAIN_DIAG, SET_ADVICE_INPUT } from '../types/pushMessage';
+import {CHANGE_ASSAY, CHANGE_CHECK, BILLING_ADVICE, ADD_SCHEME, SET_TIPS,  SET_TIPS_DETAILS, SET_CHANGE_ADVICE_TREATMENT, SET_CHANGE_ADVICE_ASSAY, SET_CHANGE_ADVICE_CHECK, ADD_BILLING,CLEAR_ALL_PUSH_MESSAGE,SHOW_TIPS_DETAILS, HIDE_TIPS_DETAILS, SET_COMMONTREATMENT, IS_FIRST_MAIN_DIAG, SET_ADVICE_INPUT ,SET_CHRONIC_TABLELIST,SHOW_TABLE_LIST,HIDE_TABLE_LIST} from '../types/pushMessage';
 import {changeAssay, changeCheck, setAdvice, addScheme, setTips, setTipsDetails, setChangeAdviceTreatment, setChangeAdviceAssay, setChangeAdviceCheck, addBilling, clearAllPushMessage, showTipsDetails, hideTipsDetails, setCommontreatment, isFirstMainDiag, setAdviceInput } from '../actions/pushMessage';
 
 const initState = {
@@ -17,9 +17,11 @@ const initState = {
     // adviceStr: '' 
   },
   AdviceStr: '',
-  tmpFlg:''
+  tmpFlg:'',
+  tableList:[]
 };
 export default function(state = initState, action) {
+  let res = Object.assign({},state);
   switch (action.type) {
     case CHANGE_ASSAY:
       return changeAssay(state, action);
@@ -52,7 +54,16 @@ export default function(state = initState, action) {
     case IS_FIRST_MAIN_DIAG:
       return isFirstMainDiag(state, action);
     case SET_ADVICE_INPUT:
-      return setAdviceInput(state, action)
+      return setAdviceInput(state, action);
+    case SET_CHRONIC_TABLELIST://量表列表数据
+      res.tableList = action.data;
+      return res;
+    case SHOW_TABLE_LIST://显示量表列表数据
+      res.showList = true;
+      return res;
+    case HIDE_TABLE_LIST://隐藏量表列表数据
+      res.showList = false;
+      return res;
     default:
       return state;
   }

+ 6 - 3
src/store/types/pushMessage.js

@@ -6,14 +6,17 @@ export const ADD_CHECK = 'ADD_CHECK'; //添加辅检;
 export const ADD_SCHEME = 'ADD_SCHEME'; //添加治疗方案;
 export const SET_TIPS = 'SET_TIPS'; //设置提示信息;
 export const SET_TIPS_DETAILS = 'SET_TIPS_DETAILS'; //设置提示信息详情页内容;
-export const SET_CHANGE_ADVICE_TREATMENT = 'SET_CHANGE_ADVICE_TREATMENT'//改变医嘱的文字内容;
+export const SET_CHANGE_ADVICE_TREATMENT = 'SET_CHANGE_ADVICE_TREATMENT';//改变医嘱的文字内容;
 export const ADD_BILLING = 'ADD_BILLIND'; //添加开单项
 export const SET_CHANGE_ADVICE_ASSAY = 'SET_CHANGE_ADVICE_ASSAY';   //改变医嘱部分辅检的文字内容
 export const SET_CHANGE_ADVICE_CHECK = 'SET_CHANGE_ADVICE_CHECK';   //改变医嘱部分化验的文字内容
 export const CLEAR_ALL_PUSH_MESSAGE = 'CLEAR_ALL_PUSH_MESSAGE';   //清除所有推送信息
 export const SHOW_TIPS_DETAILS = 'SHOW_TIPS_DETAILS'; //显示提示详情页
 export const HIDE_TIPS_DETAILS = 'HIDE_TIPS_DETAILS'; //显示提示详情页
-export const SET_COMMONTREATMENT = 'SET_COMMONTREATMENT'    //设置常见治疗
-export const SET_ADVICE_INPUT = 'SET_ADVICE_INPUT'  //设置医嘱自由输入内容
+export const SET_COMMONTREATMENT = 'SET_COMMONTREATMENT';    //设置常见治疗
+export const SET_ADVICE_INPUT = 'SET_ADVICE_INPUT' ; //设置医嘱自由输入内容
+export const SET_CHRONIC_TABLELIST = 'SET_CHRONIC_TABLELIST' ; //设置量表列表
+export const SHOW_TABLE_LIST = 'SHOW_TABLE_LIST' ; //显示量表列表
+export const HIDE_TABLE_LIST = 'HIDE_TABLE_LIST' ; //隐藏量表列表