产品-薪酬统计报表列表接口优化以及薪资项目管理列表优化

This commit is contained in:
黎永顺 2023-06-09 10:01:07 +08:00
parent 8bb1146ca5
commit 42f2a8ac55
3 changed files with 19 additions and 5 deletions

View File

@ -86,7 +86,7 @@ class ReportContent extends Component {
this.setState({ loading: true });
reportStatisticsReportGetData(payload).then(({ status, data }) => {
this.setState({ loading: false });
if (status) {
if (status && id === data.reportId) {
const { countResult, columns, pageInfo: { list } } = data;
this.setState({
countResult,

View File

@ -135,9 +135,15 @@ class Index extends Component {
<i
className="icon-coms02-currency"
title={getLabel(111, "统计数据范围及规则设置")}
onClick={() => this.setState({
statisticalPayload: { visible: true, id: report.id, dimension: report.dimensionId }
})}
onClick={() => {
if (this.reportRef.state.loading) {
message.info(getLabel(111, "列表正在加载中,请稍后"))
} else {
this.setState({
statisticalPayload: { visible: true, id: report.id, dimension: report.dimensionId }
});
}
}}
/>
<i className="icon-coms-export" onClick={this.exportData} title={getLabel(111, "导出")}/>
</div>

View File

@ -34,7 +34,15 @@ export default class SystemSalaryItemModal extends React.Component {
if (status) {
const { columns, list: dataSource, pageNum: current, pageSize, total } = data;
this.setState({
columns, dataSource,
columns: _.map(columns, item => {
return {
...item,
render: (text) => {
return <span className="ellipsis" title={text}>{text}</span>;
}
};
}),
dataSource,
pageInfo: { ...pageInfo, current, pageSize, total }
});
}