福利台账-重新核算后调差页面需要刷新才能删除

This commit is contained in:
黎永顺 2022-12-06 15:44:29 +08:00
parent 499fe647a2
commit 2d78222cf5
2 changed files with 5 additions and 11 deletions

View File

@ -32,12 +32,11 @@ class AdjustTable extends Component {
};
}
componentDidMount() {
this.getCompensationList().then(r => {
});
}
componentWillReceiveProps(nextProps, nextContext) {
if (nextProps.visible !== this.props.visible) {
nextProps.visible && this.getCompensationList().then(r => {
});
}
}
getCompensationList = async () => {

View File

@ -28,11 +28,6 @@ class AdjustmentSlide extends Component {
this.adjustTableRef = null;
}
componentWillReceiveProps(nextProps, nextContext) {
if (nextProps.visible !== this.props.visible) {
}
}
handleSave = () => {
let { dataSource, targetOptions } = this.adjustTableRef.state;
dataSource = _.filter(dataSource, it => !it.id);
@ -106,7 +101,7 @@ class AdjustmentSlide extends Component {
customOperate={this.renderCustomOperate()}
/>
}
content={<AdjustTable ref={dom => this.adjustTableRef = dom}/>}
content={<AdjustTable ref={dom => this.adjustTableRef = dom} visible={visible}/>}
onClose={onCancel}
/>
);