From 5a2ecefa6f32014bf567cf9c9fc840d8a8a58322 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, 2 Jul 2024 15:05:17 +0800 Subject: [PATCH] hotfix/2.14.2.2406.02 --- pc4mobx/hrmSalary/pages/ruleConfig/form.js | 10 +++++-- .../hrmSalary/pages/ruleConfig/ruleConfig.js | 27 ++++++++++++------- 2 files changed, 25 insertions(+), 12 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/ruleConfig/form.js b/pc4mobx/hrmSalary/pages/ruleConfig/form.js index c1308ec4..9b17f248 100644 --- a/pc4mobx/hrmSalary/pages/ruleConfig/form.js +++ b/pc4mobx/hrmSalary/pages/ruleConfig/form.js @@ -1,7 +1,9 @@ import React from "react"; -import { WeaFormItem, WeaSearchGroup } from "ecCom"; +import { WeaFormItem, WeaSearchGroup, WeaTools } from "ecCom"; import { WeaSwitch } from "comsMobx"; +const getKey = WeaTools.getKey; + export const renderRuleForm = (form, condition, onChange) => { const { isFormInit } = form; const formParams = form.getFormParams(); @@ -15,7 +17,11 @@ export const renderRuleForm = (form, condition, onChange) => { label={`${fields.label}`} labelCol={{ span: `${fields.labelcol}` }} wrapperCol={{ span: `${fields.fieldcol}` }} error={form.getError(fields)} tipPosition="bottom"> - + getKey(fields) !== "salaryAcctFixedColumns" && onChange(v)} + onBlur={(v) => getKey(fields) === "salaryAcctFixedColumns" && onChange({ salaryAcctFixedColumns: { value: v } })} + /> ), colSpan: 1, hide: fields.hide diff --git a/pc4mobx/hrmSalary/pages/ruleConfig/ruleConfig.js b/pc4mobx/hrmSalary/pages/ruleConfig/ruleConfig.js index efda13dd..3f24a0d6 100644 --- a/pc4mobx/hrmSalary/pages/ruleConfig/ruleConfig.js +++ b/pc4mobx/hrmSalary/pages/ruleConfig/ruleConfig.js @@ -25,6 +25,7 @@ class RuleConfig extends Component { super(props); this.state = { conditions: [], sysinfo: {}, progressVisible: false, progress: 50 }; this.timer = null; + this.handleDebounce = null; } componentDidMount() { @@ -116,16 +117,22 @@ class RuleConfig extends Component { case "taxAgentShowStatus": case "salaryShowStatus": case "adjustShowStatus": - const confTitle = { - welBaseDiffByPerAndCom: getLabel(111, "福利档案基数区分个人和公司"), - welBaseAutoAdjust: getLabel(111, "福利档案导入基数不符合要求时自动调整为上限/下限"), - salaryAcctFixedColumns: getLabel(545791, "薪资核算固定列头数"), - extEmpsWitch: getLabel(544097, "开启非系统人员"), - taxAgentShowStatus: getLabel(111, "显示【个税扣缴义务人】信息"), - salaryShowStatus: getLabel(111, "显示工资单页签"), - adjustShowStatus: getLabel(111, "显示调薪记录页签") - }; - this.unifiedSettings(key, confTitle[key]); + if (!this.handleDebounce) { + this.handleDebounce = _.debounce(() => { + const confTitle = { + welBaseDiffByPerAndCom: getLabel(111, "福利档案基数区分个人和公司"), + welBaseAutoAdjust: getLabel(111, "福利档案导入基数不符合要求时自动调整为上限/下限"), + salaryAcctFixedColumns: getLabel(545791, "薪资核算固定列头数"), + extEmpsWitch: getLabel(544097, "开启非系统人员"), + taxAgentShowStatus: getLabel(111, "显示【个税扣缴义务人】信息"), + salaryShowStatus: getLabel(111, "显示工资单页签"), + adjustShowStatus: getLabel(111, "显示调薪记录页签") + }; + this.unifiedSettings(key, confTitle[key]); + this.handleDebounce = null; + }, 500); + } + this.handleDebounce(); break; default: break;