zhangxc 6 年 前
コミット
686eebe970

+ 1 - 1
src/components/CopyRight/index.less

@@ -2,7 +2,7 @@
   position: absolute;
   bottom: 0px;      //页面布局
   z-index: 40;
-  width: 418px;
+  width: 450px;
   .disTips{
     padding: 10px 20px 0px 20px;
     font-size: 10px;

+ 22 - 0
src/components/Treat/LastTreat/index.jsx

@@ -0,0 +1,22 @@
+import React, { Component } from 'react';
+import style from './index.less';
+
+class LastTreat extends Component {
+    constructor(props){
+        super(props);
+    }
+
+    render() {
+        const { icon, titleStyle,titleBg, filter, title, lasttreatTreat } = this.props
+        return(
+            lasttreatTreat.content && lasttreatTreat.content.length > 0 && <div className={style['last-treat-wrapper']}>
+                <div className={style['last-treat-title-box']} style={titleStyle}></div>
+                <div className={style['last-treat-title']} ><img className={style['last-treat-icon']} src={icon}/>{title}</div>
+                
+            </div>
+        )
+    }
+
+}
+
+export default LastTreat;

+ 25 - 0
src/components/Treat/LastTreat/index.less

@@ -0,0 +1,25 @@
+.last-treat-wrapper {
+    position: relative;
+    padding: 10px 0 0 0;
+}
+.last-treat-title-box {
+    height: 36px;
+    line-height: 36px;
+    background: rgb(47,199,156);
+    opacity: 0.1;
+    filter:alpha(opacity=10);
+    -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(opacity=10);";
+}
+.last-treat-title {
+    position: absolute;
+    width: 100%;
+    top: 10px;
+    height: 36px;
+    line-height: 36px;
+    font-weight: bold;
+}
+.last-treat-icon {
+    width: 16px;
+    float: left;
+    margin: 10px;
+}

+ 1 - 0
src/components/Treat/index.jsx

@@ -2,6 +2,7 @@ import React,{ Component } from 'react';
 import style from './index.less';
 import GeneralTreat from './GeneralTreat/index.jsx';
 import DrugTreat from './DrugTreat/index.jsx';
+import LastTreat from './LastTreat/index.jsx';
 import TreatDesc from '@components/TreatDesc'
 import {dragBox,windowRemoveEventHandler} from '@utils/tools'
 import DrugInfo from '@components/TreatDesc/DrugInfo';

+ 22 - 0
src/store/reducers/treat.js

@@ -68,6 +68,28 @@ const initState = {
     //         ]
     //     }
     // ],
+    lastTreat: {
+        commonDisMedica: [
+            {
+                name: '泮托拉唑',
+                id: 145
+            },
+            {
+                name: '奥美拉唑',
+                id: 341
+            }
+        ],
+        chronicDisMedica: [
+            {
+                name: '兰索拉唑',
+                id: 342
+            },
+            {
+                name: '山莨菪碱',
+                id: 344
+            }
+        ],
+    },
     treatDesc:{
         title: '药品推荐',
     }