diff --git a/pc4mobx/hrmSalary/pages/payrollFiles/components/importMenu.js b/pc4mobx/hrmSalary/pages/payrollFiles/components/importMenu.js index 04103886..5e9e6ae0 100644 --- a/pc4mobx/hrmSalary/pages/payrollFiles/components/importMenu.js +++ b/pc4mobx/hrmSalary/pages/payrollFiles/components/importMenu.js @@ -21,7 +21,12 @@ class ImportMenu extends Component { } salaryArchivePreview = (params) => { - params.importType = this.state.importParams.importType; + if (this.state.importParams.importType === "init" || this.state.importParams.importType === "salaryItemAdjust") { + params.importType = this.state.importParams.importType; + params.listType = "FIXED"; + } else { + params.listType = this.state.importParams.importType; + } API.salaryArchivePreview(params).then(({ status, data }) => { if (status) { const { headers, list } = data; @@ -77,16 +82,21 @@ class ImportMenu extends Component { handleInitModal = () => { // 清空列表数据 this.setState({ - previewDataSource:[], + previewDataSource: [], importParams: { ...this.state.importParams, - importResult:{}, + importResult: {} } }); }; // 导入档案 handleImportFile = (params) => { - params.importType = this.state.importParams.importType; + if (this.state.importParams.importType === "init" || this.state.importParams.importType === "salaryItemAdjust") { + params.importType = this.state.importParams.importType; + params.listType = "FIXED"; + } else { + params.listType = this.state.importParams.importType; + } API.importSalaryArchive(params).then(({ status, data }) => { if (status) { data.errorData = data.errorNotice; diff --git a/pc4mobx/hrmSalary/pages/payrollFiles/index.js b/pc4mobx/hrmSalary/pages/payrollFiles/index.js index 5ee14399..47405cca 100644 --- a/pc4mobx/hrmSalary/pages/payrollFiles/index.js +++ b/pc4mobx/hrmSalary/pages/payrollFiles/index.js @@ -223,7 +223,7 @@ class Index extends Component { onOk: () => { API.allGotoFixed({}).then(({ status, data, errormsg }) => { if (status) { - const { msg }= data; + const { msg } = data; message.info(msg || "操作成功!"); this.query(); } else { @@ -293,20 +293,12 @@ class Index extends Component { const { taxAgentStore: { showOperateBtn } } = this.props; if (selectedKey === "pending" && showOperateBtn) { return [ - it.id !== "salaryItemAdjust")} - refreshList={() => { - this.query(); - this.setState({ selectedRowKeys: [] }); - }}/>}> - - , - }> - , + }> + @@ -328,13 +320,14 @@ class Index extends Component { this.setState({ selectedRowKeys: [] }); }}/> }> - , - }> - @@ -365,20 +358,11 @@ class Index extends Component { } this.deleteSuspendTodo(selectedRowKeys); }}>批量删除待办, - it.id !== "salaryItemAdjust")} - refreshList={() => { - this.query(); - this.setState({ selectedRowKeys: [] }); - }}/> - }> - - , - }> + , + }> , - }> + }>