瀏覽代碼

弹窗样式修改

zhouna 6 年之前
父節點
當前提交
9dcbe5e06c

+ 3 - 3
src/common/components/ComplexModal/index.jsx

@@ -19,13 +19,13 @@ class ComplexModal extends Component {
     super(props)
   }
   render() {
-    const { onclose,title,children,footer,shadeClose,icon,width,height} = this.props;
+    const { onclose,title,children,footer,shadeClose,icon,width,top,bottom} = this.props;
     const marginLeft = width? -parseInt(width)/2 : '';
-    const marginTop = height? -parseInt(height)/2: '';
+    //const marginTop = height? -parseInt(height)/2: '';
     const domNode = document.getElementById('root');
     return ReactDom.createPortal(<div className={style['container']}>
       <div className={style['shade']} onClick={shadeClose===false?'':onclose}></div>
-      <div className={style['modal']} style = {{width: width?width:'auto', marginLeft:marginLeft, height:height?height:'auto', marginTop:marginTop}}>
+      <div className={style['modal']} style = {{width: width?width:'auto', marginLeft:marginLeft, top:top?top+'px':'',bottom:bottom?bottom+'px':''}}>
         <div className={style['close']}>
           {icon?<img src={icon} />:''}
           {title}

+ 5 - 5
src/common/components/ComplexModal/index.less

@@ -4,8 +4,8 @@
   .content{
     overflow: auto;
     position: fixed;
-    // bottom: 130px;
-    // top: 110px;
+    bottom: 130px;
+    top: 110px;
     // width: 820px;
   }
   .footer{
@@ -30,10 +30,10 @@
     background: #fff;
     position: fixed;
     left: 50%;
-    top: 50%;
+    //top: 50%;
     // margin-left: -410px;
-    // top: 65px;
-    // bottom: 65px;
+    top: 65px;
+    bottom: 65px;
   }
   .close {
     padding:  15px 15px 15px 20px;

+ 4 - 4
src/components/ChronicInfo/index.jsx

@@ -193,15 +193,15 @@ class ChronicInfo extends React.Component{
         </ComplexModal>:''}
         {showTable?<ComplexModal onclose={this.closeTable} footer={footer}
                       title='密西根糖尿病神经筛查表(MDNS)' 
-                      icon={tableIcon} 
-                      height={800}
+                      icon={tableIcon}
                       width={820}>
           <ScaleTable></ScaleTable>
         </ComplexModal>:''}
         {showAssess?<ComplexModal onclose={this.showAssessFn} footer={footer}
                       title='管理和评估' 
-                      icon={manageIcon} 
-                      height={800}
+                      icon={manageIcon}
+                      top={20}
+                      bottom={20}
                       width={820}>
           <AssessResult></AssessResult>
         </ComplexModal>:''}

+ 3 - 22
src/components/PushItems/index.jsx

@@ -7,8 +7,6 @@ import tipsImg from "../../common/images/tips.png";
 import vigilantImg from "../../common/images/vigilant.png";
 import showImg from "../../common/images/show.png";
 import hideImg from "../../common/images/close.png";
-import printIcon from '@common/images/team.png';
-import DetailsModal from './DetailsModal';
 import PushDiag from "./PushDiag";
 import DiagnosticItem from "@containers/DiagnosticItem";
 import store from "@store";
@@ -16,8 +14,7 @@ import { getWindowInnerHeight } from "@common/js/func";
 import {addLabel} from '@store/actions/inspect';
 import {addAssistLabel} from '@store/actions/assistCheck';
 import {windowEventHandler} from '@utils/tools'
-import {ConfirmModal,ComplexModal} from '@commonComp';
-import AssessResult from '../AssessResult';
+import {ConfirmModal} from '@commonComp';
 import ChronicInfo from '@containers/ChronicInfo';//慢病推送模块
 
 class PushItems extends Component {
@@ -161,23 +158,16 @@ class PushItems extends Component {
       assay,
       check,
       tips,
-      showTipsDetails,
-      tipsDetails,
       tmpFlg,
     } = this.props.pushMessage;
-    const footer = <div className={style['footer']}>
-      <span className={style['print']}><img src={printIcon} alt=""/>打印</span>
-      <span className={style['okBtn']}>确定</span>
-    </div>;
-    const { tipsDiscalimer,tableList ,showList,chronicMagItem} = this.props;
-    const { moreAssay, moreCheck ,show,showAssess} = this.state;
+    const { tipsDiscalimer} = this.props;
+    const { moreAssay, moreCheck ,show} = this.state;
     const {
       showMore,
       closeMore,
       billing,
       changeCheck,
       changeAssay,
-      showAdd,
       showTips
     } = this;
     let assayNum = 0;
@@ -483,15 +473,6 @@ class PushItems extends Component {
             </div>
           </div>
         </div>
-        {tipsDiscalimer.data && <div className={style['disTips']} dangerouslySetInnerHTML={{__html: tipsDiscalimer.data.data[1]&&tipsDiscalimer.data.data[1].description}}></div>}
-        {showTipsDetails && <DetailsModal  
-            showTipsDetails = {showTipsDetails}
-            hideTips = {this.hideTips}
-            tipsDetails = {tipsDetails}/>}
-        {showAssess?<ComplexModal onclose={this.showAssessFn} footer={footer}
-                                  title='管理和评估'>
-          <AssessResult></AssessResult>
-        </ComplexModal>:''}
       </div>
     );
   }