|
|
@@ -34,13 +34,16 @@ const PopContent = props => {
|
|
|
}
|
|
|
}
|
|
|
useEffect(() => {
|
|
|
- if (shouldUpdate) {
|
|
|
+ if (visible || shouldUpdate) {
|
|
|
initData()
|
|
|
}
|
|
|
- }, [shouldUpdate])
|
|
|
- useEffect(() => {
|
|
|
- visible && initData()
|
|
|
- }, [])
|
|
|
+ window.addEventListener('resize', () => {
|
|
|
+ setClientWidth(document.body.clientWidth * 0.7)
|
|
|
+ })
|
|
|
+ return () => {
|
|
|
+ window.removeEventListener('resize', () => {})
|
|
|
+ }
|
|
|
+ }, [visible, shouldUpdate])
|
|
|
return (
|
|
|
<Spin spinning={state.loading}>
|
|
|
<div className="sheet-box">
|
|
|
@@ -51,7 +54,7 @@ const PopContent = props => {
|
|
|
</div>
|
|
|
</Col>
|
|
|
<Col span={12}>
|
|
|
- <ContanctTabList />
|
|
|
+ <ContanctTabList clientId={state.client.id} />
|
|
|
<ContanctLowerList log={state.log} servicelist={state.serviceLog} />
|
|
|
</Col>
|
|
|
</Row>
|