Compare commits
2 Commits
63a530f4d7
...
ebc80f8b88
| Author | SHA1 | Date |
|---|---|---|
|
|
ebc80f8b88 | |
|
|
d5617ae341 |
|
|
@ -115,3 +115,18 @@ export const getbsReportListSum = (params) => {
|
||||||
export const exportbsReportList = (params) => {
|
export const exportbsReportList = (params) => {
|
||||||
return postExportFetch("/api/bs/hrmsalary/ly/bsReport/export", params);
|
return postExportFetch("/api/bs/hrmsalary/ly/bsReport/export", params);
|
||||||
};
|
};
|
||||||
|
export const getSalaryFileReportList = (type, params) => {
|
||||||
|
return postFetch(`/api/bs/hrmsalary/ly/${type}/list`, params);
|
||||||
|
};
|
||||||
|
export const exportXcdazjtjReport = (params) => {
|
||||||
|
return postExportFetch("/api/bs/hrmsalary/ly/xcdazjtjReport/export", params);
|
||||||
|
};
|
||||||
|
export const exportXcdazwjstjReport = (params) => {
|
||||||
|
return postExportFetch("/api/bs/hrmsalary/ly/xcdazwjstjReport/export", params);
|
||||||
|
};
|
||||||
|
export const exportTxdazjtjReport = (params) => {
|
||||||
|
return postExportFetch("/api/bs/hrmsalary/ly/txdazjtjReport/export", params);
|
||||||
|
};
|
||||||
|
export const exportTxdazwjstjReport = (params) => {
|
||||||
|
return postExportFetch("/api/bs/hrmsalary/ly/txdazwjstjReport/export", params);
|
||||||
|
};
|
||||||
|
|
|
||||||
|
|
@ -8,6 +8,10 @@ import HistoryVouncherSummary from "./lingyue/historyVouncherSummary";
|
||||||
import SalaryStatisticsReport from "./lingyue/salaryStatisticsReport";
|
import SalaryStatisticsReport from "./lingyue/salaryStatisticsReport";
|
||||||
import SalaryPaymentReport from "./lingyue/salaryPaymentReport";
|
import SalaryPaymentReport from "./lingyue/salaryPaymentReport";
|
||||||
import SalaryTaxReturnForm from "./lingyue/salaryTaxReturnForm";
|
import SalaryTaxReturnForm from "./lingyue/salaryTaxReturnForm";
|
||||||
|
import SalaryFileRankReport from "./lingyue/salaryFile/rankReport";
|
||||||
|
import SalaryFilePositionReport from "./lingyue/salaryFile/positionReport";
|
||||||
|
import AdjustSalaryFileRankReport from "./lingyue/adjustSalaryFile/rankReport";
|
||||||
|
import AdjustSalaryFilePositionReport from "./lingyue/adjustSalaryFile/positionReport";
|
||||||
|
|
||||||
const CustomRoutes = [
|
const CustomRoutes = [
|
||||||
<Route key="customPage_salarySummary_lingyue" path="customPage_salarySummary_lingyue"
|
<Route key="customPage_salarySummary_lingyue" path="customPage_salarySummary_lingyue"
|
||||||
|
|
@ -24,7 +28,17 @@ const CustomRoutes = [
|
||||||
<Route key="customPage_paymentReport_lingyue" path="customPage_paymentReport_lingyue"
|
<Route key="customPage_paymentReport_lingyue" path="customPage_paymentReport_lingyue"
|
||||||
component={SalaryPaymentReport}/>,
|
component={SalaryPaymentReport}/>,
|
||||||
<Route key="customPage_salaryTaxReturnForm_lingyue" path="customPage_salaryTaxReturnForm_lingyue"
|
<Route key="customPage_salaryTaxReturnForm_lingyue" path="customPage_salaryTaxReturnForm_lingyue"
|
||||||
component={SalaryTaxReturnForm}/>
|
component={SalaryTaxReturnForm}/>,
|
||||||
|
// 薪酬档案职级和职务统计报表
|
||||||
|
<Route key="customPage_salaryFile_rankReport_lingyue" path="customPage_salaryFile_rankReport_lingyue"
|
||||||
|
component={SalaryFileRankReport}/>,
|
||||||
|
<Route key="customPage_salaryFile_positionReport_lingyue" path="customPage_salaryFile_positionReport_lingyue"
|
||||||
|
component={SalaryFilePositionReport}/>,
|
||||||
|
// 调薪档案职级职务角色统计报表
|
||||||
|
<Route key="customPage_adjustSalaryFile_rankReport_lingyue" path="customPage_adjustSalaryFile_rankReport_lingyue"
|
||||||
|
component={AdjustSalaryFileRankReport}/>,
|
||||||
|
<Route key="customPage_adjustSalaryFile_positionReport_lingyue" path="customPage_adjustSalaryFile_positionReport_lingyue"
|
||||||
|
component={AdjustSalaryFilePositionReport}/>
|
||||||
];
|
];
|
||||||
|
|
||||||
export default CustomRoutes;
|
export default CustomRoutes;
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,143 @@
|
||||||
|
/*
|
||||||
|
* 领悦薪酬档案报表
|
||||||
|
* 公共列表
|
||||||
|
* @Author: 黎永顺
|
||||||
|
* @Date: 2025/9/16
|
||||||
|
* @Wechat:
|
||||||
|
* @Email: 971387674@qq.com
|
||||||
|
* @description:
|
||||||
|
*/
|
||||||
|
import React, { Component } from "react";
|
||||||
|
import { WeaEchart, WeaLeftRightLayout, WeaLocaleProvider, WeaTable } from "ecCom";
|
||||||
|
import * as API from "../../../../apis/custom-apis/lingyue";
|
||||||
|
import { format_with_regex } from "../../../../util";
|
||||||
|
import "./index.less";
|
||||||
|
|
||||||
|
const getLabel = WeaLocaleProvider.getLabel;
|
||||||
|
const colorList = ["#709DF7", "#73DEB3", "#7585A2", "#F7C739", "#5FC3E3", "#AEE279", "#FF7F81"];
|
||||||
|
|
||||||
|
class Content extends Component {
|
||||||
|
constructor(props) {
|
||||||
|
super(props);
|
||||||
|
this.state = {
|
||||||
|
columns: [], dataSource: [], loading: false, chartsDataA: {}, chartsDataB: {},
|
||||||
|
showLeft: false
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
componentDidMount() {
|
||||||
|
this.getSalaryFileReportList();
|
||||||
|
}
|
||||||
|
|
||||||
|
componentWillReceiveProps(nextProps, nextContext) {
|
||||||
|
if (nextProps.isQuery !== this.props.isQuery) this.getSalaryFileReportList(nextProps);
|
||||||
|
}
|
||||||
|
|
||||||
|
componentDidUpdate(prevProps, prevState, snapshot) {
|
||||||
|
if (prevState.showLeft !== this.state.showLeft) {
|
||||||
|
this.refs.chartA.paint();
|
||||||
|
this.refs.chartB.paint();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
getSalaryFileReportList = (props) => {
|
||||||
|
const { type, queryParams } = props || this.props,
|
||||||
|
{ dateRange, pqList, xmList, zwjsList, ...extra } = queryParams;
|
||||||
|
const [startDate, endDate] = dateRange;
|
||||||
|
const payload = {
|
||||||
|
pqList: pqList ? pqList.split(",") : [],
|
||||||
|
xmList: xmList ? xmList.split(",") : [],
|
||||||
|
zwjsList: zwjsList ? zwjsList.split(",") : [],
|
||||||
|
startDate, endDate, ...extra
|
||||||
|
};
|
||||||
|
this.setState({ loading: true });
|
||||||
|
API.getSalaryFileReportList(type, payload).then(({ status, data: result }) => {
|
||||||
|
this.setState({ loading: false });
|
||||||
|
if (status) {
|
||||||
|
const { data: dataSource, columns, chartsDataA, chartsDataB } = result;
|
||||||
|
this.setState({
|
||||||
|
dataSource,
|
||||||
|
chartsDataA: _.reduce(_.keys(chartsDataA), (pre, cur) => {
|
||||||
|
return [...pre, { name: cur, value: chartsDataA[cur] }];
|
||||||
|
}, []),
|
||||||
|
chartsDataB: _.reduce(_.keys(chartsDataB), (pre, cur) => {
|
||||||
|
return [...pre, { name: cur, value: chartsDataB[cur] }];
|
||||||
|
}, []),
|
||||||
|
columns: _.map(columns, o => ({ title: o.text, width: o.width, dataIndex: o.column }))
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
};
|
||||||
|
mapPieOptions = (data, pieName) => {
|
||||||
|
return {
|
||||||
|
tooltip: {
|
||||||
|
show: true,
|
||||||
|
formatter: function (params) {
|
||||||
|
let str = params.seriesName + "<br>";
|
||||||
|
str += params.marker + params.name + ":" + format_with_regex(params.value) + "(" + params.percent + "%" + ")" + "<br>";
|
||||||
|
return str;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
legend: {
|
||||||
|
type: "scroll",
|
||||||
|
icon: "rect",
|
||||||
|
bottom: "2%",
|
||||||
|
orient: "horizontal",
|
||||||
|
itemGap: 10,
|
||||||
|
textStyle: {
|
||||||
|
fontSize: 12,//字体大小
|
||||||
|
color: "#787E95"//字体颜色
|
||||||
|
}
|
||||||
|
},
|
||||||
|
series: [
|
||||||
|
{
|
||||||
|
name: pieName,
|
||||||
|
data: data,
|
||||||
|
type: "pie",
|
||||||
|
radius: "60%",
|
||||||
|
avoidLabelOverlap: true,
|
||||||
|
animation: false,
|
||||||
|
labelLine: {
|
||||||
|
show: true,
|
||||||
|
normal: {
|
||||||
|
length: 5,
|
||||||
|
align: "center"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
itemStyle: {
|
||||||
|
normal: {
|
||||||
|
color: function (colors) {
|
||||||
|
return colorList[colors.dataIndex] || colorList[Math.floor((Math.random() * colorList.length))];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
render() {
|
||||||
|
const { columns, dataSource, chartsDataA, chartsDataB, loading, showLeft } = this.state;
|
||||||
|
return (<WeaLeftRightLayout leftWidth={310} showLeft={showLeft}
|
||||||
|
onCollapse={v => this.setState({ showLeft: v })}
|
||||||
|
leftCom={<div className="salaryFileReport_lingyue">
|
||||||
|
<div className="salaryFileReport_item">
|
||||||
|
<WeaEchart
|
||||||
|
ref="chartA" useDefault={false} className="chart"
|
||||||
|
option={this.mapPieOptions(chartsDataA, getLabel(111, "周期内调薪人数比例"))}
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
<div className="salaryFileReport_item">
|
||||||
|
<WeaEchart
|
||||||
|
ref="chartB" useDefault={false} className="chart"
|
||||||
|
option={this.mapPieOptions(chartsDataB, getLabel(111, "周期内调薪总额比例"))}
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
</div>}>
|
||||||
|
<WeaTable columns={columns} dataSource={dataSource} loading={loading} pagination={false} bordered
|
||||||
|
scroll={{ x: 1200, y: `calc(100vh - 126px)` }}/>
|
||||||
|
</WeaLeftRightLayout>);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export default Content;
|
||||||
|
|
@ -0,0 +1,10 @@
|
||||||
|
.salaryFileReport_lingyue {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
height: 100%;
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.salaryFileReport_item {
|
||||||
|
flex: 1;
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,34 @@
|
||||||
|
/*
|
||||||
|
* 领悦调薪档案报表
|
||||||
|
*
|
||||||
|
* @Author: 黎永顺
|
||||||
|
* @Date: 2025/9/16
|
||||||
|
* @Wechat:
|
||||||
|
* @Email: 971387674@qq.com
|
||||||
|
* @description:
|
||||||
|
*/
|
||||||
|
import React, { Component } from "react";
|
||||||
|
import { WeaLocaleProvider, WeaRangePicker, WeaTop } from "ecCom";
|
||||||
|
import { Button } from "antd";
|
||||||
|
import "../index.less"
|
||||||
|
|
||||||
|
const getLabel = WeaLocaleProvider.getLabel;
|
||||||
|
|
||||||
|
class Layout extends Component {
|
||||||
|
|
||||||
|
render() {
|
||||||
|
const { title, onExport, dateRange, onChange } = this.props;
|
||||||
|
const buttons = [
|
||||||
|
<WeaRangePicker value={dateRange} onChange={onChange}/>,
|
||||||
|
<Button type="primary" onClick={onExport}>{getLabel(111, "导出全部")}</Button>
|
||||||
|
];
|
||||||
|
return (<WeaTop title={title} icon={<i className="icon-coms-fa"/>} buttons={buttons} showDropIcon={false}
|
||||||
|
iconBgcolor="#F14A2D" className="custom_salary_lingyue">
|
||||||
|
<div className="lingyue-body">
|
||||||
|
{this.props.children}
|
||||||
|
</div>
|
||||||
|
</WeaTop>);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export default Layout;
|
||||||
|
|
@ -0,0 +1,129 @@
|
||||||
|
/*
|
||||||
|
* 领悦薪酬档案报表
|
||||||
|
* 调薪档案职务角色统计报表
|
||||||
|
* @Author: 黎永顺
|
||||||
|
* @Date: 2025/9/16
|
||||||
|
* @Wechat:
|
||||||
|
* @Email: 971387674@qq.com
|
||||||
|
* @description:
|
||||||
|
*/
|
||||||
|
import React, { Component } from "react";
|
||||||
|
import { WeaBrowser, WeaFormItem, WeaLoadingGlobal, WeaLocaleProvider } from "ecCom";
|
||||||
|
import * as API from "../../../../../apis/custom-apis/lingyue";
|
||||||
|
import SalaryFileReportLayout from "../layout";
|
||||||
|
import SalaryFileReport from "../content";
|
||||||
|
import moment from "moment";
|
||||||
|
|
||||||
|
const getLabel = WeaLocaleProvider.getLabel;
|
||||||
|
|
||||||
|
class Index extends Component {
|
||||||
|
constructor(props) {
|
||||||
|
super(props);
|
||||||
|
this.state = {
|
||||||
|
isQuery: false,
|
||||||
|
queryParams: {
|
||||||
|
pqList: "", xmList: "", zwjsList: "",
|
||||||
|
dateRange: [
|
||||||
|
moment(new Date()).format("YYYY-MM-DD"),
|
||||||
|
moment(new Date()).format("YYYY-MM-DD")
|
||||||
|
]
|
||||||
|
}
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
handleExport = async () => {
|
||||||
|
const { queryParams } = this.state;
|
||||||
|
const { dateRange, pqList, xmList, zwjsList } = queryParams;
|
||||||
|
const [startDate, endDate] = dateRange;
|
||||||
|
WeaLoadingGlobal.start();
|
||||||
|
const payload = {
|
||||||
|
pqList: pqList ? pqList.split(",") : [],
|
||||||
|
xmList: xmList ? xmList.split(",") : [],
|
||||||
|
zwjsList: zwjsList ? zwjsList.split(",") : [],
|
||||||
|
startDate, endDate
|
||||||
|
};
|
||||||
|
const promise = await API.exportTxdazwjstjReport(payload);
|
||||||
|
};
|
||||||
|
getBrowserPatams = (type, title) => {
|
||||||
|
let custBrowserParams = {};
|
||||||
|
type === 162 && (custBrowserParams = {
|
||||||
|
completeParams: {
|
||||||
|
type: 162,
|
||||||
|
fielddbtype: "browser.b_zwjs"
|
||||||
|
},
|
||||||
|
conditionDataParams: {
|
||||||
|
type: 162,
|
||||||
|
fielddbtype: "browser.b_zwjs"
|
||||||
|
},
|
||||||
|
dataParams: {
|
||||||
|
type: 162,
|
||||||
|
fielddbtype: "browser.b_zwjs"
|
||||||
|
},
|
||||||
|
destDataParams: {
|
||||||
|
type: 162,
|
||||||
|
fielddbtype: "browser.b_zwjs"
|
||||||
|
},
|
||||||
|
isMultCheckbox: true
|
||||||
|
});
|
||||||
|
return {
|
||||||
|
completeParams: {},
|
||||||
|
conditionDataParams: {},
|
||||||
|
dataParams: {},
|
||||||
|
destDataParams: {},
|
||||||
|
hasAddBtn: false,
|
||||||
|
hasAdvanceSerach: false,
|
||||||
|
idSeparator: ",",
|
||||||
|
isAutoComplete: 1,
|
||||||
|
isDetail: 0,
|
||||||
|
isMultCheckbox: false,
|
||||||
|
isSingle: false,
|
||||||
|
icon: "icon-coms-hrm",
|
||||||
|
linkUrl: "",
|
||||||
|
pageSize: 10,
|
||||||
|
quickSearchName: "",
|
||||||
|
title,
|
||||||
|
type,
|
||||||
|
viewAttr: 2,
|
||||||
|
...custBrowserParams
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
render() {
|
||||||
|
const { queryParams, isQuery } = this.state;
|
||||||
|
const { dateRange, zwjsList, pqList, xmList } = queryParams;
|
||||||
|
return (
|
||||||
|
<SalaryFileReportLayout title={getLabel(111, "调薪档案职务角色统计报表")} dateRange={dateRange}
|
||||||
|
onExport={this.handleExport}
|
||||||
|
onChange={v => this.setState({
|
||||||
|
queryParams: { ...queryParams, dateRange: v },
|
||||||
|
isQuery: !isQuery
|
||||||
|
})}>
|
||||||
|
<div className="lingyue-query">
|
||||||
|
<WeaFormItem label={getLabel(111, "片区")} labelCol={{ span: 8 }} wrapperCol={{ span: 16 }}>
|
||||||
|
<WeaBrowser type={194} value={pqList}
|
||||||
|
onChange={v => {
|
||||||
|
this.setState({ queryParams: { ...queryParams, pqList: v }, isQuery: !isQuery });
|
||||||
|
}}
|
||||||
|
title={getLabel(111, "片区")} {...this.getBrowserPatams(194, getLabel(111, "片区"))} />
|
||||||
|
</WeaFormItem>
|
||||||
|
<WeaFormItem label={getLabel(111, "项目")} labelCol={{ span: 8 }} wrapperCol={{ span: 16 }}>
|
||||||
|
<WeaBrowser type={194} value={xmList}
|
||||||
|
onChange={v => this.setState({ queryParams: { ...queryParams, xmList: v }, isQuery: !isQuery })}
|
||||||
|
title={getLabel(111, "项目")} {...this.getBrowserPatams(194, getLabel(111, "项目"))} />
|
||||||
|
</WeaFormItem>
|
||||||
|
<WeaFormItem label={getLabel(111, "职务角色")} labelCol={{ span: 8 }} wrapperCol={{ span: 16 }}>
|
||||||
|
<WeaBrowser type={194} value={zwjsList}
|
||||||
|
onChange={v => this.setState({
|
||||||
|
queryParams: { ...queryParams, zwjsList: v },
|
||||||
|
isQuery: !isQuery
|
||||||
|
})}
|
||||||
|
title={getLabel(111, "职务角色")} {...this.getBrowserPatams(162, getLabel(111, "职务角色"))} />
|
||||||
|
</WeaFormItem>
|
||||||
|
</div>
|
||||||
|
<SalaryFileReport type="txdazwjstjReport" queryParams={queryParams} isQuery={isQuery}/>
|
||||||
|
</SalaryFileReportLayout>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export default Index;
|
||||||
|
|
@ -0,0 +1,101 @@
|
||||||
|
/*
|
||||||
|
* 领悦调薪档案报表
|
||||||
|
* 调薪档案职级统计报表
|
||||||
|
* @Author: 黎永顺
|
||||||
|
* @Date: 2025/9/16
|
||||||
|
* @Wechat:
|
||||||
|
* @Email: 971387674@qq.com
|
||||||
|
* @description:
|
||||||
|
*/
|
||||||
|
import React, { Component } from "react";
|
||||||
|
import { WeaBrowser, WeaFormItem, WeaInputSearch, WeaLoadingGlobal, WeaLocaleProvider } from "ecCom";
|
||||||
|
import SalaryFileReportLayout from "../layout";
|
||||||
|
import SalaryFileReport from "../content";
|
||||||
|
import * as API from "../../../../../apis/custom-apis/lingyue";
|
||||||
|
import moment from "moment";
|
||||||
|
|
||||||
|
const getLabel = WeaLocaleProvider.getLabel;
|
||||||
|
|
||||||
|
class Index extends Component {
|
||||||
|
constructor(props) {
|
||||||
|
super(props);
|
||||||
|
this.state = {
|
||||||
|
isQuery: false,
|
||||||
|
queryParams: {
|
||||||
|
pqList: "", xmList: "", zj: "",
|
||||||
|
dateRange: [
|
||||||
|
moment(new Date()).format("YYYY-MM-DD"),
|
||||||
|
moment(new Date()).format("YYYY-MM-DD")
|
||||||
|
]
|
||||||
|
}
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
handleExport = async () => {
|
||||||
|
const { queryParams } = this.state;
|
||||||
|
const { dateRange, pqList, xmList, ...extra } = queryParams;
|
||||||
|
const [startDate, endDate] = dateRange;
|
||||||
|
WeaLoadingGlobal.start();
|
||||||
|
const payload = {
|
||||||
|
pqList: pqList ? pqList.split(",") : [],
|
||||||
|
xmList: xmList ? xmList.split(",") : [],
|
||||||
|
startDate, endDate, ...extra
|
||||||
|
};
|
||||||
|
const promise = await API.exportTxdazjtjReport(payload);
|
||||||
|
};
|
||||||
|
getBrowserPatams = (type, title) => {
|
||||||
|
return {
|
||||||
|
completeParams: {},
|
||||||
|
conditionDataParams: {},
|
||||||
|
dataParams: {},
|
||||||
|
destDataParams: {},
|
||||||
|
hasAddBtn: false,
|
||||||
|
hasAdvanceSerach: false,
|
||||||
|
idSeparator: ",",
|
||||||
|
isAutoComplete: 1,
|
||||||
|
isDetail: 0,
|
||||||
|
isMultCheckbox: false,
|
||||||
|
isSingle: false,
|
||||||
|
icon: "icon-coms-hrm",
|
||||||
|
linkUrl: "",
|
||||||
|
pageSize: 10,
|
||||||
|
quickSearchName: "",
|
||||||
|
title,
|
||||||
|
type,
|
||||||
|
viewAttr: 2
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
render() {
|
||||||
|
const { queryParams, isQuery } = this.state;
|
||||||
|
const { dateRange, zj, pqList, xmList } = queryParams;
|
||||||
|
return (
|
||||||
|
<SalaryFileReportLayout title={getLabel(111, "调薪档案职级统计报表")} dateRange={dateRange}
|
||||||
|
onExport={this.handleExport}
|
||||||
|
onChange={v => this.setState({
|
||||||
|
queryParams: { ...queryParams, dateRange: v },
|
||||||
|
isQuery: !isQuery
|
||||||
|
})}>
|
||||||
|
<div className="lingyue-query">
|
||||||
|
<WeaFormItem label={getLabel(111, "片区")} labelCol={{ span: 8 }} wrapperCol={{ span: 16 }}>
|
||||||
|
<WeaBrowser type={194} value={pqList}
|
||||||
|
onChange={v => this.setState({ queryParams: { ...queryParams, pqList: v }, isQuery: !isQuery })}
|
||||||
|
title={getLabel(111, "片区")} {...this.getBrowserPatams(194, getLabel(111, "片区"))} />
|
||||||
|
</WeaFormItem>
|
||||||
|
<WeaFormItem label={getLabel(111, "项目")} labelCol={{ span: 8 }} wrapperCol={{ span: 16 }}>
|
||||||
|
<WeaBrowser type={194} value={xmList}
|
||||||
|
onChange={v => this.setState({ queryParams: { ...queryParams, xmList: v }, isQuery: !isQuery })}
|
||||||
|
title={getLabel(111, "项目")} {...this.getBrowserPatams(194, getLabel(111, "项目"))} />
|
||||||
|
</WeaFormItem>
|
||||||
|
<WeaFormItem label={getLabel(111, "职级")} labelCol={{ span: 8 }} wrapperCol={{ span: 16 }}>
|
||||||
|
<WeaInputSearch value={zj} onChange={v => this.setState({ queryParams: { ...queryParams, zj: v } })}
|
||||||
|
onSearch={() => this.setState({ isQuery: !isQuery })}/>
|
||||||
|
</WeaFormItem>
|
||||||
|
</div>
|
||||||
|
<SalaryFileReport type="txdazjtjReport" queryParams={queryParams} isQuery={isQuery}/>
|
||||||
|
</SalaryFileReportLayout>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export default Index;
|
||||||
|
|
@ -0,0 +1,126 @@
|
||||||
|
/*
|
||||||
|
* 领悦薪酬档案报表
|
||||||
|
* 公共列表
|
||||||
|
* @Author: 黎永顺
|
||||||
|
* @Date: 2025/9/16
|
||||||
|
* @Wechat:
|
||||||
|
* @Email: 971387674@qq.com
|
||||||
|
* @description:
|
||||||
|
*/
|
||||||
|
import React, { Component } from "react";
|
||||||
|
import { WeaEchart, WeaLeftRightLayout, WeaLocaleProvider, WeaTable } from "ecCom";
|
||||||
|
import * as API from "../../../../apis/custom-apis/lingyue";
|
||||||
|
import { format_with_regex } from "../../../../util";
|
||||||
|
|
||||||
|
const getLabel = WeaLocaleProvider.getLabel;
|
||||||
|
const colorList = ["#709DF7", "#73DEB3", "#7585A2", "#F7C739", "#5FC3E3", "#AEE279", "#FF7F81"];
|
||||||
|
|
||||||
|
class Content extends Component {
|
||||||
|
constructor(props) {
|
||||||
|
super(props);
|
||||||
|
this.state = {
|
||||||
|
columns: [], dataSource: [], loading: false, chartsData: {}, showLeft: false
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
componentDidMount() {
|
||||||
|
this.getSalaryFileReportList();
|
||||||
|
}
|
||||||
|
|
||||||
|
componentWillReceiveProps(nextProps, nextContext) {
|
||||||
|
if (nextProps.isQuery !== this.props.isQuery) this.getSalaryFileReportList(nextProps);
|
||||||
|
}
|
||||||
|
|
||||||
|
componentDidUpdate(prevProps, prevState, snapshot) {
|
||||||
|
if (prevState.showLeft !== this.state.showLeft) this.refs.chart.paint();
|
||||||
|
}
|
||||||
|
|
||||||
|
getSalaryFileReportList = (props) => {
|
||||||
|
const { type, queryParams } = props || this.props;
|
||||||
|
const { dateRange, pqList, xmList, zwjsList, ...extra } = queryParams;
|
||||||
|
|
||||||
|
this.setState({ loading: true });
|
||||||
|
const payload = {
|
||||||
|
pqList: pqList ? pqList.split(",") : [],
|
||||||
|
xmList: xmList ? xmList.split(",") : [],
|
||||||
|
zwjsList: zwjsList ? zwjsList.split(",") : [],
|
||||||
|
...extra
|
||||||
|
};
|
||||||
|
API.getSalaryFileReportList(type, payload).then(({ status, data: result }) => {
|
||||||
|
this.setState({ loading: false });
|
||||||
|
if (status) {
|
||||||
|
const { data: dataSource, columns, chartsData } = result;
|
||||||
|
this.setState({
|
||||||
|
dataSource,
|
||||||
|
chartsData: _.reduce(_.keys(chartsData), (pre, cur) => {
|
||||||
|
return [...pre, { name: cur, value: chartsData[cur] }];
|
||||||
|
}, []),
|
||||||
|
columns: _.map(columns, o => ({ title: o.text, width: o.width, dataIndex: o.column }))
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
};
|
||||||
|
mapPieOptions = (data) => {
|
||||||
|
const { pieName } = this.props;
|
||||||
|
return {
|
||||||
|
tooltip: {
|
||||||
|
show: true,
|
||||||
|
formatter: function (params) {
|
||||||
|
let str = params.seriesName + "<br>";
|
||||||
|
str += params.marker + params.name + ":" + format_with_regex(params.value) + "(" + params.percent + "%" + ")" + "<br>";
|
||||||
|
return str;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
legend: {
|
||||||
|
type: "scroll",
|
||||||
|
icon: "rect",
|
||||||
|
bottom: "2%",
|
||||||
|
orient: "horizontal",
|
||||||
|
itemGap: 10,
|
||||||
|
textStyle: {
|
||||||
|
fontSize: 12,//字体大小
|
||||||
|
color: "#787E95"//字体颜色
|
||||||
|
}
|
||||||
|
},
|
||||||
|
series: [
|
||||||
|
{
|
||||||
|
name: pieName,
|
||||||
|
data: data,
|
||||||
|
type: "pie",
|
||||||
|
radius: "60%",
|
||||||
|
avoidLabelOverlap: true,
|
||||||
|
animation: false,
|
||||||
|
labelLine: {
|
||||||
|
show: true,
|
||||||
|
normal: {
|
||||||
|
length: 5,
|
||||||
|
align: "center"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
itemStyle: {
|
||||||
|
normal: {
|
||||||
|
color: function (colors) {
|
||||||
|
return colorList[colors.dataIndex] || colorList[Math.floor((Math.random() * colorList.length))];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
render() {
|
||||||
|
const { columns, dataSource, chartsData, loading, showLeft } = this.state;
|
||||||
|
return (<WeaLeftRightLayout leftWidth={310} showLeft={showLeft}
|
||||||
|
onCollapse={v => this.setState({ showLeft: v })}
|
||||||
|
leftCom={<WeaEchart
|
||||||
|
ref="chart" useDefault={false} className="chart"
|
||||||
|
option={this.mapPieOptions(chartsData)}
|
||||||
|
/>}>
|
||||||
|
<WeaTable columns={columns} dataSource={dataSource} loading={loading} pagination={false} bordered
|
||||||
|
scroll={{ x: 1200, y: `calc(100vh - 126px)` }}/>
|
||||||
|
</WeaLeftRightLayout>);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export default Content;
|
||||||
|
|
@ -0,0 +1,32 @@
|
||||||
|
/*
|
||||||
|
* 领悦薪酬档案报表
|
||||||
|
*
|
||||||
|
* @Author: 黎永顺
|
||||||
|
* @Date: 2025/9/16
|
||||||
|
* @Wechat:
|
||||||
|
* @Email: 971387674@qq.com
|
||||||
|
* @description:
|
||||||
|
*/
|
||||||
|
import React, { Component } from "react";
|
||||||
|
import { WeaLocaleProvider, WeaTop } from "ecCom";
|
||||||
|
import { Button } from "antd";
|
||||||
|
import "../index.less";
|
||||||
|
|
||||||
|
const getLabel = WeaLocaleProvider.getLabel;
|
||||||
|
|
||||||
|
class Layout extends Component {
|
||||||
|
render() {
|
||||||
|
const { title, onExport } = this.props;
|
||||||
|
const buttons = [
|
||||||
|
<Button type="primary" onClick={onExport}>{getLabel(111, "导出全部")}</Button>
|
||||||
|
];
|
||||||
|
return (<WeaTop title={title} icon={<i className="icon-coms-fa"/>} buttons={buttons} showDropIcon={false}
|
||||||
|
iconBgcolor="#F14A2D" className="custom_salary_lingyue">
|
||||||
|
<div className="lingyue-body">
|
||||||
|
{this.props.children}
|
||||||
|
</div>
|
||||||
|
</WeaTop>);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export default Layout;
|
||||||
|
|
@ -0,0 +1,114 @@
|
||||||
|
/*
|
||||||
|
* 领悦薪酬档案报表
|
||||||
|
* 薪酬档案职务角色统计报表
|
||||||
|
* @Author: 黎永顺
|
||||||
|
* @Date: 2025/9/16
|
||||||
|
* @Wechat:
|
||||||
|
* @Email: 971387674@qq.com
|
||||||
|
* @description:
|
||||||
|
*/
|
||||||
|
import React, { Component } from "react";
|
||||||
|
import { WeaBrowser, WeaFormItem, WeaLoadingGlobal, WeaLocaleProvider } from "ecCom";
|
||||||
|
import * as API from "../../../../../apis/custom-apis/lingyue";
|
||||||
|
import SalaryFileReportLayout from "../layout";
|
||||||
|
import SalaryFileReport from "../content";
|
||||||
|
|
||||||
|
const getLabel = WeaLocaleProvider.getLabel;
|
||||||
|
|
||||||
|
class Index extends Component {
|
||||||
|
constructor(props) {
|
||||||
|
super(props);
|
||||||
|
this.state = {
|
||||||
|
isQuery: false,
|
||||||
|
queryParams: {
|
||||||
|
pqList: "", xmList: "", zwjsList: ""
|
||||||
|
}
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
handleExport = async () => {
|
||||||
|
const { queryParams } = this.state;
|
||||||
|
const { pqList, xmList, zwjsList } = queryParams;
|
||||||
|
WeaLoadingGlobal.start();
|
||||||
|
const payload = {
|
||||||
|
pqList: pqList ? pqList.split(",") : [],
|
||||||
|
xmList: xmList ? xmList.split(",") : [],
|
||||||
|
zwjsList: zwjsList ? zwjsList.split(",") : []
|
||||||
|
};
|
||||||
|
const promise = await API.exportXcdazwjstjReport(payload);
|
||||||
|
};
|
||||||
|
getBrowserPatams = (type, title) => {
|
||||||
|
let custBrowserParams = {};
|
||||||
|
type === 162 && (custBrowserParams = {
|
||||||
|
completeParams: {
|
||||||
|
type: 162,
|
||||||
|
fielddbtype: "browser.b_zwjs"
|
||||||
|
},
|
||||||
|
conditionDataParams: {
|
||||||
|
type: 162,
|
||||||
|
fielddbtype: "browser.b_zwjs"
|
||||||
|
},
|
||||||
|
dataParams: {
|
||||||
|
type: 162,
|
||||||
|
fielddbtype: "browser.b_zwjs"
|
||||||
|
},
|
||||||
|
destDataParams: {
|
||||||
|
type: 162,
|
||||||
|
fielddbtype: "browser.b_zwjs"
|
||||||
|
},
|
||||||
|
isMultCheckbox: true
|
||||||
|
});
|
||||||
|
|
||||||
|
return {
|
||||||
|
completeParams: {},
|
||||||
|
conditionDataParams: {},
|
||||||
|
dataParams: {},
|
||||||
|
destDataParams: {},
|
||||||
|
hasAddBtn: false,
|
||||||
|
hasAdvanceSerach: false,
|
||||||
|
idSeparator: ",",
|
||||||
|
isAutoComplete: 1,
|
||||||
|
isDetail: 0,
|
||||||
|
isMultCheckbox: false,
|
||||||
|
isSingle: false,
|
||||||
|
icon: "icon-coms-hrm",
|
||||||
|
linkUrl: "",
|
||||||
|
pageSize: 10,
|
||||||
|
quickSearchName: "",
|
||||||
|
title,
|
||||||
|
type,
|
||||||
|
viewAttr: 2,
|
||||||
|
...custBrowserParams
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
render() {
|
||||||
|
const { queryParams, isQuery } = this.state;
|
||||||
|
const { zwjsList, pqList, xmList } = queryParams;
|
||||||
|
return (
|
||||||
|
<SalaryFileReportLayout title={getLabel(111, "薪酬档案职务角色统计报表")} onExport={this.handleExport}>
|
||||||
|
<div className="lingyue-query">
|
||||||
|
<WeaFormItem label={getLabel(111, "片区")} labelCol={{ span: 8 }} wrapperCol={{ span: 16 }}>
|
||||||
|
<WeaBrowser type={194} value={pqList}
|
||||||
|
onChange={v => this.setState({ queryParams: { ...queryParams, pqList: v }, isQuery: !isQuery })}
|
||||||
|
title={getLabel(111, "片区")} {...this.getBrowserPatams(194, getLabel(111, "片区"))} />
|
||||||
|
</WeaFormItem>
|
||||||
|
<WeaFormItem label={getLabel(111, "项目")} labelCol={{ span: 8 }} wrapperCol={{ span: 16 }}>
|
||||||
|
<WeaBrowser type={194} value={xmList}
|
||||||
|
onChange={v => this.setState({ queryParams: { ...queryParams, xmList: v }, isQuery: !isQuery })}
|
||||||
|
title={getLabel(111, "项目")} {...this.getBrowserPatams(194, getLabel(111, "项目"))} />
|
||||||
|
</WeaFormItem>
|
||||||
|
<WeaFormItem label={getLabel(111, "职务角色")} labelCol={{ span: 8 }} wrapperCol={{ span: 16 }}>
|
||||||
|
<WeaBrowser type={194} value={zwjsList}
|
||||||
|
onChange={v => this.setState({ queryParams: { ...queryParams, zwjsList: v }, isQuery: !isQuery })}
|
||||||
|
title={getLabel(111, "职务角色")} {...this.getBrowserPatams(162, getLabel(111, "职务角色"))} />
|
||||||
|
</WeaFormItem>
|
||||||
|
</div>
|
||||||
|
<SalaryFileReport type="xcdazwjstjReport" isQuery={isQuery} queryParams={queryParams}
|
||||||
|
pieName={getLabel(111, "职务角色")}/>
|
||||||
|
</SalaryFileReportLayout>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export default Index;
|
||||||
|
|
@ -0,0 +1,88 @@
|
||||||
|
/*
|
||||||
|
* 领悦薪酬档案报表
|
||||||
|
* 薪酬档案职级统计报表
|
||||||
|
* @Author: 黎永顺
|
||||||
|
* @Date: 2025/9/16
|
||||||
|
* @Wechat:
|
||||||
|
* @Email: 971387674@qq.com
|
||||||
|
* @description:
|
||||||
|
*/
|
||||||
|
import React, { Component } from "react";
|
||||||
|
import { WeaBrowser, WeaFormItem, WeaInputSearch, WeaLoadingGlobal, WeaLocaleProvider } from "ecCom";
|
||||||
|
import SalaryFileReportLayout from "../layout";
|
||||||
|
import SalaryFileReport from "../content";
|
||||||
|
import * as API from "../../../../../apis/custom-apis/lingyue";
|
||||||
|
|
||||||
|
const getLabel = WeaLocaleProvider.getLabel;
|
||||||
|
|
||||||
|
class Index extends Component {
|
||||||
|
constructor(props) {
|
||||||
|
super(props);
|
||||||
|
this.state = {
|
||||||
|
isQuery: false, queryParams: { pqList: "", xmList: "", zj: "" }
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
handleExport = async () => {
|
||||||
|
const { queryParams } = this.state;
|
||||||
|
const { pqList, xmList, ...extra } = queryParams;
|
||||||
|
WeaLoadingGlobal.start();
|
||||||
|
const payload = {
|
||||||
|
pqList: pqList ? pqList.split(",") : [],
|
||||||
|
xmList: xmList ? xmList.split(",") : [],
|
||||||
|
...extra
|
||||||
|
};
|
||||||
|
const promise = await API.exportXcdazjtjReport(payload);
|
||||||
|
};
|
||||||
|
getBrowserPatams = (type, title) => {
|
||||||
|
return {
|
||||||
|
completeParams: {},
|
||||||
|
conditionDataParams: {},
|
||||||
|
dataParams: {},
|
||||||
|
destDataParams: {},
|
||||||
|
hasAddBtn: false,
|
||||||
|
hasAdvanceSerach: false,
|
||||||
|
idSeparator: ",",
|
||||||
|
isAutoComplete: 1,
|
||||||
|
isDetail: 0,
|
||||||
|
isMultCheckbox: false,
|
||||||
|
isSingle: false,
|
||||||
|
icon: "icon-coms-hrm",
|
||||||
|
linkUrl: "",
|
||||||
|
pageSize: 10,
|
||||||
|
quickSearchName: "",
|
||||||
|
title,
|
||||||
|
type,
|
||||||
|
viewAttr: 2
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
render() {
|
||||||
|
const { queryParams, isQuery } = this.state;
|
||||||
|
const { zj, pqList, xmList } = queryParams;
|
||||||
|
return (
|
||||||
|
<SalaryFileReportLayout title={getLabel(111, "薪酬档案职级统计报表")} onExport={this.handleExport}>
|
||||||
|
<div className="lingyue-query">
|
||||||
|
<WeaFormItem label={getLabel(111, "片区")} labelCol={{ span: 8 }} wrapperCol={{ span: 16 }}>
|
||||||
|
<WeaBrowser type={194} value={pqList}
|
||||||
|
onChange={v => this.setState({ queryParams: { ...queryParams, pqList: v }, isQuery: !isQuery })}
|
||||||
|
title={getLabel(111, "片区")} {...this.getBrowserPatams(194, getLabel(111, "片区"))} />
|
||||||
|
</WeaFormItem>
|
||||||
|
<WeaFormItem label={getLabel(111, "项目")} labelCol={{ span: 8 }} wrapperCol={{ span: 16 }}>
|
||||||
|
<WeaBrowser type={194} value={xmList}
|
||||||
|
onChange={v => this.setState({ queryParams: { ...queryParams, xmList: v }, isQuery: !isQuery })}
|
||||||
|
title={getLabel(111, "项目")} {...this.getBrowserPatams(194, getLabel(111, "项目"))} />
|
||||||
|
</WeaFormItem>
|
||||||
|
<WeaFormItem label={getLabel(111, "职级")} labelCol={{ span: 8 }} wrapperCol={{ span: 16 }}>
|
||||||
|
<WeaInputSearch value={zj} onChange={v => this.setState({ queryParams: { ...queryParams, zj: v } })}
|
||||||
|
onSearch={() => this.setState({ isQuery: !isQuery })}/>
|
||||||
|
</WeaFormItem>
|
||||||
|
</div>
|
||||||
|
<SalaryFileReport type="xcdazjtjReport" isQuery={isQuery} queryParams={queryParams}
|
||||||
|
pieName={getLabel(111, "职级")}/>
|
||||||
|
</SalaryFileReportLayout>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export default Index;
|
||||||
Loading…
Reference in New Issue