From 1deceeb3e8955c884537ced9f0b4f2e3f95a2191 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Wed, 20 Mar 2024 16:36:56 +0800 Subject: [PATCH 01/14] =?UTF-8?q?feature/2.12.1.2403.02-=E7=A4=BE=E4=BF=9D?= =?UTF-8?q?=E6=A1=A3=E6=A1=88=E4=BF=9D=E5=AD=98=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../welfareEditArchiveSlide/index.js | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfareArchive/components/welfareEditArchiveSlide/index.js b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfareArchive/components/welfareEditArchiveSlide/index.js index 03a89212..304724fb 100644 --- a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfareArchive/components/welfareEditArchiveSlide/index.js +++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfareArchive/components/welfareEditArchiveSlide/index.js @@ -180,7 +180,7 @@ class Index extends Component { welfareType, validate: welfareData[`${underTakeType}SchemeId`] ? !!welfareData[`${underTakeType}StartTime`] : true }; }; - save = async () => { + save = async (changeData = false) => { const socailPayload = this.covertPayload("SOCIAL_SECURITY", "social", getConditionDomkeys(this.props.socialBase.items), getConditionDomkeys(this.props.socialBase.comItems || [])), fundPayload = this.covertPayload("ACCUMULATION_FUND", "fund", getConditionDomkeys(this.props.fundBase.items), getConditionDomkeys(this.props.fundBase.comItems || [])), otherPayload = this.covertPayload("OTHER", "other", getConditionDomkeys(this.props.otherBase.items), getConditionDomkeys(this.props.otherBase.comItems || [])); @@ -198,13 +198,24 @@ class Index extends Component { }, { status: otherStatus, errormsg: otherErrorMsg = "!" - }] = await Promise.all([API.save(socailPayload), API.save(fundPayload), API.save(otherPayload)]); + }] = await Promise.all([ + API.save({ ...socailPayload, changeData }), + API.save({ ...fundPayload, changeData }), + API.save({ ...otherPayload, changeData })]); this.setState({ loading: false }); if (socialStatus && fundStatus && otherStatus) { message.success(getLabel(30700, "操作成功!")); this.props.onClose(true); } else { - message.error(socialErrorMsg + fundErrorMsg + otherErrorMsg); + Modal.confirm({ + title: getLabel(131329, "信息确认"), + content:
+
{socialErrorMsg + fundErrorMsg + otherErrorMsg}
+
{getLabel(111, "是否自动将方案的上下限调整为设置值?")}
+
, + onOk: () => this.save(true), + onCancel: () => this.props.onClose() + }); } }; updateFormData = (baseData) => this.setState({ formData: { ...this.state.formData, ...baseData } }); @@ -278,7 +289,7 @@ class Index extends Component {
{ runStatuses !== "4,5" && showOperateBtn && - + }
; From 2fb3c8994741ef275b18a73be4e35c4f98ea6f3c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Fri, 26 Apr 2024 16:53:51 +0800 Subject: [PATCH 02/14] =?UTF-8?q?feature/2.12.1.2404.02-=E8=96=AA=E8=B5=84?= =?UTF-8?q?=E6=A0=B8=E7=AE=97=E5=88=A4=E6=96=AD=E8=B4=A6=E5=A5=97=E6=98=AF?= =?UTF-8?q?=E5=90=A6=E4=BF=AE=E6=94=B9=E6=8F=90=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pc4mobx/hrmSalary/apis/calculate.js | 9 ++ .../doCalc/components/salaryEditCalc/index.js | 6 +- .../components/salaryEditCalc/index.less | 27 ++++++ .../salaryEditCalc/salaryCalcLayout.js | 86 +++++++++++++++++++ 4 files changed, 125 insertions(+), 3 deletions(-) create mode 100644 pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/salaryCalcLayout.js diff --git a/pc4mobx/hrmSalary/apis/calculate.js b/pc4mobx/hrmSalary/apis/calculate.js index 0abda464..f2bd582a 100644 --- a/pc4mobx/hrmSalary/apis/calculate.js +++ b/pc4mobx/hrmSalary/apis/calculate.js @@ -266,4 +266,13 @@ export const deleteExportTemplate = (params) => { export const getExportTemplateForm = (params) => { return postFetch("/api/bs/hrmsalary/salaryacct/acctresult/getExportTemplateForm", params); }; +//薪资核算-薪资项目改变否 +export const getCompareSobConfig = params => { + return WeaTools.callApi("/api/bs/hrmsalary/salaryacct/compareSobConfig", "GET", params); +}; +//薪资核算-更新薪资账套 +export const updateSobConfig = params => { + return WeaTools.callApi("/api/bs/hrmsalary/salaryacct/updateSobConfig", "GET", params); +}; + diff --git a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/index.js b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/index.js index e3ed75a1..2b4a149d 100644 --- a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/index.js +++ b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/index.js @@ -6,12 +6,12 @@ */ import React, { Component } from "react"; import { WeaHelpfulTip, WeaLocaleProvider } from "ecCom"; -import { Button } from "antd"; import { getColumnDesc, getSalarySobCycle } from "../../../../../apis/calculate"; import { sysConfCodeRule } from "../../../../../apis/ruleconfig"; import EditCalcAdvanceSearchPannel from "./editCalcAdvanceSearchPannel"; import EditCalcTable from "./editCalcTable"; import SalaryMonthTip from "../salaryMonthTip"; +import SalaryCalcLayout from "./salaryCalcLayout"; import cs from "classnames"; import "./index.less"; @@ -57,7 +57,7 @@ class Index extends Component { const { salarySobCycle, showSearchAd, formulaTd, columnDesc, showTotalCell } = this.state; const { routeParams: { salaryAcctRecordId } } = this.props; const formulaObj = _.get(columnDesc, [formulaTd]) || {}; - return ( + return (
@@ -92,7 +92,7 @@ class Index extends Component { {...this.props} showTotalCell={showTotalCell} onShowFormulaTd={this.handleShowFormulaTa}/>
- ); + ); } } diff --git a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/index.less b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/index.less index 77f3e425..19d48e65 100644 --- a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/index.less +++ b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/index.less @@ -207,3 +207,30 @@ } } } + +.infoConfirmDialog { + .confirm-content { + width: 100%; + height: 100%; + padding: 16px; + overflow: auto; + position: relative; + display: flex; + flex-direction: column; + justify-content: space-between; + + .contract { + text-align: center; + flex-grow: 1; + flex-shrink: 1; + } + + .confirm-container { + flex-grow: 0; + flex-shrink: 0; + margin-top: 8px; + width: 100%; + + } + } +} diff --git a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/salaryCalcLayout.js b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/salaryCalcLayout.js new file mode 100644 index 00000000..1e7c24a1 --- /dev/null +++ b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/salaryCalcLayout.js @@ -0,0 +1,86 @@ +/* + * Author: 黎永顺 + * name: 薪资核算-layout + * Description: + * Date: 2024/4/26 + */ +import React, { Component } from "react"; +import { WeaCheckbox, WeaDialog, WeaLocaleProvider } from "ecCom"; +import { Button, message } from "antd"; +import * as API from "../../../../../apis/calculate"; +import "./index.less"; + +const getLabel = WeaLocaleProvider.getLabel; + +class SalaryCalcLayout extends Component { + constructor(props) { + super(props); + this.state = { + fieldInformationConfirm: { visible: false, data: {} }, userConfirmed: "0" + }; + } + + componentDidMount() { + this.getCompareSobConfig(); + } + + getCompareSobConfig = () => { + const { fieldInformationConfirm } = this.state; + const { routeParams: { salaryAcctRecordId: id } } = this.props; + API.getCompareSobConfig({ id }).then(({ status, data }) => { + if (status) { + this.setState({ + fieldInformationConfirm: { ...fieldInformationConfirm, visible: true } + }); + } + }); + }; + onOk = () => { + const { fieldInformationConfirm } = this.state; + const { routeParams: { salaryAcctRecordId: id } } = this.props; + API.updateSobConfig({ id }).then(({ status, errormsg }) => { + if (status) { + message.success(getLabel(30700, "操作成功!")); + this.setState({ + fieldInformationConfirm: { ...fieldInformationConfirm, visible: false } + }); + } else { + message.error(errormsg); + } + }); + }; + + render() { + const { fieldInformationConfirm, userConfirmed } = this.state; + const buttons = [ + , + + ]; + return ( + + {this.props.children} + + this.setState({ + fieldInformationConfirm: { ...fieldInformationConfirm, visible: false } + })}> +
+
+ {getLabel("111", "本次核算所属薪资账套发生变更,是否需要按最新的账套设置进行核算?按照最新的账套进行核算,将覆盖当前核算数据(不清空手动输入/导入的数据),且不可恢复,请谨慎操作。")} +
+
+ this.setState({ userConfirmed: v })}/> +
+
+
+
+ ); + } +} + +export default SalaryCalcLayout; From ae427c033ac34f9f946c117d3e51fbea5cc76d50 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Fri, 26 Apr 2024 17:37:22 +0800 Subject: [PATCH 03/14] =?UTF-8?q?feature/2.12.1.2404.02-=E8=96=AA=E8=B5=84?= =?UTF-8?q?=E6=A0=B8=E7=AE=97=E5=88=A4=E6=96=AD=E8=B4=A6=E5=A5=97=E6=98=AF?= =?UTF-8?q?=E5=90=A6=E4=BF=AE=E6=94=B9=E6=8F=90=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../doCalc/components/salaryEditCalc/salaryCalcLayout.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/salaryCalcLayout.js b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/salaryCalcLayout.js index 1e7c24a1..73d0c771 100644 --- a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/salaryCalcLayout.js +++ b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/salaryCalcLayout.js @@ -30,7 +30,7 @@ class SalaryCalcLayout extends Component { API.getCompareSobConfig({ id }).then(({ status, data }) => { if (status) { this.setState({ - fieldInformationConfirm: { ...fieldInformationConfirm, visible: true } + fieldInformationConfirm: { ...fieldInformationConfirm, visible: data } }); } }); From 020af95921f44afb705121ef514516d786f1bf57 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Mon, 6 May 2024 16:58:42 +0800 Subject: [PATCH 04/14] =?UTF-8?q?feature/2.12.1.2404.02-=E8=96=AA=E8=B5=84?= =?UTF-8?q?=E6=A0=B8=E7=AE=97=E5=88=A4=E6=96=AD=E8=B4=A6=E5=A5=97=E6=98=AF?= =?UTF-8?q?=E5=90=A6=E4=BF=AE=E6=94=B9=E6=8F=90=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pages/calculate/doCalc/components/salaryEditCalc/index.js | 2 +- .../doCalc/components/salaryEditCalc/salaryCalcLayout.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/index.js b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/index.js index 2b4a149d..1f803fed 100644 --- a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/index.js +++ b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/index.js @@ -57,7 +57,7 @@ class Index extends Component { const { salarySobCycle, showSearchAd, formulaTd, columnDesc, showTotalCell } = this.state; const { routeParams: { salaryAcctRecordId } } = this.props; const formulaObj = _.get(columnDesc, [formulaTd]) || {}; - return ( + return ( this.onAdSearch(false)}>
diff --git a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/salaryCalcLayout.js b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/salaryCalcLayout.js index 73d0c771..141e6510 100644 --- a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/salaryCalcLayout.js +++ b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/salaryCalcLayout.js @@ -43,7 +43,7 @@ class SalaryCalcLayout extends Component { message.success(getLabel(30700, "操作成功!")); this.setState({ fieldInformationConfirm: { ...fieldInformationConfirm, visible: false } - }); + }, () => this.props.onConfirm()); } else { message.error(errormsg); } From 3b90b1def4e7ae323c0d85015448fd7268c1660e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Tue, 7 May 2024 10:48:52 +0800 Subject: [PATCH 05/14] =?UTF-8?q?feature/2.12.1.2404.02-=E8=96=AA=E8=B5=84?= =?UTF-8?q?=E6=A0=B8=E7=AE=97=E5=88=A4=E6=96=AD=E8=B4=A6=E5=A5=97=E6=98=AF?= =?UTF-8?q?=E5=90=A6=E4=BF=AE=E6=94=B9=E6=8F=90=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../doCalc/components/salaryEditCalc/salaryCalcLayout.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/salaryCalcLayout.js b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/salaryCalcLayout.js index 141e6510..d30a722f 100644 --- a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/salaryCalcLayout.js +++ b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/salaryCalcLayout.js @@ -54,7 +54,7 @@ class SalaryCalcLayout extends Component { const { fieldInformationConfirm, userConfirmed } = this.state; const buttons = [ , + disabled={userConfirmed === "0"}>{getLabel(111, "是,更新账套设置")}, @@ -70,7 +70,7 @@ class SalaryCalcLayout extends Component { })}>
- {getLabel("111", "本次核算所属薪资账套发生变更,是否需要按最新的账套设置进行核算?按照最新的账套进行核算,将覆盖当前核算数据(不清空手动输入/导入的数据),且不可恢复,请谨慎操作。")} + {getLabel("111", "账套发生变更,是否需要更新账套设置?更新后核算将按照最新的账套进行核算,请谨慎操作。")}
Date: Tue, 7 May 2024 14:09:08 +0800 Subject: [PATCH 06/14] =?UTF-8?q?feature/2.12.1.2404.02-=E8=96=AA=E8=B5=84?= =?UTF-8?q?=E6=A0=B8=E7=AE=97=E5=88=A4=E6=96=AD=E8=B4=A6=E5=A5=97=E6=98=AF?= =?UTF-8?q?=E5=90=A6=E4=BF=AE=E6=94=B9=E6=8F=90=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../doCalc/components/salaryEditCalc/index.js | 6 +---- .../components/salaryEditCalc/index.less | 9 +++++++ .../salaryEditCalc/salaryCalcLayout.js | 27 ++++++++++++------- .../hrmSalary/pages/calculate/doCalc/index.js | 26 +++++++----------- 4 files changed, 38 insertions(+), 30 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/index.js b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/index.js index 1f803fed..54081da1 100644 --- a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/index.js +++ b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/index.js @@ -26,10 +26,6 @@ class Index extends Component { }; } - componentDidMount() { - const promise = this.init(); - } - openAdvanceSearch = () => this.setState({ showSearchAd: !this.state.showSearchAd }); onAdSearch = (bool = true) => { this.calcTableRef.wrappedInstance.queryCalcResultList(); @@ -57,7 +53,7 @@ class Index extends Component { const { salarySobCycle, showSearchAd, formulaTd, columnDesc, showTotalCell } = this.state; const { routeParams: { salaryAcctRecordId } } = this.props; const formulaObj = _.get(columnDesc, [formulaTd]) || {}; - return ( this.onAdSearch(false)}> + return ( this.onAdSearch(false)}>
diff --git a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/index.less b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/index.less index 19d48e65..3d23810b 100644 --- a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/index.less +++ b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/index.less @@ -234,3 +234,12 @@ } } } + +.loadingLayout { + width: 100%; + height: 100%; + text-align: center; + border-radius: 4px; + padding: 30px 50px; + margin: 20px 0; +} diff --git a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/salaryCalcLayout.js b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/salaryCalcLayout.js index d30a722f..0ece4702 100644 --- a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/salaryCalcLayout.js +++ b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/salaryCalcLayout.js @@ -6,7 +6,7 @@ */ import React, { Component } from "react"; import { WeaCheckbox, WeaDialog, WeaLocaleProvider } from "ecCom"; -import { Button, message } from "antd"; +import { Button, message, Spin } from "antd"; import * as API from "../../../../../apis/calculate"; import "./index.less"; @@ -16,7 +16,7 @@ class SalaryCalcLayout extends Component { constructor(props) { super(props); this.state = { - fieldInformationConfirm: { visible: false, data: {} }, userConfirmed: "0" + fieldInformationConfirm: { visible: false, data: {} }, userConfirmed: "0", show: false }; } @@ -28,12 +28,14 @@ class SalaryCalcLayout extends Component { const { fieldInformationConfirm } = this.state; const { routeParams: { salaryAcctRecordId: id } } = this.props; API.getCompareSobConfig({ id }).then(({ status, data }) => { - if (status) { + if (status && data) { this.setState({ fieldInformationConfirm: { ...fieldInformationConfirm, visible: data } }); + } else { + this.setState({ show: true }, () => this.props.init()); } - }); + }).catch(() => this.setState({ show: true }, () => this.props.init())); }; onOk = () => { const { fieldInformationConfirm } = this.state; @@ -42,8 +44,12 @@ class SalaryCalcLayout extends Component { if (status) { message.success(getLabel(30700, "操作成功!")); this.setState({ + show: true, fieldInformationConfirm: { ...fieldInformationConfirm, visible: false } - }, () => this.props.onConfirm()); + }, () => { + this.props.init(); + this.props.onConfirm(); + }); } else { message.error(errormsg); } @@ -51,23 +57,26 @@ class SalaryCalcLayout extends Component { }; render() { - const { fieldInformationConfirm, userConfirmed } = this.state; + const { fieldInformationConfirm, userConfirmed, show } = this.state; const buttons = [ , + }, () => this.props.init())}>{getLabel(111, "否,忽略该提示")} ]; return ( - {this.props.children} + { + show ? this.props.children :
+ } this.setState({ fieldInformationConfirm: { ...fieldInformationConfirm, visible: false } - })}> + }, () => this.props.init())}>
{getLabel("111", "账套发生变更,是否需要更新账套设置?更新后核算将按照最新的账套进行核算,请谨慎操作。")} diff --git a/pc4mobx/hrmSalary/pages/calculate/doCalc/index.js b/pc4mobx/hrmSalary/pages/calculate/doCalc/index.js index d8a8d78e..0d1c87fc 100644 --- a/pc4mobx/hrmSalary/pages/calculate/doCalc/index.js +++ b/pc4mobx/hrmSalary/pages/calculate/doCalc/index.js @@ -216,23 +216,17 @@ class Index extends Component { /> } {/* 薪资核算-自定义导出*/} - { - this.setState({ - customExpDialog: { ...customExpDialog, visible: false } - }); - }} - /> + { + this.setState({ + customExpDialog: { ...customExpDialog, visible: false } + }); + }}/> {/* 薪资核算-导入*/} - { - this.setState({ - salaryImpDialog: { ...salaryImpDialog, visible: false } - }, () => isFresh && this.calc.onAdSearch(false)); - }} - /> + { + this.setState({ + salaryImpDialog: { ...salaryImpDialog, visible: false } + }, () => isFresh && this.calc.onAdSearch(false)); + }}/>
From 7cf0cc33576dc69da6801487bac2ab36cc86a522 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Tue, 7 May 2024 14:13:12 +0800 Subject: [PATCH 07/14] =?UTF-8?q?feature/2.12.1.2404.02-=E8=96=AA=E8=B5=84?= =?UTF-8?q?=E6=A0=B8=E7=AE=97=E5=88=A4=E6=96=AD=E8=B4=A6=E5=A5=97=E6=98=AF?= =?UTF-8?q?=E5=90=A6=E4=BF=AE=E6=94=B9=E6=8F=90=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../doCalc/components/salaryEditCalc/salaryCalcLayout.js | 1 + 1 file changed, 1 insertion(+) diff --git a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/salaryCalcLayout.js b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/salaryCalcLayout.js index 0ece4702..c95f07b0 100644 --- a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/salaryCalcLayout.js +++ b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/salaryCalcLayout.js @@ -75,6 +75,7 @@ class SalaryCalcLayout extends Component { title={getLabel(131329, "信息确认")} visible={fieldInformationConfirm.visible} initLoadCss hasScroll style={{ width: 380 }} className="infoConfirmDialog" buttons={buttons} onCancel={() => this.setState({ + show: true, fieldInformationConfirm: { ...fieldInformationConfirm, visible: false } }, () => this.props.init())}>
From 8f8f6c5ed1b8751827d7de81ba4cddfdbbf23266 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Fri, 17 May 2024 10:51:56 +0800 Subject: [PATCH 08/14] =?UTF-8?q?feature/2.12.1.2403.02-=E7=A4=BE=E4=BF=9D?= =?UTF-8?q?=E6=A1=A3=E6=A1=88=E4=BF=9D=E5=AD=98=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../welfareEditArchiveSlide/index.js | 53 ++++++++++++------- .../welfareArchive/config.js | 4 +- 2 files changed, 35 insertions(+), 22 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfareArchive/components/welfareEditArchiveSlide/index.js b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfareArchive/components/welfareEditArchiveSlide/index.js index 304724fb..e2342e93 100644 --- a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfareArchive/components/welfareEditArchiveSlide/index.js +++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfareArchive/components/welfareEditArchiveSlide/index.js @@ -6,7 +6,7 @@ */ import React, { Component } from "react"; import { inject, observer } from "mobx-react"; -import { WeaLocaleProvider, WeaSlideModal, WeaTools } from "ecCom"; +import { WeaDialog, WeaLocaleProvider, WeaSlideModal, WeaTools } from "ecCom"; import * as API from "../../../../../apis/welfareArchive"; import { getTaxAgentSelectList } from "../../../../../apis/taxAgent"; import { sysinfo } from "../../../../../apis/ruleconfig"; @@ -23,7 +23,7 @@ class Index extends Component { constructor(props) { super(props); this.state = { - loading: false, conditions: [], formData: {} + loading: false, conditions: [], formData: {}, errorDialog: { visible: false, errorMsg: "" } }; } @@ -207,14 +207,8 @@ class Index extends Component { message.success(getLabel(30700, "操作成功!")); this.props.onClose(true); } else { - Modal.confirm({ - title: getLabel(131329, "信息确认"), - content:
-
{socialErrorMsg + fundErrorMsg + otherErrorMsg}
-
{getLabel(111, "是否自动将方案的上下限调整为设置值?")}
-
, - onOk: () => this.save(true), - onCancel: () => this.props.onClose() + !changeData && this.setState({ + errorDialog: { visible: true, errorMsg: socialErrorMsg + fundErrorMsg + otherErrorMsg } }); } }; @@ -257,18 +251,19 @@ class Index extends Component { }; handleExtraChange = (key, value) => this.setState({ formData: { ...this.state.formData, [key]: value } }); handleSameChange = (baseItems, value) => { + if (!value) return; let newFormDatas = {}, hasCompromise = false; baseItems.forEach((formLabel) => { - const { min, max } = formLabel; + // const { min, max } = formLabel; newFormDatas[getKey(formLabel)] = toDecimal_n(value, 2) || ""; - if (min !== "0.000" && value !== "" && Number(value) < Number(min)) { - hasCompromise = true; - newFormDatas[getKey(formLabel)] = toDecimal_n(Number(min), 2); - } - if (max !== "0.000" && value !== "" && Number(value) > Number(max)) { - hasCompromise = true; - newFormDatas[getKey(formLabel)] = toDecimal_n(Number(max), 2); - } + // if (min !== "0.000" && value !== "" && Number(value) < Number(min)) { + // hasCompromise = true; + // newFormDatas[getKey(formLabel)] = toDecimal_n(Number(min), 2); + // } + // if (max !== "0.000" && value !== "" && Number(value) > Number(max)) { + // hasCompromise = true; + // newFormDatas[getKey(formLabel)] = toDecimal_n(Number(max), 2); + // } }); if (hasCompromise) { message.warning(getLabel("111", "超出所选缴纳方案设置的基数上下限范围,将自动按基数上下限填充。")); @@ -311,7 +306,7 @@ class Index extends Component { render() { const { archivesStore: { welfareProfileForm }, showOperateBtn } = this.props; - const { conditions, formData } = this.state; + const { conditions, formData, errorDialog } = this.state; return ( { + this.setState({ errorDialog: { ...errorDialog, visible: false } }, () => { + const promise = this.save(true); + message.success(getLabel(30700, "操作成功!")); + this.props.onClose(true); + }); + }}>{getLabel(111, "确认")} + ]} + onCancel={() => this.setState({ errorDialog: { ...errorDialog, visible: false } })} + bottomLeft={getLabel(111, "点击【确认】自动将不满足条件的基数值设置为对应的上限或下限值")} + > +
+
") }}/> +
+
} /> ); diff --git a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfareArchive/config.js b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfareArchive/config.js index 2c0a760d..78fb3505 100644 --- a/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfareArchive/config.js +++ b/pc4mobx/hrmSalary/pages/socialSecurityBenefits/welfareArchive/config.js @@ -815,8 +815,8 @@ const BenefitBaseComponent = (props) => { com: onChange(getKey(child), v)} viewAttr={(runStatuses === "4,5" || !showOperateBtn) ? 1 : 2} /> From fd6fb3bd9dfd1957130062f9ac8a2311e0137407 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Tue, 21 May 2024 15:11:52 +0800 Subject: [PATCH 09/14] hotfix/2.14.2.2405.02 --- .../pages/calculate/calcOc/components/salaryCalcOcImport.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/calculate/calcOc/components/salaryCalcOcImport.js b/pc4mobx/hrmSalary/pages/calculate/calcOc/components/salaryCalcOcImport.js index 11a784ca..95de0805 100644 --- a/pc4mobx/hrmSalary/pages/calculate/calcOc/components/salaryCalcOcImport.js +++ b/pc4mobx/hrmSalary/pages/calculate/calcOc/components/salaryCalcOcImport.js @@ -16,8 +16,7 @@ class SalaryCalcOcImport extends Component { super(props); this.state = { importDialog: { - visible: false, title: "", nextloading: false, importResult: {}, imageId: "", - link: "/api/bs/hrmsalary/salaryacct/comparisonresult/importtemplate/export?salaryAcctRecordId=", + visible: false, title: "", nextloading: false, importResult: {}, imageId: "", link: "", previewUrl: "/api/bs/hrmsalary/salaryacct/comparisonresult/preview", extraPreview: { salaryAcctRecordId: "" } } @@ -30,7 +29,7 @@ class SalaryCalcOcImport extends Component { this.setState({ importDialog: { ...this.state.importDialog, - link: `${importDialog.link}${nextProps.salaryAcctRecordId}`, + link: `/api/bs/hrmsalary/salaryacct/comparisonresult/importtemplate/export?salaryAcctRecordId=${nextProps.salaryAcctRecordId}`, visible: nextProps.visible, importResult: {}, title: nextProps.title, imageId: "", extraPreview: { salaryAcctRecordId: nextProps.salaryAcctRecordId } From 4eabe190353876fd57106d13a5510fc5e5167cec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Tue, 21 May 2024 15:58:28 +0800 Subject: [PATCH 10/14] hotfix/2.14.2.2405.02 --- pc4mobx/hrmSalary/pages/salaryItem/columns.js | 7 +++++++ pc4mobx/hrmSalary/pages/salaryItem/salaryItemForm.js | 6 ++++++ 2 files changed, 13 insertions(+) diff --git a/pc4mobx/hrmSalary/pages/salaryItem/columns.js b/pc4mobx/hrmSalary/pages/salaryItem/columns.js index d03e1dfc..281fa6ec 100644 --- a/pc4mobx/hrmSalary/pages/salaryItem/columns.js +++ b/pc4mobx/hrmSalary/pages/salaryItem/columns.js @@ -128,6 +128,13 @@ export const salaryItemFields = [ viewAttr: 2, tip: "" }, + { + key: "defaultValue", + label: "默认值", + type: "INPUT", + viewAttr: 2, + tip: "" + }, { key: "formulaContent", label: "公式", diff --git a/pc4mobx/hrmSalary/pages/salaryItem/salaryItemForm.js b/pc4mobx/hrmSalary/pages/salaryItem/salaryItemForm.js index 564c2ef8..c510a622 100644 --- a/pc4mobx/hrmSalary/pages/salaryItem/salaryItemForm.js +++ b/pc4mobx/hrmSalary/pages/salaryItem/salaryItemForm.js @@ -84,6 +84,12 @@ class SalaryItemForm extends Component { ...item, viewAttr: (useInEmployeeSalary.toString() === "0" && ((isLedger && record.canEdit) || (editable && record.canEdit) || isAdd)) ? 2 : 1 }; + case "defaultValue": + return { + ...item, + display: valueType && valueType.toString() === "1", + viewAttr: (isLedger && record.canEdit) || (editable && record.canEdit) || isAdd ? 2 : 1 + }; case "formulaContent": return { ...item, From fb64d5e344def7bd6a114e66f1235393d64cf82c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Tue, 21 May 2024 17:33:47 +0800 Subject: [PATCH 11/14] hotfix/2.14.2.2405.02 --- pc4mobx/hrmSalary/pages/salaryItem/salaryItemForm.js | 5 +++++ pc4mobx/hrmSalary/stores/salaryItem.js | 6 ++++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/salaryItem/salaryItemForm.js b/pc4mobx/hrmSalary/pages/salaryItem/salaryItemForm.js index c510a622..47d48a73 100644 --- a/pc4mobx/hrmSalary/pages/salaryItem/salaryItemForm.js +++ b/pc4mobx/hrmSalary/pages/salaryItem/salaryItemForm.js @@ -87,6 +87,7 @@ class SalaryItemForm extends Component { case "defaultValue": return { ...item, + type: dataType === "number" ? "INPUTNUMBER" : "INPUT", display: valueType && valueType.toString() === "1", viewAttr: (isLedger && record.canEdit) || (editable && record.canEdit) || isAdd ? 2 : 1 }; @@ -117,6 +118,10 @@ class SalaryItemForm extends Component { return { ...item, display: v === "1", viewAttr: 3 }; } else if (key === "dataType" && (item.key === "roundingMode" || item.key === "pattern")) { return { ...item, display: v === "number" }; + } else if (key === "dataType" && (item.key === "defaultValue")) { + return { ...item, type: v === "number" ? "INPUTNUMBER" : "INPUT" }; + } else if (key === "valueType" && item.key === "defaultValue") { + return { ...item, display: v === "1" }; } else if (key === "valueType" && (item.key === "originSqlContent" || item.key === "originFormulaContent")) { return { ...item, diff --git a/pc4mobx/hrmSalary/stores/salaryItem.js b/pc4mobx/hrmSalary/stores/salaryItem.js index 54a84562..cc3a0214 100644 --- a/pc4mobx/hrmSalary/stores/salaryItem.js +++ b/pc4mobx/hrmSalary/stores/salaryItem.js @@ -34,7 +34,8 @@ export class SalaryItemStore { dataType: "number", description: "", sharedType: "0", - taxAgentIds: "" + taxAgentIds: "", + defaultValue: "" }; @observable tableDataSource = []; // 主列表 @@ -75,7 +76,8 @@ export class SalaryItemStore { dataType: "number", description: "", sharedType: "0", - taxAgentIds: "" + taxAgentIds: "", + defaultValue: "" }; @action From b7aeae0aeb5aef3b34d3a3c0d10aa178f1d47791 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Thu, 23 May 2024 11:01:06 +0800 Subject: [PATCH 12/14] hotfix/2.14.2.2405.02 --- pc4mobx/hrmSalary/pages/salaryItem/columns.js | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/salaryItem/columns.js b/pc4mobx/hrmSalary/pages/salaryItem/columns.js index 281fa6ec..e34b5431 100644 --- a/pc4mobx/hrmSalary/pages/salaryItem/columns.js +++ b/pc4mobx/hrmSalary/pages/salaryItem/columns.js @@ -128,13 +128,13 @@ export const salaryItemFields = [ viewAttr: 2, tip: "" }, - { - key: "defaultValue", - label: "默认值", - type: "INPUT", - viewAttr: 2, - tip: "" - }, + // { + // key: "defaultValue", + // label: "默认值", + // type: "INPUT", + // viewAttr: 2, + // tip: "" + // }, { key: "formulaContent", label: "公式", From 655dd6afb45419a4c4e62b419eea125dd6e99e8d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Thu, 23 May 2024 15:42:14 +0800 Subject: [PATCH 13/14] hotfix/2.14.2.2405.02 --- pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/index.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/index.js b/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/index.js index d4681ac2..121e334a 100644 --- a/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/index.js +++ b/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/index.js @@ -42,8 +42,8 @@ class Index extends Component { keyword: "", year: moment().format("YYYY"), dateRange: [ - moment(new Date()).subtract(1, "year").startOf("year").format("YYYY-MM"), - moment(new Date()).endOf("year").format("YYYY-MM") + moment(new Date()).subtract(6, "months").format("YYYY-MM"), + moment(new Date()).format("YYYY-MM") ], showSearchAd: false, isQuery: false, From 9577462831585f6cdb563269058cb3d356935d16 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=8E=E6=B0=B8=E9=A1=BA?= <971387674@qq.com> Date: Fri, 24 May 2024 09:57:35 +0800 Subject: [PATCH 14/14] hotfix/2.14.2.2405.02 --- .../components/salaryDetails.js | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/salaryDetails.js b/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/salaryDetails.js index 280a0f46..84882ff0 100644 --- a/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/salaryDetails.js +++ b/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/salaryDetails.js @@ -26,7 +26,7 @@ class SalaryDetails extends Component { this.state = { loading: false, dataSource: [], columns: [], selectedRowKeys: [], pageInfo: { current: 1, pageSize: 10, total: 0 }, payload: {}, - showTotalCell: false + showTotalCell: false, updateSum: true }; } @@ -54,10 +54,13 @@ class SalaryDetails extends Component { } else if (type === "turn") { if (id === "PAGEINFO") { const { pageNum: current, size: pageSize } = params; - this.setState({ pageInfo: { ...pageInfo, current, pageSize } }, () => this.getSalaryList(this.props)); + this.setState({ + pageInfo: { ...pageInfo, current, pageSize }, + updateSum: true + }, () => this.getSalaryList(this.props)); } else if (id === "CHECKBOX") { const { selectedRowKeys: checkBox } = params; - this.setState({ selectedRowKeys: checkBox }); + this.setState({ selectedRowKeys: checkBox, updateSum: false }); } } }; @@ -106,13 +109,13 @@ class SalaryDetails extends Component { }; getColumns = () => { const { attendanceStore: { tableStore } } = this.props; - const { dataSource, pageInfo, selectedRowKeys, showTotalCell, payload } = this.state; + const { dataSource, pageInfo, selectedRowKeys, showTotalCell, payload, updateSum } = this.state; const columns = _.filter(toJS(tableStore.columns), (item) => item.display === "true" && item.dataIndex !== "acctTimes"); const sumRowlistUrl = showTotalCell ? "/api/bs/hrmsalary/report/statistics/employee/salaryListSum" : ""; if (!_.isEmpty(columns)) { this.postMessageToChild({ - dataSource, pageInfo, selectedRowKeys, showTotalCell, calcDetail: true, tableScrollHeight: 154, payload, - sumRowlistUrl, + dataSource, pageInfo, selectedRowKeys, showTotalCell, calcDetail: true, tableScrollHeight: 154, + sumRowlistUrl, payload: { ...payload, updateSum }, columns: _.map(columns, (it, idx) => ({ ...it, width: (it.dataIndex === "taxAgent" || it.dataIndex === "salarySob") ? 176 : it.oldWidth,