feature/2.16.1.2410.01-薪酬统计报表薪资明细添加模板切换和模板创建功能

This commit is contained in:
lys 2024-11-07 09:23:46 +08:00
parent e9f4d9b043
commit 0abeee25f3
5 changed files with 65 additions and 99 deletions

View File

@ -54,68 +54,16 @@ import TopologyMap from "./pages/topologyMap";
import SupplementaryCalc from "./pages/supplementaryCalc";
import VariableSalary from "./pages/variableSalary";
import Layout from "./layout";
import stores from "./stores";
import "./style/index";
// 读取系统多语言配置
let getLocaleLabel = WeaLocaleProvider.getLocaleLabel.bind(this, "hrmSalary");
// 不需要读取系统多语言
getLocaleLabel = function (nextState, replace, callback) {
callback();
};
const Home = (props) => props.children;
const SocialSecurityBenefits = (props) => props.children;
const DataAcquisition = (props) => props.children;
// historicalPayroll 历史工资单查看
// salaryAdjustmentRecords 调薪记录查看
// mySalaryMobile 我的薪资福利-移动端
// mySalaryMobile 我的薪资福利-移动端
// mySalary 我的薪资福利
// mySalaryView 我的薪资福利-查看工资单
// socialSecurityBenefits 社保福利
// programme 社保福利方案
// archives 社保福利档案
// standingBook 社保福利台账
// sbofflineComparison 社保福利台账线下对比
// salaryItem 薪资项目管理
// salaryFile 薪资档案
// dataAcquisition 数据采集
// CumDeduct 累计专项附加扣除
// otherDeduct 其他免税扣除
// cumSituation 往期累计情况
// attendance 考勤引用
// specialAddDeduction 专项附件扣除
// ledger 薪资账套
// calculate 薪资核算
// calculateDetail 核算详情
// DoCalcDetail 核算详情页面-新
// CalcView 核算查看页面-新
// OfflineCompare 薪资核算线下对比-新
// placeOnFileDetail 核算归档详情
// compareDetail 线下线上对比
// payroll 工资单发放
// declare 个税申报表
// generateDeclarationDetail 个税单详情
// taxRate 个税税率表
// taxAgent 个税扣缴义务人
// mobilepayroll 移动端工资单
// sysconfig 系統配置
// sysconfig-1 规则配置
// appconfig 应用配置
// fieldManagement 字段管理
// analysisOfSalaryStatistics 薪酬统计分析
// reportView 薪酬报表查看
// externalPersonManage 非系统人员管理
// adjustSalaryManage 档案管理
// supplementaryCalc 补算
// variableSalary 浮动薪酬
const Routes = (
<Route key="hrmSalary" path="hrmSalary" onEnter={getLocaleLabel} component={Layout}>
<Route key="historicalPayroll" path="historicalPayroll" component={HistoricalPayroll}/>

View File

@ -5,7 +5,7 @@
* Date: 2023/4/17
*/
import React, { Component } from "react";
import { WeaLocaleProvider } from "ecCom";
import { WeaAlertPage, WeaLocaleProvider } from "ecCom";
import { Button, Col, Dropdown, Menu, message, Modal, Row } from "antd";
import {
reportStatisticsReportDelete,
@ -14,7 +14,6 @@ import {
} from "../../../apis/statistics";
import "../index.less";
const SubMenu = Menu.SubMenu;
const { getLabel } = WeaLocaleProvider;
class ReportList extends Component {
@ -87,7 +86,9 @@ class ReportList extends Component {
return (
<Row gutter={16} className="reportRow">
{
_.isEmpty(dataSource) ? <div className="empty">{getLabel(111, "暂无数据")}</div> :
_.isEmpty(dataSource) ? <WeaAlertPage icon="icon-coms-blank" iconSize={100}>
<div>暂无数据</div>
</WeaAlertPage> :
_.map(dataSource, it => {
const { reportName, dimension, id, dimensionId, isShare } = it;
return <Col className="gutter-row" span={6} onClick={() => this.handleGoReportView(id)}>

View File

@ -5,15 +5,19 @@
* Date: 2024/3/26
*/
import React, { Component } from "react";
import { toJS } from "mobx";
import { inject, observer } from "mobx-react";
import { WeaTableNew } from "comsMobx";
import { WeaLoadingGlobal, WeaLocaleProvider } from "ecCom";
import { message, Spin } from "antd";
import { toJS } from "mobx";
import { getIframeParentHeight } from "../../../util";
import { sysConfCodeRule } from "../../../apis/ruleconfig";
import CustomTransferDialog from "../../../components/CustomBrowser/components/customTransferDialog";
import { MonthRangePicker } from "../../reportView/components/statisticalMicroSettingsSlide";
import AdvanceInputBtn from "../components/advanceInputBtn";
import SearchPannel from "../components/searchPannel";
import * as API from "../../../apis/statistics";
import cs from "classnames";
import "../index.less";
const WeaTableComx = WeaTableNew.WeaTable;
@ -131,7 +135,7 @@ class SalaryDetails extends Component {
dataSource, pageInfo, selectedRowKeys, showTotalCell, calcDetail: true, tableScrollHeight: 154,
sumRowlistUrl, payload: { ...payload, updateSum },
columns: _.map(columns, (it, idx) => ({
...it,
...it, calcDetail: true,
width: (it.dataIndex === "taxAgent" || it.dataIndex === "salarySob") ? 176 : it.oldWidth,
fixed: (idx === 1 || idx === 0 || idx === 2) ? "left" : "",
ellipsis: true
@ -167,30 +171,39 @@ class SalaryDetails extends Component {
render() {
const { loading, dataSource, transferDialog } = this.state;
const { attendanceStore: { tableStore } } = this.props;
return (
<div className="table-layout"
style={{ height: getIframeParentHeight(".wea-new-top-req-content", dataSource.length, 0) + "px" }}>
<Spin spinning={loading}>
<iframe
style={{ border: 0, width: "100%", height: "100%" }}
// src="http://localhost:7607/#/calcTable"
src="/spa/hrmSalary/hrmSalaryCalculateDetail/index.html#/calcTable"
id="atdTable"
const { attendanceStore: { tableStore }, dateRange, showSearchAd } = this.props;
return (<React.Fragment>
<div className="query-div">
<MonthRangePicker dateRange={dateRange} viewAttr={2} onChange={this.props.onChange}/>
<AdvanceInputBtn onOpenAdvanceSearch={this.props.handleOpenAdvanceSearch}
onAdvanceSearch={this.props.handleAdvanceSearch}/>
</div>
<div className={cs("searchAdvanced-condition-container", { "searchAdvanced-condition-hide": !showSearchAd })}>
<SearchPannel onCancel={this.props.onCancel} onAdSearch={this.props.onAdSearch}/>
</div>
<div className="table-layout"
style={{ height: getIframeParentHeight(".wea-new-top-req-content", dataSource.length, 60) + "px" }}>
<Spin spinning={loading}>
<iframe
style={{ border: 0, width: "100%", height: "100%" }}
// src="http://localhost:7607/#/calcTable"
src="/spa/hrmSalary/hrmSalaryCalculateDetail/index.html#/calcTable"
id="atdTable"
/>
</Spin>
<WeaTableComx
style={{ display: "none" }}
comsWeaTableStore={tableStore}
needScroll={true}
columns={this.getColumns()}
/>
</Spin>
<WeaTableComx
style={{ display: "none" }}
comsWeaTableStore={tableStore}
needScroll={true}
columns={this.getColumns()}
/>
{/*默认显示列*/}
<CustomTransferDialog {...transferDialog} onChange={this.savePageListSetting}
onCancel={() => this.setState({
transferDialog: { ...transferDialog, visible: false, cancel: true }
})}/>
</div>
{/*默认显示列*/}
<CustomTransferDialog {...transferDialog} onChange={this.savePageListSetting}
onCancel={() => this.setState({
transferDialog: { ...transferDialog, visible: false, cancel: true }
})}/>
</div>
</React.Fragment>
);
}
}

View File

@ -19,11 +19,7 @@ import DimensionTable from "./components/dimensionTable";
import ReportList from "./components/reportList";
import ReportForm from "./components/reportForm";
import LogDialog from "../../components/logViewModal";
import { MonthRangePicker } from "../reportView/components/statisticalMicroSettingsSlide";
import AdvanceInputBtn from "./components/advanceInputBtn";
import SearchPannel from "./components/searchPannel";
import moment from "moment";
import cs from "classnames";
import "./index.less";
const { getLabel } = WeaLocaleProvider;
@ -307,11 +303,7 @@ class Index extends Component {
onClick={({ key }) => this.handleExportSalaryList(key)}>
<Menu.Item
key="SELECTED">{getLabel(543715, "导出所选")}</Menu.Item>
</Menu>}>{getLabel(81272, "")}</Dropdown.Button>,
<MonthRangePicker dateRange={dateRange} viewAttr={2}
onChange={v => this.setState({ dateRange: v }, () => this.handleAdvanceSearch())}/>,
<AdvanceInputBtn onOpenAdvanceSearch={this.handleOpenAdvanceSearch}
onAdvanceSearch={this.handleAdvanceSearch}/>
</Menu>}>{getLabel(81272, "")}</Dropdown.Button>
];
let dropMenuDatas = [
{
@ -346,9 +338,6 @@ class Index extends Component {
onChange={selectedKey => this.setState({ selectedKey }, () => this.state.selectedKey === "statistics" && this.initReportFormCondition())}
showDropIcon={selectedKey !== "detail"} onDropMenuClick={this.onDropMenuClick}
dropMenuDatas={dropMenuDatas}>
<div className={cs("searchAdvanced-condition-container", { "searchAdvanced-condition-hide": !showSearchAd })}>
<SearchPannel onCancel={() => this.setState({ showSearchAd: false })} onAdSearch={this.onAdSearch}/>
</div>
{
selectedKey === "statistics" ?
<ReportList
@ -360,7 +349,11 @@ class Index extends Component {
ref={dom => this.employeeListRef = dom}
keyword={keyword} year={year}
onFilterLog={(type, targetid) => this.onDropMenuClick(type, targetid)}
/> : <SalaryDetails ref={dom => this.salaryRef = dom} dateRange={dateRange} isQuery={isQuery}/>
/> : <SalaryDetails ref={dom => this.salaryRef = dom} dateRange={dateRange} isQuery={isQuery}
showSearchAd={showSearchAd} handleOpenAdvanceSearch={this.handleOpenAdvanceSearch}
handleAdvanceSearch={this.handleAdvanceSearch} onAdSearch={this.onAdSearch}
onCancel={() => this.setState({ showSearchAd: false })}
onChange={v => this.setState({ dateRange: v }, () => this.handleAdvanceSearch())}/>
}
<StatisticsModal {...modalReq} onCancel={this.handleCancel} form={reportForm} onClose={this.handleCancel}
onAddDimension={this.handleAddDimension}

View File

@ -15,7 +15,7 @@
}
.wea-new-top-req-content {
padding: 16px;
padding: 8px 16px;
.wea-new-table {
background: #FFF;
@ -158,11 +158,8 @@
}
}
.empty {
font-size: 16px;
width: 100%;
text-align: center;
margin-top: 26px;
.wea-alert-page-con {
padding-top: 100px;
}
}
@ -210,6 +207,20 @@
}
}
.query-div {
display: flex;
align-items: center;
justify-content: flex-end;
height: 46px;
background: #FFF;
margin-bottom: 8px;
padding: 0 8px;
.rangePickerBox {
margin-right: 10px;
}
}
.table-layout {
.ant-spin-nested-loading, .ant-spin-container {
height: 100%;