Browse Source

联系人表单列表高度自定义

outaozhen 5 years atrás
parent
commit
5dbc823652

+ 7 - 3
src/components/PopContent/Contacts/index.jsx

@@ -10,9 +10,9 @@ import consts from '@/consts'
 
 const Popcontent = props => {
   const { visible, onClose,collapsed, id = '' } = props
-  const needSubtractHeight = 48 + 48 + 48 + 64 + 24 // 需要被裁掉的高度
+  const needSubtractHeight = 55 // 需要被裁掉的高度
   // const needSubtractWidth = (collapsed ? 208 : 48) + 48 + 48 + 48 // 需要被裁掉的高度
-  const [y] = useAutoTable(collapsed, needSubtractHeight)
+  const [x,y] = useAutoTable(collapsed, needSubtractHeight)
   console.log(y)
 
 
@@ -49,6 +49,10 @@ const Popcontent = props => {
         <Drawer
           title="联系人"
           placement="right"
+          bodyStyle={{
+            height:y,
+            overflowY:'hidden'
+          }}
           width={clientWidth}
           closable
           onClose={onClose}
@@ -56,7 +60,7 @@ const Popcontent = props => {
           // mask={false}
         >
           <Row>
-            <Col span={12} className="sheet-box-left">
+            <Col span={12} className="sheet-box-left" style={{ height:y-25,overflowY:'auto' }}>
               <div className="sheet-left-panel zh-pd-right-15">
                 <ContanctForm client={state.client} />
               </div>

+ 0 - 2
src/components/PopContent/index.scss

@@ -3,9 +3,7 @@
   overflow: hidden;
 }
 .sheet-left-panel {
-  height: 834px;
   overflow-x: hidden;
-  overflow-y: auto;
 }
 .sheet-right-panel {
   height: 340px;