Merge branch 'release/2.10.1.2401.01' into release/2.10.1.2401.01-个税

# Conflicts:
#	pc4mobx/hrmSalary/pages/ledgerPage/components/ledgerSalaryItemTable.js
This commit is contained in:
黎永顺 2024-02-02 13:55:08 +08:00
commit 0a680cccc2
32 changed files with 322 additions and 86 deletions

View File

@ -6,6 +6,14 @@ import { convertToUrlString } from "../util/url";
export const mySalaryBillList = params => { export const mySalaryBillList = params => {
return postFetch("/api/bs/hrmsalary/salaryBill/mySalaryBillList", params); return postFetch("/api/bs/hrmsalary/salaryBill/mySalaryBillList", params);
}; };
// 人事卡片-工资单列表
export const mySalaryBillList4Card = params => {
return postFetch("/api/bs/hrmsalary/salaryBill/mySalaryBillList4Card", params);
};
// 人事卡片-调薪记录列表
export const mySalaryRecordList4Card = params => {
return WeaTools.callApi("/api/bs/hrmsalary/report/record/list4Card", "GET", params);
};
// 调薪记录列表 // 调薪记录列表
export const recordList = params => { export const recordList = params => {

Binary file not shown.

After

Width:  |  Height:  |  Size: 554 B

View File

@ -40,8 +40,11 @@ class ImpStep2 extends Component {
render() { render() {
const { dataSource, columns, loading } = this.state; const { dataSource, columns, loading } = this.state;
const { scrollHeight } = this.props;
return ( return (
<WeaTable dataSource={dataSource} columns={columns} pagination={false} loading={loading} scroll={{ x: 800 }}/> <WeaTable
dataSource={dataSource} columns={columns} loading={loading} scroll={{ x: 800, y: `${scrollHeight}px` }}
/>
); );
} }
} }

View File

@ -31,7 +31,7 @@ class ImpStep3 extends Component {
</div> </div>
} }
{ {
!_.isEmpty(importResult.errorData) && (!_.isEmpty(importResult.errorNotice) || !_.isEmpty(importResult.errorData)) &&
<WeaTable <WeaTable
columns={[ columns={[
{ {
@ -39,7 +39,7 @@ class ImpStep3 extends Component {
dataIndex: "message" dataIndex: "message"
} }
]} ]}
dataSource={importResult.errorData} pagination={false} dataSource={importResult.errorData || importResult.errorNotice} pagination={false}
scroll={{ y: `calc(100vh - 387px)` }} scroll={{ y: `calc(100vh - 387px)` }}
/> />
} }

View File

@ -36,8 +36,8 @@ class Index extends Component {
} }
renderChildren = () => { renderChildren = () => {
const { current } = this.state; const { current } = this.state, { importParams, link, excludeKey, importResult, exportDataDom = null } = this.props;
const { importParams, link, excludeKey, importResult, exportDataDom = null } = this.props; const scrollHeight = this.importRef ? this.importRef.state.height - 232 : 606.6;
let CurrentDom = null; let CurrentDom = null;
switch (current) { switch (current) {
case 0: case 0:
@ -45,7 +45,7 @@ class Index extends Component {
ref={dom => this.step1Ref = dom}/>; ref={dom => this.step1Ref = dom}/>;
break; break;
case 1: case 1:
CurrentDom = <ImpStep2 {...this.props}/>; CurrentDom = <ImpStep2 {...this.props} scrollHeight={scrollHeight}/>;
if (excludeKey) { if (excludeKey) {
CurrentDom = <ImpStep3 importResult={importResult}/>; CurrentDom = <ImpStep3 importResult={importResult}/>;
} }
@ -128,9 +128,10 @@ class Index extends Component {
loading={this.props.nextloading}>{getLabel(1402, "下一步")}</Button>, loading={this.props.nextloading}>{getLabel(1402, "下一步")}</Button>,
<Button type="primary" onClick={() => this.props.onCancel(true)}>{getLabel(555, "完成")}</Button> <Button type="primary" onClick={() => this.props.onCancel(true)}>{getLabel(555, "完成")}</Button>
]; ];
return ( return (
<WeaDialog <WeaDialog
{...this.props} {...this.props} ref={dom => this.importRef = dom}
scalable hasScroll className="importBox" initLoadCss scalable hasScroll className="importBox" initLoadCss
buttons={current === 0 ? _.nth(btns, 1) : (!this.props.excludeKey && current === 1) ? _.take(btns, 2) : _.takeRight(btns)} buttons={current === 0 ? _.nth(btns, 1) : (!this.props.excludeKey && current === 1) ? _.take(btns, 2) : _.takeRight(btns)}
style={{ style={{

View File

@ -10,7 +10,7 @@ class Content extends Component {
const { onlyOneGrup, showData } = dealTemplate(itemTypeList, "pc"); const { onlyOneGrup, showData } = dealTemplate(itemTypeList, "pc");
return ( return (
<div className="salary-preview-container"> <div className="salary-preview-container">
<div style={{ border: "10px solid #F6F6F6" }}> <div style={{ border: "10px solid #F3F9FF" }}>
<div className="edition-center"> <div className="edition-center">
<div className="header"> <div className="header">
<div className="header-title">{theme || ""}</div> <div className="header-title">{theme || ""}</div>
@ -34,7 +34,10 @@ class Content extends Component {
return ( return (
<div className="salary-group" key={groupId || index}> <div className="salary-group" key={groupId || index}>
{ {
groupName ? <div className="group-title">{groupName}</div> : null groupName ? <div className="group-title">
<img src={require("../../common/titleLogo.png")} alt=""/>
<span>{groupName}</span>
</div> : null
} }
<div className="group-list"> <div className="group-list">
{ {
@ -71,9 +74,9 @@ class Content extends Component {
!onlyOneGrup && tipPosi.toString() === "2" && tip && !onlyOneGrup && tipPosi.toString() === "2" && tip &&
<div className="corporate-culture-text" title={tip} dangerouslySetInnerHTML={{ __html: tip }}/> <div className="corporate-culture-text" title={tip} dangerouslySetInnerHTML={{ __html: tip }}/>
} }
{this.props.children}
</div> </div>
</div> </div>
{this.props.children}
</div> </div>
</div> </div>
); );

View File

@ -4,7 +4,7 @@
overflow-y: auto; overflow-y: auto;
.weapp-salary-sp { .weapp-salary-sp {
background: #f6f6f6; background: #F3F9FF;
} }
.weapp-salary-payroll-pc-preview { .weapp-salary-payroll-pc-preview {
@ -58,6 +58,7 @@
.body { .body {
width: 100%; width: 100%;
background: #FFF;
//margin-top: 32px; //margin-top: 32px;
.comp-img { .comp-img {
@ -69,34 +70,43 @@
} }
.corporate-culture-text { .corporate-culture-text {
width: 100%;
text-align: left; text-align: left;
color: #111; color: #111;
padding: 8px 16px; margin: 16px 30px 20px 30px;
white-space: pre-wrap; white-space: pre-wrap;
word-break: break-all; word-break: break-all;
margin-top: 16px; padding: 10px 14px;
background: #FAFAFA;
border: 1px solid rgba(238, 238, 238, 1);
border-radius: 4px;
} }
.data-detail { .data-detail {
margin-top: 16px;
.salary-group { .salary-group {
margin-bottom: 16px;
padding-bottom: 16px;
background: #FFF; background: #FFF;
.group-title { .group-title {
font-size: 14px; font-size: 14px;
padding: 16px 0 0 8px; padding: 16px 0 0 30px;
font-weight: bolder; font-weight: bolder;
color: #333333;
img {
width: 16px;
height: 20px;
}
span {
vertical-align: middle;
margin-left: 10px;
}
} }
.group-list { .group-list {
margin-top: 16px; margin-top: 16px;
display: flex; display: flex;
flex-wrap: wrap; flex-wrap: wrap;
padding: 0 8px; padding: 0 30px;
.even { .even {
border-left: 1px solid #e5e5e5; border-left: 1px solid #e5e5e5;
@ -125,9 +135,9 @@
background: #fbfbfb; background: #fbfbfb;
border-right: 1px solid #e5e5e5; border-right: 1px solid #e5e5e5;
font-size: 12px; font-size: 12px;
color: #666; color: #5F5F5F;
display: flex; display: flex;
justify-content: center; justify-content: flex-start;
align-items: center; align-items: center;
flex-shrink: 0; flex-shrink: 0;
@ -148,7 +158,7 @@
line-height: 40px; line-height: 40px;
background: #fff; background: #fff;
font-size: 12px; font-size: 12px;
color: #111; color: #5F5F5F;
word-break: break-all; word-break: break-all;
} }
} }
@ -157,4 +167,12 @@
} }
} }
} }
.space {
margin: 20px 0 40px 0 !important;
button:last-child {
margin-right: 30px;
}
}
} }

View File

@ -1,6 +1,8 @@
import React from "react"; import React from "react";
import Route from "react-router/lib/Route"; import Route from "react-router/lib/Route";
import { WeaLocaleProvider } from "ecCom"; import { WeaLocaleProvider } from "ecCom";
import HistoricalPayroll from "./pages/historicalPayroll";
import SalaryAdjustmentRecords from "./pages/salaryAdjustmentRecords";
import MySalaryMobile from "./pages/mySalaryMobile"; import MySalaryMobile from "./pages/mySalaryMobile";
import MySalary from "./pages/mySalaryBenefits"; import MySalary from "./pages/mySalaryBenefits";
import Programme from "./pages/socialSecurityBenefits/programme"; import Programme from "./pages/socialSecurityBenefits/programme";
@ -75,6 +77,10 @@ const Home = (props) => props.children;
const SocialSecurityBenefits = (props) => props.children; const SocialSecurityBenefits = (props) => props.children;
const DataAcquisition = (props) => props.children; const DataAcquisition = (props) => props.children;
// historicalPayroll 历史工资单查看
// salaryAdjustmentRecords 调薪记录查看
// mySalaryMobile 我的薪资福利-移动端
// mySalaryMobile 我的薪资福利-移动端 // mySalaryMobile 我的薪资福利-移动端
// mySalary 我的薪资福利 // mySalary 我的薪资福利
// mySalaryView 我的薪资福利-查看工资单 // mySalaryView 我的薪资福利-查看工资单
@ -123,6 +129,8 @@ const Routes = (
path="hrmSalary" path="hrmSalary"
onEnter={getLocaleLabel} onEnter={getLocaleLabel}
component={Home}> component={Home}>
<Route key="historicalPayroll" path="historicalPayroll" component={HistoricalPayroll}/>
<Route key="salaryAdjustmentRecords" path="salaryAdjustmentRecords" component={SalaryAdjustmentRecords}/>
<Route key="mySalaryMobile" path="mySalaryMobile" component={MySalaryMobile}/> <Route key="mySalaryMobile" path="mySalaryMobile" component={MySalaryMobile}/>
<Route key="mySalary" path="mySalary" component={MySalary}/> <Route key="mySalary" path="mySalary" component={MySalary}/>
<Route key="mySalaryView" path="mySalary/:salaryInfoId" component={MySalaryView}/> <Route key="mySalaryView" path="mySalary/:salaryInfoId" component={MySalaryView}/>

View File

@ -97,6 +97,7 @@
flex-direction: column; flex-direction: column;
justify-content: space-between; justify-content: space-between;
margin-left: 10px; margin-left: 10px;
overflow: hidden;
.reportName { .reportName {
font-size: 14px; font-size: 14px;

View File

@ -0,0 +1,43 @@
/*
* Author: 黎永顺
* name:历史工资单
* Description:
* Date: 2024/1/25
*/
import React, { Component } from "react";
import { WeaLocaleProvider, WeaTools } from "ecCom";
import { MonthRangePicker } from "../reportView/components/statisticalMicroSettingsSlide";
import Payroll from "../mySalaryBenefits/components/payrollTable";
import moment from "moment";
import "./index.less";
const getLabel = WeaLocaleProvider.getLabel;
class Index extends Component {
constructor(props) {
super(props);
this.state = {
dateRange: [
moment(new Date()).subtract(1, "year").startOf("year").format("YYYY-MM"),
moment(new Date()).endOf("year").format("YYYY-MM")
]
};
}
render() {
const { dateRange } = this.state;
const employeeId = WeaTools.getUrlParams().hrmResourceID;
return (
<div className="history-payroll-box">
<div className="topQuery">
<span className="title">{getLabel(542604, "薪资所属月")}</span>
<MonthRangePicker dateRange={dateRange} viewAttr={2}
onChange={v => this.setState({ dateRange: v })}/>
</div>
<Payroll salaryYearMonth={dateRange} type="mySalaryBillList4Card" employeeId={employeeId}/>
</div>
);
}
}
export default Index;

View File

@ -0,0 +1,23 @@
.history-payroll-box {
width: 100%;
height: 100%;
background: #f6f6f6;
padding: 16px;
.topQuery {
width: 100%;
background: #fff;
padding: 16px;
margin-bottom: 16px;
display: flex;
align-items: center;
.title {
margin-right: 10px;
}
}
.wea-new-table {
background: #fff;
}
}

View File

@ -159,9 +159,9 @@ export default class MobilePayroll extends React.Component {
if (status) { if (status) {
const { mySalaryBillData } = this.state; const { mySalaryBillData } = this.state;
const { salaryTemplate } = mySalaryBillData; const { salaryTemplate } = mySalaryBillData;
const { feedbackUrl } = salaryTemplate; const { feedbackUrl, mobileFeedbackUrl } = salaryTemplate;
this.getMySalaryBill(getQueryString("id")); this.getMySalaryBill(getQueryString("id"));
window.location.href = `${window.ecologyContentPath || ""}${feedbackUrl}`; window.location.href = `${window.ecologyContentPath || ""}${getQueryString("type") === "phone" ? mobileFeedbackUrl : feedbackUrl}`;
// window.open(`${window.ecologyContentPath || ""}${feedbackUrl}`); // window.open(`${window.ecologyContentPath || ""}${feedbackUrl}`);
} else { } else {
message.error(errorMsg); message.error(errorMsg);

View File

@ -30,8 +30,10 @@
.salary-preview-container { .salary-preview-container {
max-width: 1000px; max-width: 1000px;
margin: 0 auto; margin: 0 auto;
border: 2px solid #FFF; border: 1px solid rgba(229,229,229,1);
padding-top: 32px; padding-top: 32px;
background: #F3F9FF;
border-radius: 4px;
} }
.space { .space {

View File

@ -8,9 +8,12 @@ import React, { Component } from "react";
import { inject, observer } from "mobx-react"; import { inject, observer } from "mobx-react";
import { WeaLocaleProvider, WeaTable } from "ecCom"; import { WeaLocaleProvider, WeaTable } from "ecCom";
import Authority from "../../../mySalary/authority"; import Authority from "../../../mySalary/authority";
import { recordList } from "../../../../apis/mySalaryBenefits"; import { mySalaryRecordList4Card, recordList } from "../../../../apis/mySalaryBenefits";
const getLabel = WeaLocaleProvider.getLabel; const getLabel = WeaLocaleProvider.getLabel;
const API = {
recordList, mySalaryRecordList4Card
};
@inject("mySalaryStore") @inject("mySalaryStore")
@observer @observer
@ -24,14 +27,18 @@ class Index extends Component {
} }
componentDidMount() { componentDidMount() {
const { mySalaryStore: { initRecordData } } = this.props; const { mySalaryStore: { initRecordData, getRecordData }, type } = this.props;
initRecordData(this.getRecordList); !type ? initRecordData(this.getRecordList) : getRecordData({
status: "1", token: "",
callback: () => this.getRecordList()
});
} }
getRecordList = () => { getRecordList = () => {
const { pageInfo } = this.state; const { pageInfo } = this.state;
const { employeeId, type = "recordList" } = this.props;
this.setState({ loading: true }); this.setState({ loading: true });
recordList({ ...pageInfo }).then(({ status, data }) => { API[type]({ ...pageInfo, employeeId }).then(({ status, data }) => {
this.setState({ loading: false }); this.setState({ loading: false });
if (status) { if (status) {
const { columns, list: dataSource, pageNum: current, pageSize, total } = data; const { columns, list: dataSource, pageNum: current, pageSize, total } = data;

View File

@ -6,17 +6,20 @@
*/ */
import React, { Component } from "react"; import React, { Component } from "react";
import { WeaLocaleProvider, WeaTable } from "ecCom"; import { WeaLocaleProvider, WeaTable } from "ecCom";
import { mySalaryBillList } from "../../../../apis/mySalaryBenefits"; import { mySalaryBillList, mySalaryBillList4Card } from "../../../../apis/mySalaryBenefits";
import moment from "moment"; import moment from "moment";
const getLabel = WeaLocaleProvider.getLabel; const getLabel = WeaLocaleProvider.getLabel;
const API = {
mySalaryBillList, mySalaryBillList4Card
};
class Index extends Component { class Index extends Component {
constructor(props) { constructor(props) {
super(props); super(props);
this.state = { this.state = {
juniorMapList: [], dataSource: [], columns: [], pageInfo: { current: 1, pageSize: 10, total: 0 }, dataSource: [], columns: [], pageInfo: { current: 1, pageSize: 10, total: 0 },
loading: false, employeeId: "" loading: false
}; };
} }
@ -30,9 +33,9 @@ class Index extends Component {
getMySalaryBillList = (props) => { getMySalaryBillList = (props) => {
this.setState({ loading: true }); this.setState({ loading: true });
const { pageInfo, employeeId } = this.state; const { pageInfo } = this.state;
const { salaryYearMonth } = props; const { salaryYearMonth, employeeId, type = "mySalaryBillList" } = props;
mySalaryBillList({ salaryYearMonth, employeeId, ...pageInfo }).then(({ status, data }) => { API[type]({ salaryYearMonth, employeeId, ...pageInfo }).then(({ status, data }) => {
this.setState({ loading: false }); this.setState({ loading: false });
if (status) { if (status) {
const { columns, datas: dataSource, pageInfo: { pageNum: current, pageSize, total } } = data; const { columns, datas: dataSource, pageInfo: { pageNum: current, pageSize, total } } = data;
@ -55,7 +58,7 @@ class Index extends Component {
}; };
render() { render() {
const { juniorMapList, dataSource, loading, columns, pageInfo } = this.state; const { dataSource, loading, columns, pageInfo } = this.state;
const pagination = { const pagination = {
...pageInfo, ...pageInfo,
showTotal: total => `${getLabel(18609, "共")} ${total} ${getLabel(18256, "条")}`, showTotal: total => `${getLabel(18609, "共")} ${total} ${getLabel(18256, "条")}`,

View File

@ -131,6 +131,7 @@ class SalaryItemSettings extends Component {
salarySobId: this.props.salarySobId, salarySobId: this.props.salarySobId,
existSalaryItemIds: _.map(record.items, it => it.id), existSalaryItemIds: _.map(record.items, it => it.id),
groupId: record.groupId, groupId: record.groupId,
groupName: record.groupName,
isReplenish: this.props.isReplenish isReplenish: this.props.isReplenish
}; };
getAvailableSalaryItemSet(payload).then(({ status, data }) => { getAvailableSalaryItemSet(payload).then(({ status, data }) => {

View File

@ -35,7 +35,8 @@ class TemplateBaseSettings extends Component {
ackFeedbackSetting: { ackFeedbackSetting: {
ackStatus: "0", ackStatus: "0",
autoAckDays: 7, autoAckDays: 7,
feedBackUrl: "" feedBackUrl: "",
mobileFeedbackUrl: ""
}, },
salaryBillViewingLimitSetting: { salaryBillViewingLimitSetting: {
limitMonth: 0 limitMonth: 0
@ -68,8 +69,8 @@ class TemplateBaseSettings extends Component {
}; };
salaryBillBaseSetSave = () => { salaryBillBaseSetSave = () => {
const { watermark, watermarkStatus, wmSetting, ackFeedbackSetting, salaryBillViewingLimitSetting } = this.state; const { watermark, watermarkStatus, wmSetting, ackFeedbackSetting, salaryBillViewingLimitSetting } = this.state;
const { feedBackUrl } = ackFeedbackSetting; const { feedBackUrl, mobileFeedbackUrl } = ackFeedbackSetting;
if (!feedBackUrl) { if (!feedBackUrl || !mobileFeedbackUrl) {
Modal.warning({ Modal.warning({
title: getLabel(111, "信息确认"), title: getLabel(111, "信息确认"),
content: getLabel(111, "必要信息不完整,红色*为必填项!") content: getLabel(111, "必要信息不完整,红色*为必填项!")
@ -96,7 +97,7 @@ class TemplateBaseSettings extends Component {
render() { render() {
const { watermarkStatus, watermark, watermarkSet, ackFeedbackSetting, salaryBillViewingLimitSetting } = this.state; const { watermarkStatus, watermark, watermarkSet, ackFeedbackSetting, salaryBillViewingLimitSetting } = this.state;
const { ackStatus, autoAckDays, feedBackUrl } = ackFeedbackSetting; const { ackStatus, autoAckDays, feedBackUrl, mobileFeedbackUrl } = ackFeedbackSetting;
const { limitMonth = 0 } = salaryBillViewingLimitSetting; const { limitMonth = 0 } = salaryBillViewingLimitSetting;
return ( return (
<React.Fragment> <React.Fragment>
@ -158,7 +159,7 @@ class TemplateBaseSettings extends Component {
style={{ marginLeft: 10 }} style={{ marginLeft: 10 }}
placement="top" width={200}/> placement="top" width={200}/>
</WeaFormItem> </WeaFormItem>
<WeaFormItem label={getLabel(111, "反馈流程地址")} labelCol={{ span: 2 }} wrapperCol={{ span: 4 }}> <WeaFormItem label={getLabel(111, "PC端反馈流程地址")} labelCol={{ span: 2 }} wrapperCol={{ span: 4 }}>
<WeaInput <WeaInput
value={feedBackUrl} viewAttr={3} value={feedBackUrl} viewAttr={3}
onChange={feedBackUrl => this.setState({ onChange={feedBackUrl => this.setState({
@ -167,6 +168,15 @@ class TemplateBaseSettings extends Component {
} }
})}/> })}/>
</WeaFormItem> </WeaFormItem>
<WeaFormItem label={getLabel(111, "移动端反馈流程地址")} labelCol={{ span: 2 }} wrapperCol={{ span: 4 }}>
<WeaInput
value={mobileFeedbackUrl} viewAttr={3}
onChange={mobileFeedbackUrl => this.setState({
ackFeedbackSetting: {
...ackFeedbackSetting, mobileFeedbackUrl
}
})}/>
</WeaFormItem>
</React.Fragment> </React.Fragment>
} }
</WeaSearchGroup> </WeaSearchGroup>

View File

@ -36,7 +36,7 @@ class Index extends Component {
importType: "", listType: importType importType: "", listType: importType
}; };
payload = { payload = {
importType: "", listType: importType, importType: "", listType: importType, hasData: false,
...salaryFileQueryForm.getFormParams() ...salaryFileQueryForm.getFormParams()
}; };
} else { } else {
@ -44,7 +44,7 @@ class Index extends Component {
importType: importType, listType: "FIXED" importType: importType, listType: "FIXED"
}; };
payload = { payload = {
importType: importType, listType: "FIXED", importType: importType, listType: "FIXED", hasData: false,
...salaryFileQueryForm.getFormParams() ...salaryFileQueryForm.getFormParams()
}; };
} }

View File

@ -100,12 +100,12 @@ class Index extends Component {
case "CHANGE-SALARY": case "CHANGE-SALARY":
case "VIEW": case "VIEW":
case "EDIT": case "EDIT":
const { taxAgentStore: { showOperateBtn } } = this.props; const { taxAgentStore: { showOperateBtn }, selectedKey: runStatuses } = this.props;
const { record: { id: salaryArchiveId } } = params; const { record: { id: salaryArchiveId } } = params;
this.setState({ this.setState({
salaryFilesEditSlide: { salaryFilesEditSlide: {
...this.state.salaryFilesEditSlide, visible: true, salaryArchiveId, ...this.state.salaryFilesEditSlide, visible: true, salaryArchiveId,
runStatuses: this.props.selectedKey, showOperateBtn runStatuses, showOperateBtn
} }
}); });
break; break;
@ -172,7 +172,7 @@ class Index extends Component {
const columns = _.map(_.filter(toJS(tableStore.columns), (item) => item.display === "true"), (it, idx) => ({ const columns = _.map(_.filter(toJS(tableStore.columns), (item) => item.display === "true"), (it, idx) => ({
dataIndex: it.dataIndex, title: it.title, align: "left", dataIndex: it.dataIndex, title: it.title, align: "left",
width: (it.dataIndex === "taxAgentName" || it.dataIndex === "operate") ? 185 : 150, width: (it.dataIndex === "taxAgentName" || it.dataIndex === "operate") ? 185 : 150,
fixed: it.dataIndex === "username" ? "left" : it.dataIndex === "operate" ? "right" : "", fixed: it.dataIndex === "username" ? "left" : it.dataIndex === "operate" ? "right" : it.fixed ? it.fixed : false,
ellipsis: true ellipsis: true
})); }));
if (!_.isEmpty(columns)) { if (!_.isEmpty(columns)) {

View File

@ -112,7 +112,8 @@ class Index extends Component {
if (salaryForm.isValid) { if (salaryForm.isValid) {
const { payStartDate, payEndDate, ...extraParams } = salaryForm.getFormParams(); const { payStartDate, payEndDate, ...extraParams } = salaryForm.getFormParams();
const payload = { const payload = {
salaryArchiveId, status: _.toUpper(runStatuses), //status-非系统人员保存与定薪人员一样
salaryArchiveId, status: _.toUpper(runStatuses === "ext" ? "fixed" : runStatuses),
payStartDate, payEndDate, payStartDate, payEndDate,
salaryArchiveItems: _.map(salaryArchiveItems, o => ({ salaryArchiveItems: _.map(salaryArchiveItems, o => ({
salaryItemId: o.salaryItemId, salaryItemId: o.salaryItemId,
@ -152,7 +153,7 @@ class Index extends Component {
}}>{getLabel(543310, "发起调薪")}</Button> }}>{getLabel(543310, "发起调薪")}</Button>
} }
{ {
runStatuses === "fixed" && showOperateBtn && (runStatuses === "fixed" || runStatuses === "ext") && showOperateBtn &&
<Button type="ghost" onClick={() => { <Button type="ghost" onClick={() => {
this.setState({ this.setState({
adjLogRecordDialog: { adjLogRecordDialog: {

View File

@ -7,11 +7,24 @@ export const copyConditions = [
domkey: ["name"], domkey: ["name"],
fieldcol: 14, fieldcol: 14,
label: "工资单名称", label: "工资单名称",
lanId: 536726, lanId: 543600,
labelcol: 6, labelcol: 6,
value: "", value: "",
rules: "required|string", rules: "required|string",
viewAttr: 3 viewAttr: 3
},
{
colSpan: 1,
conditionType: "SELECT",
domkey: ["salarySobId"],
fieldcol: 14,
label: "薪资账套",
lanId: 538010,
labelcol: 6,
value: "",
options: [],
rules: "required|string",
viewAttr: 3
} }
], ],
defaultshow: true, defaultshow: true,
@ -194,8 +207,21 @@ export const tempBaseSetFbConditions = [
conditionType: "INPUT", conditionType: "INPUT",
domkey: ["feedbackUrl"], domkey: ["feedbackUrl"],
fieldcol: 14, fieldcol: 14,
label: "反馈流程地址", label: "PC端反馈流程地址",
lanId: 544096, lanId: 111,
labelcol: 6,
value: "/",
viewAttr: 3,
hide: false,
rules: "required|string"
},
{
colSpan: 1,
conditionType: "INPUT",
domkey: ["mobileFeedbackUrl"],
fieldcol: 14,
label: "移动端反馈流程地址",
lanId: 111,
labelcol: 6, labelcol: 6,
value: "/", value: "/",
viewAttr: 3, viewAttr: 3,

View File

@ -6,13 +6,14 @@
*/ */
import React, { Component } from "react"; import React, { Component } from "react";
import { inject, observer } from "mobx-react"; import { inject, observer } from "mobx-react";
import { WeaDialog, WeaLocaleProvider } from "ecCom"; import { WeaDialog, WeaLocaleProvider, WeaTools } from "ecCom";
import { Button, message } from "antd"; import { Button, message } from "antd";
import { getSearchs } from "../../../../util"; import { getSearchs } from "../../../../util";
import { copyConditions } from "../conditions"; import { copyConditions } from "../conditions";
import { duplicatePayroll } from "../../../../apis/payroll"; import { duplicatePayroll, getPayrollTemplateLedgerList } from "../../../../apis/payroll";
const getLabel = WeaLocaleProvider.getLabel; const getLabel = WeaLocaleProvider.getLabel;
const getKey = WeaTools.getKey;
@inject("payrollStore") @inject("payrollStore")
@observer @observer
@ -20,15 +21,41 @@ class Index extends Component {
constructor(props) { constructor(props) {
super(props); super(props);
this.state = { this.state = {
loading: false loading: false, conditions: []
}; };
} }
componentWillReceiveProps(nextProps, nextContext) { componentWillReceiveProps(nextProps, nextContext) {
if (nextProps.visible !== this.props.visible && nextProps.visible) nextProps.payrollStore.payrollCopyForm.initFormFields(copyConditions); if (nextProps.visible !== this.props.visible && nextProps.visible) this.getPayrollTemplateLedgerList(nextProps);
if (nextProps.visible !== this.props.visible && !nextProps.visible) nextProps.payrollStore.initPayrollCopyForm(); if (nextProps.visible !== this.props.visible && !nextProps.visible) nextProps.payrollStore.initPayrollCopyForm();
} }
getPayrollTemplateLedgerList = (props) => {
getPayrollTemplateLedgerList().then(({ status, data }) => {
if (status) {
this.setState({
conditions: _.map(copyConditions, item => {
return {
...item, items: _.map(item.items, o => {
if (getKey(o) === "salarySobId") {
return {
...o, label: getLabel(o.lanId, o.label),
options: _.map(data, d => ({ key: d.id, showname: d.content }))
};
} else {
return { ...o, label: getLabel(o.lanId, o.label) };
}
})
};
})
}, () => {
props.payrollStore.payrollCopyForm.initFormFields(this.state.conditions);
props.payrollStore.payrollCopyForm.updateFields({ salarySobId: { value: props.salarySobId } });
});
}
});
};
save = () => { save = () => {
const { payrollStore: { payrollCopyForm }, copyId: id } = this.props; const { payrollStore: { payrollCopyForm }, copyId: id } = this.props;
payrollCopyForm.validateForm().then(f => { payrollCopyForm.validateForm().then(f => {
@ -51,16 +78,16 @@ class Index extends Component {
}; };
render() { render() {
const { loading } = this.state; const { loading, conditions } = this.state;
const { payrollStore: { payrollCopyForm } } = this.props; const { payrollStore: { payrollCopyForm } } = this.props;
return ( return (
<WeaDialog <WeaDialog
{...this.props} style={{ width: 480 }} initLoadCss {...this.props} style={{ width: 480, height: 127 }} initLoadCss
buttons={[ buttons={[
<Button type="primary" onClick={this.save} loading={loading}>{getLabel(537558, "保存")}</Button> <Button type="primary" onClick={this.save} loading={loading}>{getLabel(537558, "保存")}</Button>
]} ]}
> >
<div className="payroll-dialog-layout">{getSearchs(payrollCopyForm, copyConditions, 1, false)}</div> <div className="payroll-dialog-layout">{getSearchs(payrollCopyForm, conditions, 1, false)}</div>
</WeaDialog> </WeaDialog>
); );
} }

View File

@ -129,7 +129,7 @@ class Index extends Component {
hide: _.isNil(fieldsEchoData["ackFeedbackStatus"]) ? o.hide : !fieldsEchoData["ackFeedbackStatus"], hide: _.isNil(fieldsEchoData["ackFeedbackStatus"]) ? o.hide : !fieldsEchoData["ackFeedbackStatus"],
helpfulTitle: getLabel(544273, "开启后,还需在计划任务中配置定时任务,执行自动确认任务;邮箱端查看工资单暂不支持确认及反馈;") helpfulTitle: getLabel(544273, "开启后,还需在计划任务中配置定时任务,执行自动确认任务;邮箱端查看工资单暂不支持确认及反馈;")
}; };
} else if (getKey(o) === "feedbackUrl") { } else if (getKey(o) === "feedbackUrl" || getKey(o) === "mobileFeedbackUrl") {
return { return {
...o, ...o,
hide: _.isNil(fieldsEchoData["ackFeedbackStatus"]) ? o.hide : !fieldsEchoData["ackFeedbackStatus"] hide: _.isNil(fieldsEchoData["ackFeedbackStatus"]) ? o.hide : !fieldsEchoData["ackFeedbackStatus"]
@ -298,7 +298,7 @@ class Index extends Component {
if (it.title === getLabel(544092, "工资单确认反馈设置")) { if (it.title === getLabel(544092, "工资单确认反馈设置")) {
return { return {
...it, items: _.map(it.items, o => { ...it, items: _.map(it.items, o => {
if (getKey(o) === "autoAckDays" || getKey(o) === "feedbackUrl") { if (getKey(o) === "autoAckDays" || getKey(o) === "feedbackUrl" || getKey(o) === "mobileFeedbackUrl") {
return { return {
...o, hide: params[key].value === "0" ...o, hide: params[key].value === "0"
}; };
@ -312,7 +312,11 @@ class Index extends Component {
}, () => { }, () => {
payrollTempFeedbackForm.initFormFields(this.state.fbConditions); payrollTempFeedbackForm.initFormFields(this.state.fbConditions);
const ackFeedbackStatus = payrollTempFeedbackForm.getFormParams().ackFeedbackStatus; const ackFeedbackStatus = payrollTempFeedbackForm.getFormParams().ackFeedbackStatus;
if (ackFeedbackStatus === "0") payrollTempFeedbackForm.updateFields({ autoAckDays: "7", feedbackUrl: "/" }); if (ackFeedbackStatus === "0") payrollTempFeedbackForm.updateFields({
autoAckDays: "7",
feedbackUrl: "/",
mobileFeedbackUrl: "/"
});
}); });
} }
setHasBeenModify(true); setHasBeenModify(true);

View File

@ -22,7 +22,7 @@ class Index extends Component {
this.state = { this.state = {
loading: false, columns: [], dataSource: [], selectedRowKeys: [], loading: false, columns: [], dataSource: [], selectedRowKeys: [],
pageInfo: { current: 1, pageSize: 10, total: 0 }, delLoading: false, pageInfo: { current: 1, pageSize: 10, total: 0 }, delLoading: false,
copyDialog: { visible: false, title: "", copyId: "" }, copyDialog: { visible: false, title: "", copyId: "", salarySobId: "" },
tmplSlide: { tmplSlide: {
visible: false, tmplId: "", top: 0, width: 792, height: 100, visible: false, tmplId: "", top: 0, width: 792, height: 100,
measureT: "%", measureX: "px", measureY: "%" measureT: "%", measureX: "px", measureY: "%"
@ -80,7 +80,7 @@ class Index extends Component {
}; };
handleOpts = ({ key }, record) => { handleOpts = ({ key }, record) => {
const { copyDialog, tmplSlide, selectedRowKeys } = this.state; const { copyDialog, tmplSlide, selectedRowKeys } = this.state;
const { id } = record; const { id, salarySobId } = record;
switch (key) { switch (key) {
case "edit": case "edit":
this.setState({ this.setState({
@ -89,7 +89,10 @@ class Index extends Component {
break; break;
case "copy": case "copy":
this.setState({ this.setState({
copyDialog: { ...copyDialog, visible: true, copyId: id, title: getLabel(543599, "复制工资单") } copyDialog: {
...copyDialog, visible: true, copyId: id,
salarySobId: salarySobId + "", title: getLabel(543599, "复制工资单")
}
}); });
break; break;
case "del": case "del":
@ -175,7 +178,7 @@ class Index extends Component {
{/*复制工资单模板*/} {/*复制工资单模板*/}
<PayrollCopyDialog {...copyDialog} <PayrollCopyDialog {...copyDialog}
onCancel={v => this.setState({ onCancel={v => this.setState({
copyDialog: { ...copyDialog, visible: false, copyId: "" } copyDialog: { ...copyDialog, visible: false, copyId: "", salarySobId: "" }
}, () => v === "refresh" && this.getPayrollTemplateList(this.props))} }, () => v === "refresh" && this.getPayrollTemplateList(this.props))}
/> />
{/* 新建编辑工资单模板*/} {/* 新建编辑工资单模板*/}

View File

@ -0,0 +1,25 @@
/*
* Author: 黎永顺
* name:调薪记录
* Description:
* Date: 2024/1/25
*/
import React, { Component } from "react";
import { WeaLocaleProvider, WeaTools } from "ecCom";
import SalaryAdjustmentRecords from "../mySalaryBenefits/components/SalaryAdjustmentRecords";
import "../historicalPayroll/index.less";
const getLabel = WeaLocaleProvider.getLabel;
class Index extends Component {
render() {
const employeeId = WeaTools.getUrlParams().hrmResourceID;
return (
<div className="history-payroll-box">
<SalaryAdjustmentRecords type="mySalaryRecordList4Card" employeeId={employeeId}/>
</div>
);
}
}
export default Index;

View File

@ -83,7 +83,7 @@ export default class SalaryItemChangeList extends React.Component {
} }
return { ...o, width, render: text => (<span title={text}>{text}</span>) }; return { ...o, width, render: text => (<span title={text}>{text}</span>) };
}); });
if (showOperateBtn && selectedKey === "fixed") { if (showOperateBtn && (selectedKey === "fixed" || selectedKey === "ext")) {
columns = [...columns, { columns = [...columns, {
dataIndex: "operate", fixed: "right", width: 120, title: "操作", dataIndex: "operate", fixed: "right", width: 120, title: "操作",
render: (text, record) => { render: (text, record) => {

View File

@ -1,5 +1,5 @@
import React from "react"; import React from "react";
import { WeaHelpfulTip, WeaInputNumber, WeaSelect, WeaTab, WeaTable } from "ecCom"; import { WeaHelpfulTip, WeaInputNumber, WeaSelect, WeaTab } from "ecCom";
import { Switch, Table } from "antd"; import { Switch, Table } from "antd";
import { insertUpdateColumns } from "./columns"; import { insertUpdateColumns } from "./columns";
import { inject, observer } from "mobx-react"; import { inject, observer } from "mobx-react";
@ -114,7 +114,13 @@ export default class DefaultSlideForm extends React.Component {
const { programmeStore, requestParams, onChange } = this.props; const { programmeStore, requestParams, onChange } = this.props;
const { defaultPersonDataSource, defaultCompanyDataSource } = programmeStore; const { defaultPersonDataSource, defaultCompanyDataSource } = programmeStore;
insertUpdateColumns.map(item => { insertUpdateColumns.map(item => {
if (item.dataIndex == "isPayment") { if (item.dataIndex == "insuranceName") {
item.render = (text) => {
return (
<div style={{ maxWidth: 100 }} className="ellipsis" title={text}>{text}</div>
);
};
} else if (item.dataIndex == "isPayment") {
item.render = (text, record) => { item.render = (text, record) => {
return ( return (
<Switch <Switch
@ -320,7 +326,7 @@ export default class DefaultSlideForm extends React.Component {
item.render = (text, record) => { item.render = (text, record) => {
if (record.paymentCycle === "0") { if (record.paymentCycle === "0") {
return ( return (
<div>基数*比例+固定费用</div> <div style={{ maxWidth: 180 }} className="ellipsis">基数*比例+固定费用</div>
); );
} else { } else {
return ( return (

View File

@ -23,6 +23,12 @@
.tableWrapper { .tableWrapper {
margin-top: 10px; margin-top: 10px;
.ellipsis {
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.ant-table-fixed-left { .ant-table-fixed-left {
tr { tr {
height: 63px !important; height: 63px !important;

View File

@ -24,8 +24,8 @@ export default class StandingBook extends React.Component {
value: "", value: "",
selectedKey: "0", selectedKey: "0",
tableParams: { tableParams: {
startTime: moment(new Date()).startOf("year").format("YYYY-MM"), startTime: moment(new Date()).subtract(1, 'year').startOf("year").format("YYYY-MM"),
endTime: moment(new Date()).startOf("month").format("YYYY-MM"), endTime: moment(new Date()).endOf("year").format("YYYY-MM"),
paymentOrganization: "" paymentOrganization: ""
}, },
current: 1, current: 1,

View File

@ -9,6 +9,7 @@ import { inject, observer } from "mobx-react";
import { WeaLocaleProvider, WeaSlideModal, WeaTools } from "ecCom"; import { WeaLocaleProvider, WeaSlideModal, WeaTools } from "ecCom";
import * as API from "../../../../../apis/welfareArchive"; import * as API from "../../../../../apis/welfareArchive";
import { getTaxAgentSelectList } from "../../../../../apis/taxAgent"; import { getTaxAgentSelectList } from "../../../../../apis/taxAgent";
import { sysinfo } from "../../../../../apis/ruleconfig";
import { getWelfareSearchsForm, welfareConditions } from "../../config"; import { getWelfareSearchsForm, welfareConditions } from "../../config";
import { getConditionDomkeys, toDecimal_n } from "../../../../../util"; import { getConditionDomkeys, toDecimal_n } from "../../../../../util";
import { Button, message, Modal } from "antd"; import { Button, message, Modal } from "antd";
@ -38,34 +39,34 @@ class Index extends Component {
} }
getBaseForm = async (props) => { getBaseForm = async (props) => {
const { data: taxAgentList } = await getTaxAgentSelectList(); const [taxAgentListData, sysInfoData] = await Promise.all([getTaxAgentSelectList(), sysinfo()]);
const { const {
archivesStore: { welfareProfileForm }, socialBase, fundBase, otherBase, runStatuses, archivesStore: { welfareProfileForm }, socialBase, fundBase, otherBase, runStatuses,
employeeId, paymentOrganization, socialBaseData, fundBaseData, othersBaseData, employeeId, paymentOrganization, socialBaseData, fundBaseData, othersBaseData,
showOperateBtn showOperateBtn
} = props; } = props;
let socialComData = {}, fundComData = {}, otherComData = {}; let socialComData = {}, fundComData = {}, otherComData = {};
if (!_.isNil(socialBase.comItems) && !_.isNil(socialBase.comData)) { if (!_.isNil(socialBase.comItems)) {
_.forEach(getConditionDomkeys(socialBase.comItems), o => { _.forEach(getConditionDomkeys(socialBase.comItems), o => {
socialComData = { socialComData = {
...socialComData, ...socialComData,
[`${o}_com`]: socialBase.comData[o] [`${o}_com`]: !_.isNil(socialBase.comData) ? socialBase.comData[o] : _.find(socialBase.comItems[0].items, k => getKey(k) === o).min
}; };
}); });
} }
if (!_.isNil(fundBase.comItems) && !_.isNil(fundBase.comData)) { if (!_.isNil(fundBase.comItems)) {
_.forEach(getConditionDomkeys(fundBase.comItems), o => { _.forEach(getConditionDomkeys(fundBase.comItems), o => {
fundComData = { fundComData = {
...fundComData, ...fundComData,
[`${o}_com`]: fundBase.comData[o] [`${o}_com`]: !_.isNil(fundBase.comData) ? fundBase.comData[o] : _.find(fundBase.comItems[0].items, k => getKey(k) === o).min
}; };
}); });
} }
if (!_.isNil(otherBase.comItems) && !_.isNil(otherBase.comData)) { if (!_.isNil(otherBase.comItems)) {
_.forEach(getConditionDomkeys(otherBase.comItems), o => { _.forEach(getConditionDomkeys(otherBase.comItems), o => {
otherComData = { otherComData = {
...otherComData, ...otherComData,
[`${o}_com`]: otherBase.comData[o] [`${o}_com`]: !_.isNil(otherBase.comData) ? otherBase.comData[o] : _.find(otherBase.comItems[0].items, k => getKey(k) === o).min
}; };
}); });
} }
@ -76,7 +77,8 @@ class Index extends Component {
const formData = { const formData = {
...result, ...socialBaseData, ...fundBaseData, ...othersBaseData, ...result, ...socialBaseData, ...fundBaseData, ...othersBaseData,
...socialBase.data, ...fundBase.data, ...otherBase.data, ...socialBase.data, ...fundBase.data, ...otherBase.data,
...socialComData, ...fundComData, ...otherComData ...socialComData, ...fundComData, ...otherComData,
welBaseAutoAdjust: sysInfoData.data.welBaseAutoAdjust === "1"
}; };
this.setState({ this.setState({
formData, formData,
@ -95,7 +97,7 @@ class Index extends Component {
items: _.map(o.items, g => { items: _.map(o.items, g => {
return { return {
...g, label: getLabel(g.lanId, g.label), ...g, label: getLabel(g.lanId, g.label),
options: _.map(taxAgentList, j => ({ key: j.id, showname: j.content })) options: _.map(taxAgentListData.data, j => ({ key: j.id, showname: j.content }))
}; };
}) })
}; };
@ -111,6 +113,11 @@ class Index extends Component {
viewAttr: (runStatuses === "4,5" || !showOperateBtn) ? 1 : g.viewAttr, viewAttr: (runStatuses === "4,5" || !showOperateBtn) ? 1 : g.viewAttr,
options: _.find(props[`${o.title}Items`], j => j.domkey[0] === key).options options: _.find(props[`${o.title}Items`], j => j.domkey[0] === key).options
}; };
} else if (getKey(g).indexOf("StartTime") !== -1) {
return {
...g, label: getLabel(g.lanId, g.label),
viewAttr: (formData[o["typename"]][`${o.title}Name`] && showOperateBtn) ? 3 : g.viewAttr
};
} }
return { return {
...g, label: getLabel(g.lanId, g.label), ...g, label: getLabel(g.lanId, g.label),
@ -154,7 +161,7 @@ class Index extends Component {
return { return {
baseForm: JSON.stringify({ baseForm: JSON.stringify({
...formData[welfareType], ..._.reduce(_.keys(formData[welfareType]), (pre, cur) => { ...formData[welfareType], ..._.reduce(_.keys(formData[welfareType]), (pre, cur) => {
if (welfareData[cur]) return { ...pre, [cur]: welfareData[cur] }; if (welfareData[cur] || !_.isNil(welfareData[cur])) return { ...pre, [cur]: welfareData[cur] };
return { ...pre }; return { ...pre };
}, {}), }, {}),
underTake: welfareData[`${underTakeType}UnderTake`] underTake: welfareData[`${underTakeType}UnderTake`]

View File

@ -167,14 +167,14 @@ class Index extends Component {
this.setState({ this.setState({
pageInfo: { ...pageInfo, current, pageSize, total }, dataSource, pageInfo: { ...pageInfo, current, pageSize, total }, dataSource,
columns: _.map(columns, o => { columns: _.map(columns, o => {
const { column: dataIndex, text: title, width } = o; const { column: dataIndex, text: title, width, fixed } = o;
if (dataIndex === "employeeName") { if (dataIndex === "employeeName") {
return { return {
dataIndex, title, width, fixed: "left", ellipsis: true dataIndex, title, width, fixed: "left", ellipsis: true
}; };
} }
return { return {
dataIndex, title, width, ellipsis: true dataIndex, title, width, ellipsis: true, fixed: fixed || false
}; };
}) })
}, () => { }, () => {

View File

@ -791,8 +791,8 @@ const BenefitBaseComponent = (props) => {
com: <WeaFormItem label={child.label} labelCol={{ span: 10 }} wrapperCol={{ span: 14 }}> com: <WeaFormItem label={child.label} labelCol={{ span: 10 }} wrapperCol={{ span: 14 }}>
<WeaInputNumber <WeaInputNumber
value={value[getKey(child)] || (child.min !== "0.000" ? child.min : 0)} precision={2} value={value[getKey(child)] || (child.min !== "0.000" ? child.min : 0)} precision={2}
min={child.min !== "0.000" ? child.min : -999999999999999} min={(child.min !== "0.000" && value.welBaseAutoAdjust) ? parseFloat(child.min) : -999999999999999}
max={child.max !== "0.000" ? child.max : 999999999999999} max={(child.max !== "0.000" && value.welBaseAutoAdjust) ? parseFloat(child.max) : 999999999999999}
onChange={v => onChange(getKey(child), v)} onChange={v => onChange(getKey(child), v)}
viewAttr={(runStatuses === "4,5" || !showOperateBtn) ? 1 : 2} viewAttr={(runStatuses === "4,5" || !showOperateBtn) ? 1 : 2}
/> />