工资单部分发放和部分撤回

This commit is contained in:
黎永顺 2022-12-07 17:43:39 +08:00
parent 479cea2967
commit 0e53183958
2 changed files with 30 additions and 22 deletions

View File

@ -5,7 +5,7 @@ import { WeaDropdown, WeaHelpfulTip, WeaTab, WeaTop } from "ecCom";
import { Button, Dropdown, Menu, message } from "antd";
import "./index.less";
import { getQueryString } from "../../../util/url";
import { getSearchs } from "../../../util";
import { getSearchs, renderLoading } from "../../../util";
import CustomPaginationTable from "../../../components/customPaginationTable";
import PayrollPartTable from "./payrollPartTable";
@ -56,7 +56,9 @@ export default class PayrollGrant extends React.Component {
}).then(() => {
getInfoList({
salarySendId: this.state.currentId,
isGranted: selectedKey !== "0"
isGranted: selectedKey !== "0",
current: this.pageInfo.current,
pageSize: this.pageInfo.pageSize
});
this.handleClose();
});
@ -73,7 +75,10 @@ export default class PayrollGrant extends React.Component {
}).then(() => {
getInfoList({
salarySendId: currentId,
isGranted: selectedKey !== "0"
isGranted: selectedKey !== "0",
current: this.pageInfo.current,
pageSize: this.pageInfo.pageSize
});
this.handleClose();
});
@ -466,23 +471,26 @@ export default class PayrollGrant extends React.Component {
</div>
</div>
<div className="tableWrapper">
<CustomPaginationTable
rowKey="id"
rowSelection={rowSelection}
dataSource={salaryGrantDataSource}
columns={this.getColumns()}
total={salaryGrantPageInfo.total}
current={salaryGrantPageInfo.pageNum}
pageSize={this.pageInfo.pageSize}
onPageChange={value => {
this.pageInfo.current = value;
this.handleDataPageChange(value);
}}
onShowSizeChange={(current, pageSize) => {
this.pageInfo = { current, pageSize };
this.handleShowSizeChange(this.pageInfo);
}}
/>
{
!_.isEmpty(this.getColumns()) ?
<CustomPaginationTable
rowKey="id"
rowSelection={rowSelection}
dataSource={salaryGrantDataSource}
columns={this.getColumns()}
total={salaryGrantPageInfo.total}
current={salaryGrantPageInfo.pageNum}
pageSize={this.pageInfo.pageSize}
onPageChange={value => {
this.pageInfo.current = value;
this.handleDataPageChange(value);
}}
onShowSizeChange={(current, pageSize) => {
this.pageInfo = { current, pageSize };
this.handleShowSizeChange(this.pageInfo);
}}
/> : renderLoading()
}
</div>
<PayrollPartTable
{...payrollPartModalParams}

View File

@ -57,8 +57,8 @@ class PayrollPartTable extends Component {
pageInfo: { ...pageInfo, current, pageSize, total },
dataSource: _.map(dataSource, it => ({
...it,
includeObj: _.map(it.includeObj, child => child.targetName).join(","),
excludeObj: _.map(it.excludeObj, child => child.targetName).join(",")
includeObj: _.map(it.includeObj, child => child.targetName || child.targetTypeName).join(","),
excludeObj: _.map(it.excludeObj, child => child.targetName || child.targetTypeName).join(",")
})),
columns
});