diff --git a/pc4mobx/hrmSalary/pages/variableSalary/components/salaryFileList/index.js b/pc4mobx/hrmSalary/pages/variableSalary/components/salaryFileList/index.js
index f3b0e52a..d68ae568 100644
--- a/pc4mobx/hrmSalary/pages/variableSalary/components/salaryFileList/index.js
+++ b/pc4mobx/hrmSalary/pages/variableSalary/components/salaryFileList/index.js
@@ -31,7 +31,6 @@ class Index extends Component {
componentDidMount() {
window.addEventListener("message", this.handleReceive, false);
window.addEventListener("resize", this.handleResize, false);
- this.getVariableSalaryList();
}
componentWillUnmount() {
@@ -40,9 +39,12 @@ class Index extends Component {
}
componentWillReceiveProps(nextProps, nextContext) {
+ if (nextProps.taxAgentIds !== this.props.taxAgentIds && nextProps.taxAgentIds) {
+ this.getVariableSalaryList(nextProps);
+ }
if (nextProps.isQuery !== this.props.isQuery) this.setState({
pageInfo: { ...this.state.pageInfo, current: 1 }
- }, () => this.getVariableSalaryList());
+ }, () => this.getVariableSalaryList(nextProps));
}
handleReceive = async ({ data }) => {
@@ -67,8 +69,8 @@ class Index extends Component {
}
}
};
- getVariableSalaryList = () => {
- const { baseTableStore: { VSalryForm, getVariableSalaryList }, salaryMonth, taxAgentIds } = this.props;
+ getVariableSalaryList = (props) => {
+ const { baseTableStore: { VSalryForm, getVariableSalaryList }, salaryMonth, taxAgentIds } = props || this.props;
const { pageInfo } = this.state;
const { departmentIds } = VSalryForm.getFormParams();
this.setState({ loading: true });
diff --git a/pc4mobx/hrmSalary/pages/variableSalary/index.js b/pc4mobx/hrmSalary/pages/variableSalary/index.js
index 115aa93e..6401465d 100644
--- a/pc4mobx/hrmSalary/pages/variableSalary/index.js
+++ b/pc4mobx/hrmSalary/pages/variableSalary/index.js
@@ -109,15 +109,15 @@ class Index extends Component {
,
this.setState({ salaryMonth: val }, () => this.handleAdvanceSearch())}/>,
- this.setState({ taxAgentIds: val }, () => this.handleAdvanceSearch())}/>,
+ this.setState({ taxAgentIds: val })}/>,
this.openAdvanceSearch()}
onAdvanceSearch={this.handleAdvanceSearch}/>
] : [
this.setState({ salaryMonth: val }, () => this.handleAdvanceSearch())}/>,
- this.setState({ taxAgentIds: val }, () => this.handleAdvanceSearch())}/>,
+ this.setState({ taxAgentIds: val })}/>,
this.openAdvanceSearch()}
onAdvanceSearch={this.handleAdvanceSearch}/>
],
diff --git a/pc4mobx/hrmSalary/pages/variableSalary/index.less b/pc4mobx/hrmSalary/pages/variableSalary/index.less
index b76440d6..ac609fbd 100644
--- a/pc4mobx/hrmSalary/pages/variableSalary/index.less
+++ b/pc4mobx/hrmSalary/pages/variableSalary/index.less
@@ -1,6 +1,15 @@
.variable_salary_wrapper {
.wea-new-top-req-title > div:last-child {
right: 16px !important;
+
+ .ant-calendar-range-picker {
+ min-width: 100px !important;
+ width: 100px;
+ }
+
+ .wea-input-focus {
+ width: 140px;
+ }
}
.wea-new-top-req-content {