From d14003a125a7d889468dcfb535a9ad8e7abd9e4a 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, 17 Jun 2024 15:48:52 +0800 Subject: [PATCH 01/60] =?UTF-8?q?feature/2.14.4.2406.02-=E4=B8=AA=E7=A8=8E?= =?UTF-8?q?=E5=9C=A8=E7=BA=BF=E7=AE=97=E7=A8=8E?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pc4mobx/hrmSalary/apis/calculate.js | 10 +- pc4mobx/hrmSalary/apis/ledger.js | 12 + .../custom-title/weaReqTitle/index.js | 17 + .../custom-title/weaTopTitle/index.js | 15 + .../hrmSalary/pages/calculate/doCalc/index.js | 42 +- .../incomeTaxFieldsCorresponding.js | 147 +++++++ .../pages/ledgerPage/components/index.less | 14 +- .../components/ledgerBaseSetting.js | 24 +- .../ledgerPage/components/ledgerSlide.js | 412 +++++++++--------- pc4mobx/hrmSalary/pages/ledgerPage/index.less | 10 - pc4mobx/hrmSalary/style/index.less | 24 + 11 files changed, 483 insertions(+), 244 deletions(-) create mode 100644 pc4mobx/hrmSalary/components/custom-title/weaReqTitle/index.js create mode 100644 pc4mobx/hrmSalary/components/custom-title/weaTopTitle/index.js create mode 100644 pc4mobx/hrmSalary/pages/ledgerPage/components/incomeTaxFieldsCorresponding.js diff --git a/pc4mobx/hrmSalary/apis/calculate.js b/pc4mobx/hrmSalary/apis/calculate.js index 85805d5c..d7f1fb5b 100644 --- a/pc4mobx/hrmSalary/apis/calculate.js +++ b/pc4mobx/hrmSalary/apis/calculate.js @@ -278,5 +278,11 @@ export const getCompareSobConfig = params => { export const updateSobConfig = params => { return WeaTools.callApi("/api/bs/hrmsalary/salaryacct/updateSobConfig", "GET", params); }; - - +//薪资核算-计算个税 +export const acctresultCalcTax = (params) => { + return postFetch("/api/bs/hrmsalary/salaryacct/acctresult/calcTax", params); +}; +//薪资核算-获取个税计算反馈 +export const calcTaxFeedback = (params) => { + return postFetch("/api/bs/hrmsalary/salaryacct/acctresult/calcTaxFeedback", params); +}; diff --git a/pc4mobx/hrmSalary/apis/ledger.js b/pc4mobx/hrmSalary/apis/ledger.js index 9c9d625e..59f898d4 100644 --- a/pc4mobx/hrmSalary/apis/ledger.js +++ b/pc4mobx/hrmSalary/apis/ledger.js @@ -25,6 +25,10 @@ export const deleteLedger = params => { export const getLedgerBasicForm = params => { return WeaTools.callApi("/api/bs/hrmsalary/salarysob/basic/getForm", "get", params); }; +//薪资帐套基本信息工资类型接口 +export const getIncomeCategoryList = params => { + return WeaTools.callApi("/api/bs/hrmsalary/salarysob/incomeCategoryList", "get", params); +}; //保存薪资帐套基本信息 export const saveLedgerBasic = params => { @@ -143,6 +147,10 @@ export const getBackitemForm = params => { export const taxreportruleGetForm = params => { return WeaTools.callApi("/api/bs/hrmsalary/salarysob/taxreportrule/getForm", "GET", params); }; +//薪资账套下的个税字段对应-个税字段对应 +export const taxruleGetForm = params => { + return WeaTools.callApi("/api/bs/hrmsalary/salarysob/taxrule/getForm", "GET", params); +}; //薪资账套下的个税申报-累计字段对应 export const addupruleGetForm = params => { return WeaTools.callApi("/api/bs/hrmsalary/salarysob/adduprule/getForm", "GET", params); @@ -151,6 +159,10 @@ export const addupruleGetForm = params => { export const taxreportruleSave = params => { return postFetch("/api/bs/hrmsalary/salarysob/taxreportrule/save", params); }; +//保存薪资账套下的个税字段对应规则 +export const taxruleSave = params => { + return postFetch("/api/bs/hrmsalary/salarysob/taxrule/save", params); +}; //保存薪资账套下的累计字段对应关系 export const addupruleSave = params => { return postFetch("/api/bs/hrmsalary/salarysob/adduprule/save", params); diff --git a/pc4mobx/hrmSalary/components/custom-title/weaReqTitle/index.js b/pc4mobx/hrmSalary/components/custom-title/weaReqTitle/index.js new file mode 100644 index 00000000..69766076 --- /dev/null +++ b/pc4mobx/hrmSalary/components/custom-title/weaReqTitle/index.js @@ -0,0 +1,17 @@ +import React, { Component } from "react"; +import { WeaLocaleProvider, WeaReqTop } from "ecCom"; + +const getLabel = WeaLocaleProvider.getLabel; + +class Index extends Component { + render() { + return ( + } iconBgcolor="#F14A2D" + showDropIcon={false} tabDatas={this.props.tabDatas} {...this.props} + /> + ); + } +} + +export default Index; diff --git a/pc4mobx/hrmSalary/components/custom-title/weaTopTitle/index.js b/pc4mobx/hrmSalary/components/custom-title/weaTopTitle/index.js new file mode 100644 index 00000000..d265c8eb --- /dev/null +++ b/pc4mobx/hrmSalary/components/custom-title/weaTopTitle/index.js @@ -0,0 +1,15 @@ +import React, { Component } from "react"; +import { WeaLocaleProvider, WeaTop } from "ecCom"; + +const getLabel = WeaLocaleProvider.getLabel; + +class Index extends Component { + render() { + return ( + } + iconBgcolor="#F14A2D" {...this.props}/> + ); + } +} + +export default Index; diff --git a/pc4mobx/hrmSalary/pages/calculate/doCalc/index.js b/pc4mobx/hrmSalary/pages/calculate/doCalc/index.js index 0d1c87fc..cef79e68 100644 --- a/pc4mobx/hrmSalary/pages/calculate/doCalc/index.js +++ b/pc4mobx/hrmSalary/pages/calculate/doCalc/index.js @@ -9,7 +9,7 @@ import { WeaLocaleProvider, WeaReqTop } from "ecCom"; import { Button, Dropdown, Menu, message, Modal } from "antd"; import { inject, observer } from "mobx-react"; import Layout from "./layout"; -import { acctresultAccounting, getCalculateProgress, getExportField } from "../../../apis/calculate"; +import * as API from "../../../apis/calculate"; import AdvanceInputBtn from "./components/advanceInputBtn"; import SalaryCalcPersonConfirm from "./components/salaryCalcPersonConfirm"; import SalaryEditCalc from "./components/salaryEditCalc"; @@ -27,7 +27,7 @@ class Index extends Component { constructor(props) { super(props); this.state = { - selectedKey: "person", progressVisible: false, progress: 0, + selectedKey: "person", progressVisible: false, progress: 0, loading: { calcTax: false, feedback: false }, customExpDialog: { visible: false, salaryAcctRecordId: "", checkItems: [], itemsByGroup: [] }, salaryImpDialog: { visible: false, title: "", salaryAcctRecordId: "" }, accountExceptInfo: "" //核算报错信息, @@ -60,11 +60,11 @@ class Index extends Component { this.setState({ progress: 0 }); let payload = { salaryAcctRecordId }; if (key === "calc_selected") payload = _.assign(payload, { ids: selectedRowKeys }); - acctresultAccounting(payload).then(() => { + API.acctresultAccounting(payload).then(() => { this.setState({ progressVisible: true }); if (this.timer) clearInterval(this.timer); this.timer = setInterval(() => { - getCalculateProgress(salaryAcctRecordId).then(({ data }) => { + API.getCalculateProgress(salaryAcctRecordId).then(({ data }) => { let progress = data.progress; if (progress === 1 && this.timer) { clearInterval(this.timer); @@ -101,7 +101,7 @@ class Index extends Component { window.open(`${window.ecologyContentPath || ""}${url}`, "_blank"); break; case "export_custom": - getExportField({ salaryAcctRecordId }).then(({ status, data }) => { + API.getExportField({ salaryAcctRecordId }).then(({ status, data }) => { if (status) { const { checkItems, itemsByGroup } = data; this.setState({ @@ -129,8 +129,34 @@ class Index extends Component { break; } }; + acctresultCalcTax = () => { + const { routeParams: { salaryAcctRecordId } } = this.props; + this.setState({ loading: { ...this.state.loading, calcTax: true } }); + API.acctresultCalcTax({ salaryAcctRecordId }).then(({ status, errormsg }) => { + this.setState({ loading: { ...this.state.loading, calcTax: false } }); + if (status) { + message.success(getLabel(111, "操作成功!")); + this.calc.onAdSearch(false); + } else { + message.error(errormsg); + } + }).catch(() => this.setState({ loading: { ...this.state.loading, calcTax: false } })); + }; + calcTaxFeedback = () => { + const { routeParams: { salaryAcctRecordId } } = this.props; + this.setState({ loading: { ...this.state.loading, feedback: true } }); + API.calcTaxFeedback({ salaryAcctRecordId }).then(({ status, errormsg }) => { + this.setState({ loading: { ...this.state.loading, feedback: false } }); + if (status) { + message.success(getLabel(111, "操作成功!")); + this.calc.onAdSearch(false); + } else { + message.error(errormsg); + } + }).catch(() => this.setState({ loading: { ...this.state.loading, feedback: false } })); + }; renderReqBtns = () => { - const { selectedKey, accountExceptInfo } = this.state; + const { selectedKey, accountExceptInfo, loading } = this.state; let reqBtns = []; switch (selectedKey) { case "calc": @@ -151,6 +177,10 @@ class Index extends Component { this.doCacl("ALL")} overlay={menu} type="primary"> {getLabel(543545, "核算所有人")} , + , + , , this.calc.openAdvanceSearch()} onAdvanceSearch={() => this.calc.onAdSearch(false)}/> diff --git a/pc4mobx/hrmSalary/pages/ledgerPage/components/incomeTaxFieldsCorresponding.js b/pc4mobx/hrmSalary/pages/ledgerPage/components/incomeTaxFieldsCorresponding.js new file mode 100644 index 00000000..468288c0 --- /dev/null +++ b/pc4mobx/hrmSalary/pages/ledgerPage/components/incomeTaxFieldsCorresponding.js @@ -0,0 +1,147 @@ +/* + * + * 个税字段对应 + * @Author: 黎永顺 + * @Date: 2024/6/17 + * @Wechat: + * @Email: 971387674@qq.com + * @description: +*/ +import React, { Component } from "react"; +import { WeaLocaleProvider, WeaSearchGroup, WeaTab } from "ecCom"; +import LedgerFieldsItemPopver from "./ledgerFieldsItemPopver"; +import { taxruleGetForm } from "../../../apis/ledger"; +import LedgerFieldsTable from "./ledgerFieldsTable"; + +const { getLabel } = WeaLocaleProvider; + +class IncomeTaxFields extends Component { + constructor(props) { + super(props); + this.state = { + selectedKey: "", tabs: [], + incomeTaxFields: [], keywords: "" + }; + } + + componentDidMount() { + this.taxruleGetForm(); + } + + taxruleGetForm = () => { + const { editId, saveSalarySobId } = this.props; + taxruleGetForm({ id: editId || saveSalarySobId }).then(({ status, data }) => { + if (status && !_.isEmpty(data)) { + this.setState({ + tabs: _.map(data, it => ({ viewcondition: it.incomeCategoryId, title: it.incomeCategoryName })), + selectedKey: _.take(data)[0].incomeCategoryId, + incomeTaxFields: _.map(data, it => ({ + ...it, taxReportRules: _.map(it.taxRules, o => ({ + ...o, canEdit: o.canEdit, id: "", reportColumnDataIndex: o.taxIndex, reportColumnName: o.name, + salaryItem: [{ id: o.salaryItemId, name: o.salaryItemName }] + })) + })) + }, () => this.props.onSetTaxreportrule(this.state.incomeTaxFields, this.state.selectedKey)); + } + }); + }; + handleChangeSwitch = (visible, id) => { + const { incomeTaxFields, selectedKey } = this.state; + this.setState({ + incomeTaxFields: _.map(incomeTaxFields, it => { + if (it.incomeCategoryId === selectedKey) { + return { + ...it, + taxReportRules: _.map(it.taxReportRules, child => { + if (child.id === id) { + return { ...child, visible }; + } + return { ...child, visible: false }; + }) + }; + } + return { ...it }; + }) + }, () => this.props.onSetTaxreportrule(this.state.incomeTaxFields, this.state.selectedKey)); + }; + handleChangeIncomeFieldsItem = (salaryItem, recordRuleId) => { + const { incomeTaxFields, selectedKey } = this.state; + this.setState({ + incomeTaxFields: _.map(incomeTaxFields, it => { + if (it.incomeCategoryId === selectedKey) { + return { + ...it, + taxReportRules: _.map(it.taxReportRules, child => { + if (child.id === recordRuleId) { + return { ...child, visible: false, salaryItem }; + } + return { ...child, visible: false }; + }) + }; + } + return { ...it }; + }) + }, () => { + this.props.onSetTaxreportrule(this.state.incomeTaxFields, this.state.selectedKey); + }); + }; + + render() { + const { editId, saveSalarySobId } = this.props; + const { selectedKey, tabs, incomeTaxFields, keywords } = this.state; + const list = _.map(incomeTaxFields, it => { + if (it.incomeCategoryId === selectedKey) { + return { + ...it, + taxReportRules: _.filter(it.taxReportRules, item => item.reportColumnName.indexOf(keywords) !== -1) + }; + } + return { ...it }; + }); + const dataSource = _.takeWhile(list, it => it.incomeCategoryId === selectedKey); + return ( + + this.setState({ keywords: val })} + /> + + } + > + + {getLabel(111, "个税申报表字段")} + {/**/} + , + width: "50%", + dataIndex: "reportColumnName" + }, + { + title: getLabel(111, "对应本账套薪资项目"), + width: "50%", + dataIndex: "salaryItem", + render: (_, record) => ( + + ) + } + ]} + dataSource={dataSource} + /> + + ); + } +} + +export default IncomeTaxFields; diff --git a/pc4mobx/hrmSalary/pages/ledgerPage/components/index.less b/pc4mobx/hrmSalary/pages/ledgerPage/components/index.less index bcdacf71..e5971341 100644 --- a/pc4mobx/hrmSalary/pages/ledgerPage/components/index.less +++ b/pc4mobx/hrmSalary/pages/ledgerPage/components/index.less @@ -9,7 +9,19 @@ } } -.ledgerSlideContent { +.ledgerSlideLayout { + .wea-new-top { + .ant-col-10 { + padding-right: 45px !important; + } + } + + .wea-new-top-req-wapper .wea-new-top-req-title > div:last-child { + right: 45px !important; + } + + .ledgerSlideContent { + } } .copyWrapper { diff --git a/pc4mobx/hrmSalary/pages/ledgerPage/components/ledgerBaseSetting.js b/pc4mobx/hrmSalary/pages/ledgerPage/components/ledgerBaseSetting.js index ad86439e..45022954 100644 --- a/pc4mobx/hrmSalary/pages/ledgerPage/components/ledgerBaseSetting.js +++ b/pc4mobx/hrmSalary/pages/ledgerPage/components/ledgerBaseSetting.js @@ -5,11 +5,11 @@ * Date: 2022/12/9 */ import React, { Component } from "react"; -import { WeaCheckbox, WeaFormItem, WeaHelpfulTip, WeaInput, WeaSelect, WeaTextarea } from "ecCom"; +import { WeaCheckbox, WeaFormItem, WeaHelpfulTip, WeaInput, WeaLocaleProvider, WeaSelect, WeaTextarea } from "ecCom"; import { Col, Row } from "antd"; import { inject, observer } from "mobx-react"; import { baseSettingFormItem } from "../config"; -import { getLedgerBasicForm } from "../../../apis/ledger"; +import { getIncomeCategoryList, getLedgerBasicForm } from "../../../apis/ledger"; import { generateBasicInfo, getAddMonthYearMonth, @@ -18,10 +18,12 @@ import { getSubtractMonthYearMonth, prefixAddZero } from "../../../util/date"; -import { commonEnumList } from "../../../apis/ruleconfig"; import moment from "moment"; +import cs from "classnames"; import "./index.less"; +const getLabel = WeaLocaleProvider.getLabel; + @inject("taxAgentStore") @observer class LedgerBaseSetting extends Component { @@ -124,10 +126,7 @@ class LedgerBaseSetting extends Component { }); }; commonEenumList = () => { - const payload = { - enumClass: "com.engine.salary.enums.salarysob.IncomeCategoryEnum" - }; - commonEnumList(payload).then(({ status, data }) => { + getIncomeCategoryList().then(({ status, data }) => { if (status) { const { baseForm } = this.state; this.setState({ @@ -135,7 +134,16 @@ class LedgerBaseSetting extends Component { if (it.key === "taxableItems") { return { ...it, - options: _.map(data, it => ({ key: it.value.toString(), showname: it.defaultLabel })) + options: _.map(data, it => ({ + key: it.value.toString(), + showname:
+ {it.defaultLabel} + + {it.reportTypeName} + +
+ })) }; } return { ...it }; diff --git a/pc4mobx/hrmSalary/pages/ledgerPage/components/ledgerSlide.js b/pc4mobx/hrmSalary/pages/ledgerPage/components/ledgerSlide.js index 1395aed8..6f2c8379 100644 --- a/pc4mobx/hrmSalary/pages/ledgerPage/components/ledgerSlide.js +++ b/pc4mobx/hrmSalary/pages/ledgerPage/components/ledgerSlide.js @@ -8,20 +8,23 @@ import React, { Component } from "react"; import { inject, observer } from "mobx-react"; import { WeaLocaleProvider, WeaSlideModal, WeaSteps } from "ecCom"; import { Button, message, Modal } from "antd"; -import SlideModalTitle from "../../../components/slideModalTitle"; import LedgerBaseSetting from "./ledgerBaseSetting"; import LedgerAssociatedPersonnel from "./ledgerAssociatedPersonnel"; import LedgerSalaryAdjustmentRules from "./ledgerSalaryAdjustmentRules"; import LedgerBackCalculatedSalaryItem from "./ledgerBackCalculatedSalaryItem"; import LedgerSalaryItem from "./ledgerSalaryItem"; import IncomeTaxFields from "./incomeTaxFields"; +import IncomeTaxFieldsCorresponding from "./incomeTaxFieldsCorresponding"; import CumulativeFields from "./cumulativeFields"; +import WeaTopTitle from "../../../components/custom-title/weaTopTitle"; +import WeaReqTitle from "../../../components/custom-title/weaReqTitle"; import { addupruleSave, saveAdjustmentRule, saveLedgerBasic, saveLedgerItem, - taxreportruleSave + taxreportruleSave, + taxruleSave } from "../../../apis/ledger"; import "./index.less"; @@ -39,6 +42,7 @@ class LedgerSlide extends Component { baseSettingInfo: {}, adjustRules: [], empFields: [], itemGroups: [], + taxruleFields: [], taxruleKeys: "", //个税字段对应 incomeTaxFields: [], incomeTaxKeys: "", //个税申报字段对应 addupruleFields: [], addupruleKeys: "", //累计字段对应 saveSalarySobId: "", @@ -147,6 +151,45 @@ class LedgerSlide extends Component { } }).catch(() => this.setState({ loading: false })); }; + /* + * Author: 黎永顺 + * Description:个税字段对应-保存 + * Params: + * Date: 2023/8/16 + */ + taxRuleSave = () => { + const { editId } = this.props; + const { taxruleKeys, taxruleFields, saveSalarySobId } = this.state; + const payload = { + salarySobId: editId || saveSalarySobId, + incomeCategoryParams: _.map(taxruleFields, it => { + if (it.incomeCategoryId === taxruleKeys) { + return { + incomeCategory: it.incomeCategoryId, + taxRuleParams: _.map(it.taxReportRules, child => { + return { + taxIndex: child.reportColumnDataIndex, + salaryItemId: _.map(child.salaryItem, o => o.id).join(",") + }; + }) + }; + } + return { + incomeCategory: it.incomeCategoryId, + taxRuleParams: [] + }; + }) + }; + this.setState({ loading: true }); + taxruleSave(payload).then(({ status, errormsg }) => { + this.setState({ loading: false }); + if (status) { + message.success(getLabel(22619, "保存成功!")); + } else { + message.error(errormsg || getLabel(22620, "保存失败!")); + } + }).catch(() => this.setState({ loading: false })); + }; /* * Author: 黎永顺 * Description:个税申报字段对应-保存 @@ -154,33 +197,29 @@ class LedgerSlide extends Component { * Date: 2023/8/16 */ taxreportruleSave = () => { - const { taxableItems, incomeTaxKeys, incomeTaxFields, saveSalarySobId } = this.state; const { editId } = this.props; - if ((!editId && taxableItems && taxableItems.toString() !== "1" && taxableItems.toString() !== "489")) { - this.saveLedgerAdjustRule(); - } else { - const payload = { - salarySobId: editId || saveSalarySobId, - incomeCategoryParams: _.map(incomeTaxFields, it => { - if (it.incomeCategoryId === incomeTaxKeys) { - return { - incomeCategory: it.incomeCategoryId, - taxReportRuleParams: _.map(it.taxReportRules, child => { - return { - reportColumnDataIndex: child.reportColumnDataIndex, - salaryItemId: _.map(child.salaryItem, o => o.id).join(",") - }; - }) - }; - } + const { incomeTaxKeys, incomeTaxFields, saveSalarySobId } = this.state; + const payload = { + salarySobId: editId || saveSalarySobId, + incomeCategoryParams: _.map(incomeTaxFields, it => { + if (it.incomeCategoryId === incomeTaxKeys) { return { incomeCategory: it.incomeCategoryId, - taxReportRuleParams: [] + taxReportRuleParams: _.map(it.taxReportRules, child => { + return { + reportColumnDataIndex: child.reportColumnDataIndex, + salaryItemId: _.map(child.salaryItem, o => o.id).join(",") + }; + }) }; - }) - }; - this.saveTaxreportrule(payload); - } + } + return { + incomeCategory: it.incomeCategoryId, + taxReportRuleParams: [] + }; + }) + }; + this.saveTaxreportrule(payload); }; saveTaxreportrule = (payload) => { this.setState({ loading: true }); @@ -200,7 +239,10 @@ class LedgerSlide extends Component { * Date: 2023/8/17 */ addupruleSave = () => { - const { taxableItems, incomeTaxFields, incomeTaxKeys, addupruleFields, addupruleKeys, saveSalarySobId } = this.state; + const { + taxableItems, incomeTaxFields, incomeTaxKeys, addupruleFields, + addupruleKeys, saveSalarySobId + } = this.state; const { editId } = this.props; if ((!editId && taxableItems && taxableItems.toString() !== "1" && taxableItems.toString() !== "489")) { const payload = { @@ -256,21 +298,14 @@ class LedgerSlide extends Component { }).catch(() => this.setState({ loading: false })); } }; - handleChangeSlideTab = (current) => { - this.setState({ current: Number(current) }); - }; - handleClose = () => { - this.setState({ current: 0 }, () => this.props.onCancel()); - }; + handleClose = () => this.setState({ current: 0, baseSettingInfo: {} }, () => this.props.onCancel()); /* * Author: 黎永顺 * Description: 基础信息字段切换 * Params: * Date: 2022/12/9 */ - handleChangeSaveParams = (baseSettingInfo) => { - this.setState({ baseSettingInfo }); - }; + handleChangeSaveParams = (baseSettingInfo) => this.setState({ baseSettingInfo }); /* * Author: 黎永顺 * Description: 薪资项目保存数据 @@ -280,179 +315,132 @@ class LedgerSlide extends Component { handleSaveSalaryItemParams = (empFields, itemGroups) => { this.setState({ empFields, itemGroups }); }; - renderChildren = () => { - const { editId } = this.props; - const { current, saveSalarySobId, taxableItems } = this.state; - let CurrentDom = null; - switch (current) { - case 0: - CurrentDom = this.setState({ taxableItems: val })} - />; - break; - case 1: - CurrentDom = ; - break; - case 2: - CurrentDom = ; - break; - case 3: - CurrentDom = ; - break; - case 4: - CurrentDom = (!editId && taxableItems && taxableItems.toString() !== "1" && taxableItems.toString() !== "489") ? - this.setState({ - incomeTaxFields, - incomeTaxKeys: selectedKey - })}/> : - this.setState({ - addupruleFields, - addupruleKeys: selectedKey - })}/>; - break; - case 5: - CurrentDom = (!editId && taxableItems && taxableItems.toString() !== "1" && taxableItems.toString() !== "489") ? - this.setState({ adjustRules })}/> : - this.setState({ - incomeTaxFields, - incomeTaxKeys: selectedKey - })}/>; - break; - case 6: - CurrentDom = - this.setState({ adjustRules })}/>; - break; - default: - CurrentDom = null; - break; - } - return CurrentDom; - }; - renderCustomOperate = () => { - const { taxAgentStore: { showOperateBtn }, editId } = this.props; - const { current, loading, taxableItems } = this.state; - let CurrentDom = []; - //管理员操作权限 - if (showOperateBtn) { - switch (current) { - case 0: - CurrentDom = [ - - ]; - break; - case 1: - CurrentDom = !editId ? [ - , - - ] : []; - break; - case 2: - CurrentDom = !editId ? - [ - , - , - - ] : [ - - ]; - break; - case 3: - CurrentDom = !editId ? - [ - , - , - - ] : []; - break; - case 4: - CurrentDom = !editId ? - [ - , - , - - ] : [ - - ]; - break; - case 5: - CurrentDom = !editId ? - [ - , - , - - ] : [ - - ]; - break; - case 6: - CurrentDom = !editId ? - [ - , - - ] : [ - - ]; - break; - default: - break; - } - } - return CurrentDom; - }; render() { + const { visible, editId, taxAgentStore: { showOperateBtn } } = this.props; + const { current, taxableItems, saveSalarySobId, loading } = this.state; let tabs = [ - { key: 0, title: getLabel(82751, "基础设置") }, - { key: 1, title: getLabel(543467, "关联人员") }, - { key: 2, title: getLabel(542362, "薪资项目") }, - { key: 3, title: getLabel(543468, "回算薪资项目") }, - { key: 4, title: getLabel(111, "累计字段对应") }, - { key: 5, title: getLabel(111, "个税申报字段对应") }, - { key: 6, title: getLabel(543469, "调薪计薪规则") } + { + key: 0, title: getLabel(82751, "基础设置"), + createBtns: [ + + ], + editBtns: [ + + ], + children: this.setState({ taxableItems: val })} + /> + }, + { + key: 1, title: getLabel(543467, "关联人员"), + createBtns: [ + , + + ], + editBtns: [], + children: + }, + { + key: 2, title: getLabel(542362, "薪资项目"), + createBtns: [ + , + , + + ], + editBtns: [ + + ], + children: + }, + { + key: 3, title: getLabel(543468, "回算薪资项目"), + createBtns: [ + , + , + + ], + editBtns: [], + children: + }, + { + key: 4, title: getLabel(111, "累计字段对应"), + createBtns: [ + , + , + + ], + editBtns: [], + children: this.setState({ + addupruleFields, addupruleKeys: selectedKey + })}/> + }, + { + key: 5, title: getLabel(111, "个税字段对应"), + createBtns: [ + , + , + + ], + editBtns: [], + children: this.setState({ + taxruleFields, taxruleKeys: selectedKey + })}/> + }, + { + key: 6, title: getLabel(111, "个税申报字段对应"), + createBtns: [ + , + , + + ], + editBtns: [], + children: this.setState({ + incomeTaxFields, + incomeTaxKeys: selectedKey + })}/> + }, + { + key: 7, title: getLabel(543469, "调薪计薪规则"), + createBtns: [ + , + + ], + editBtns: [ + + ], + children: this.setState({ adjustRules })}/> + } ]; - const { title, visible, editId, taxAgentStore: { showOperateBtn } } = this.props; - const { current, taxableItems } = this.state; - (taxableItems && taxableItems.toString() !== "1" && taxableItems.toString() !== "489") && (tabs = _.filter(tabs, o => o.key !== 4)); + (taxableItems && taxableItems.toString() !== "1" && taxableItems.toString() !== "489") && + (tabs = _.map(_.filter(tabs, o => o.key !== 4), (k, j) => ({ ...k, key: j }))); return ( { - }} - selectedTab={current} - customOperate={this.renderCustomOperate()} - subItemChange={this.handleChangeSlideTab} - /> + !editId ? current === o.key).createBtns}/> : + current === o.key).editBtns : []} + tabDatas={tabs} selectedKey={String(current)} + onChange={cur => this.setState({ current: parseInt(cur) })}/> } content={
@@ -486,9 +466,7 @@ class LedgerSlide extends Component { } } - { - this.renderChildren() - } + {_.find(tabs, o => current === o.key).children}
} onClose={this.handleClose} diff --git a/pc4mobx/hrmSalary/pages/ledgerPage/index.less b/pc4mobx/hrmSalary/pages/ledgerPage/index.less index 2fc10db7..182042bf 100644 --- a/pc4mobx/hrmSalary/pages/ledgerPage/index.less +++ b/pc4mobx/hrmSalary/pages/ledgerPage/index.less @@ -1,13 +1,3 @@ -.ledgerOuter { - .wea-new-top { - .ant-col-10 { - & > span:nth-child(2) { - margin-top: -6px; - } - } - } -} - .ledgerWrapper { height: 100%; diff --git a/pc4mobx/hrmSalary/style/index.less b/pc4mobx/hrmSalary/style/index.less index 4ce6ef7a..6296eac4 100644 --- a/pc4mobx/hrmSalary/style/index.less +++ b/pc4mobx/hrmSalary/style/index.less @@ -83,3 +83,27 @@ } +//薪资账套-工资类型下拉选项样式自定义 +.reportTypeName-box { + display: flex; + align-items: center; + justify-content: space-between; + + .reportTypeName { + display: flex; + padding: 0 8px; + align-items: center; + color: #ffcd50; + border: 1px solid #ffde8a; + background-color: #fff5db; + border-radius: 2px; + height: 24px; + } + + .danger { + color: #ff666a !important; + border: 1px solid #ffc1c3 !important; + background-color: #ffdfe0 !important; + } +} + From 808936f54024dd35b932b71cd2e484bd2bbff408 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, 17 Jun 2024 17:04:06 +0800 Subject: [PATCH 02/60] =?UTF-8?q?=E5=9C=A8=E7=BA=BF=E7=AE=97=E7=A8=8E?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ledgerPage/components/incomeTaxFieldsCorresponding.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pc4mobx/hrmSalary/pages/ledgerPage/components/incomeTaxFieldsCorresponding.js b/pc4mobx/hrmSalary/pages/ledgerPage/components/incomeTaxFieldsCorresponding.js index 468288c0..3df66b4c 100644 --- a/pc4mobx/hrmSalary/pages/ledgerPage/components/incomeTaxFieldsCorresponding.js +++ b/pc4mobx/hrmSalary/pages/ledgerPage/components/incomeTaxFieldsCorresponding.js @@ -12,6 +12,7 @@ import { WeaLocaleProvider, WeaSearchGroup, WeaTab } from "ecCom"; import LedgerFieldsItemPopver from "./ledgerFieldsItemPopver"; import { taxruleGetForm } from "../../../apis/ledger"; import LedgerFieldsTable from "./ledgerFieldsTable"; +import uuidV4 from "uuid/v4"; const { getLabel } = WeaLocaleProvider; @@ -37,7 +38,7 @@ class IncomeTaxFields extends Component { selectedKey: _.take(data)[0].incomeCategoryId, incomeTaxFields: _.map(data, it => ({ ...it, taxReportRules: _.map(it.taxRules, o => ({ - ...o, canEdit: o.canEdit, id: "", reportColumnDataIndex: o.taxIndex, reportColumnName: o.name, + ...o, canEdit: o.canEdit, id: uuidV4(), reportColumnDataIndex: o.taxIndex, reportColumnName: o.name, salaryItem: [{ id: o.salaryItemId, name: o.salaryItemName }] })) })) From 40d150423132c67862216edd018ecc0e687a7301 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, 19 Jun 2024 10:55:22 +0800 Subject: [PATCH 03/60] =?UTF-8?q?feature/2.14.4.2406.02-=E4=B8=AA=E7=A8=8E?= =?UTF-8?q?=E5=9C=A8=E7=BA=BF=E7=AE=97=E7=A8=8E?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pc4mobx/hrmSalary/apis/calculate.js | 5 ++ .../doCalc/components/salaryEditCalc/index.js | 18 +++- .../components/salaryEditCalc/index.less | 5 ++ .../salaryEditCalc/personAbnormalDialog.js | 84 +++++++++++++++++++ 4 files changed, 109 insertions(+), 3 deletions(-) create mode 100644 pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/personAbnormalDialog.js diff --git a/pc4mobx/hrmSalary/apis/calculate.js b/pc4mobx/hrmSalary/apis/calculate.js index d7f1fb5b..752461e5 100644 --- a/pc4mobx/hrmSalary/apis/calculate.js +++ b/pc4mobx/hrmSalary/apis/calculate.js @@ -286,3 +286,8 @@ export const acctresultCalcTax = (params) => { export const calcTaxFeedback = (params) => { return postFetch("/api/bs/hrmsalary/salaryacct/acctresult/calcTaxFeedback", params); }; +//薪资核算-人员异常 +export const listPage4NotDeclare = (params) => { + return postFetch("/api/bs/hrmsalary/salaryacct/acctemployee/listPage4NotDeclare", params); +}; + diff --git a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/index.js b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/index.js index 54081da1..633a5a92 100644 --- a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/index.js +++ b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/index.js @@ -12,6 +12,7 @@ import EditCalcAdvanceSearchPannel from "./editCalcAdvanceSearchPannel"; import EditCalcTable from "./editCalcTable"; import SalaryMonthTip from "../salaryMonthTip"; import SalaryCalcLayout from "./salaryCalcLayout"; +import PersonAbnormalDialog from "./personAbnormalDialog"; import cs from "classnames"; import "./index.less"; @@ -22,7 +23,8 @@ class Index extends Component { super(props); this.state = { salarySobCycle: {}, showSearchAd: false, - columnDesc: {}, formulaTd: "", showTotalCell: false + columnDesc: {}, formulaTd: "", showTotalCell: false, + perAbnormalDialog: { visible: false, salaryAcctRecordId: "" } }; } @@ -50,7 +52,7 @@ class Index extends Component { }; render() { - const { salarySobCycle, showSearchAd, formulaTd, columnDesc, showTotalCell } = this.state; + const { salarySobCycle, showSearchAd, formulaTd, columnDesc, showTotalCell, perAbnormalDialog } = this.state; const { routeParams: { salaryAcctRecordId } } = this.props; const formulaObj = _.get(columnDesc, [formulaTd]) || {}; return ( this.onAdSearch(false)}> @@ -65,7 +67,13 @@ class Index extends Component { style={{ marginLeft: 10 }} /> -
+
+
this.setState({ + perAbnormalDialog: { visible: true, salaryAcctRecordId } + })}>{getLabel(111, "未报送人员")}:{salarySobCycle.abnormalEmployeeNum} +
+
@@ -87,6 +95,10 @@ class Index extends Component { this.calcTableRef = dom} salarySobId={salarySobCycle.salarySobId} {...this.props} showTotalCell={showTotalCell} onShowFormulaTd={this.handleShowFormulaTa}/> + this.setState({ + perAbnormalDialog: { ...perAbnormalDialog, visible: false } + })}/>
); } diff --git a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/index.less b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/index.less index 3d23810b..614973f1 100644 --- a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/index.less +++ b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/index.less @@ -14,6 +14,11 @@ padding-bottom: 0; height: 46px; margin-bottom: 0; + + .abnormal-text { + color: #ef9502; + cursor: pointer; + } } .formula-detail-area { diff --git a/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/personAbnormalDialog.js b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/personAbnormalDialog.js new file mode 100644 index 00000000..1498fc02 --- /dev/null +++ b/pc4mobx/hrmSalary/pages/calculate/doCalc/components/salaryEditCalc/personAbnormalDialog.js @@ -0,0 +1,84 @@ +/* + * Author: 黎永顺 + * name: 薪资核算-人员异常 + * Description: + * Date: 2023/8/18 + */ +import React, { Component } from "react"; +import { WeaDialog, WeaLocaleProvider, WeaTable } from "ecCom"; +import { listPage4NotDeclare } from "../../../../../apis/calculate"; + +const { getLabel } = WeaLocaleProvider; + +class PersonAbnormalDialog extends Component { + constructor(props) { + super(props); + this.state = { + pageInfo: { current: 1, pageSize: 10, total: 0 }, + loading: false, columns: [], dataSource: [] + }; + } + + componentWillReceiveProps(nextProps, nextContext) { + if (nextProps.visible !== this.props.visible && nextProps.visible) this.queryList(nextProps); + } + + queryList = (props) => { + const { salaryAcctRecordId } = props, { pageInfo } = this.state; + const payload = { ...pageInfo, recordId: salaryAcctRecordId }; + this.setState({ loading: true }); + listPage4NotDeclare(payload).then(({ status, data }) => { + this.setState({ loading: false }); + if (status) { + const { columns, list: dataSource, pageNum: current, pageSize, total } = data; + this.setState({ + dataSource, pageInfo: { ...pageInfo, current, pageSize, total }, columns + }); + } else { + + } + }).catch(() => this.setState({ loading: false })); + }; + + render() { + const { loading, columns, dataSource, pageInfo } = this.state; + const pagination = { + ...pageInfo, + showTotal: total => `${getLabel(18609, "共")} ${total} ${getLabel(18256, "条")}`, + showQuickJumper: true, + showSizeChanger: true, + pageSizeOptions: ["10", "20", "50", "100"], + onShowSizeChange: (current, pageSize) => { + this.setState({ + pageInfo: { ...pageInfo, current, pageSize } + }, () => this.queryList(this.props)); + }, + onChange: current => { + this.setState({ + pageInfo: { ...pageInfo, current } + }, () => this.queryList(this.props)); + } + }; + return ( + +
+ +
+
+ ); + } +} + +export default PersonAbnormalDialog; From da6a8266f6c428f7ec9ce417765a3e8202b871a6 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, 26 Jun 2024 10:02:45 +0800 Subject: [PATCH 04/60] hotfix/2.14.2.2406.02 --- .../analysisOfSalaryStatistics/components/salaryDetails.js | 6 +++++- pc4mobx/hrmSalary/pages/payrollFiles/config/index.js | 3 ++- pc4mobx/hrmSalary/stores/payrollFiles.js | 3 ++- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/salaryDetails.js b/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/salaryDetails.js index 9d8d2816..3f01a8bf 100644 --- a/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/salaryDetails.js +++ b/pc4mobx/hrmSalary/pages/analysisOfSalaryStatistics/components/salaryDetails.js @@ -99,13 +99,17 @@ class SalaryDetails extends Component { }).catch(() => this.setState({ loading: false })); }; handleExportSalaryList = (key) => { + const { attendanceStore: { tableStore } } = this.props; let { selectedRowKeys, payload } = this.state; if (key === "SELECTED" && selectedRowKeys.length === 0) { message.warning(getLabel(543345, "请选择需要导出的数据!")); return; } WeaLoadingGlobal.start(); - const promise = API.exportSalaryList({ ...payload, ids: key === "SELECTED" ? selectedRowKeys : [] }); + const promise = API.exportSalaryList({ + ...payload, ids: key === "SELECTED" ? selectedRowKeys : [], + columns: _.map(_.filter(toJS(tableStore.columns), (item) => item.display === "true" && item.dataIndex !== "acctTimes"), o => o.dataIndex) + }); }; getColumns = () => { const { attendanceStore: { tableStore } } = this.props; diff --git a/pc4mobx/hrmSalary/pages/payrollFiles/config/index.js b/pc4mobx/hrmSalary/pages/payrollFiles/config/index.js index 25b815a0..e1ee1288 100644 --- a/pc4mobx/hrmSalary/pages/payrollFiles/config/index.js +++ b/pc4mobx/hrmSalary/pages/payrollFiles/config/index.js @@ -324,10 +324,11 @@ export const salaryFileSearchConditions = [ }, { conditionType: "SELECT", - domkey: ["taxAgentId"], + domkey: ["taxAgentIds"], fieldcol: 16, label: getLabel(537996, "个税扣缴义务人"), labelcol: 8, + multiple: true, options: [], viewAttr: 2 }, diff --git a/pc4mobx/hrmSalary/stores/payrollFiles.js b/pc4mobx/hrmSalary/stores/payrollFiles.js index c9095936..d70e0113 100644 --- a/pc4mobx/hrmSalary/stores/payrollFiles.js +++ b/pc4mobx/hrmSalary/stores/payrollFiles.js @@ -24,11 +24,12 @@ export class PayrollFilesStore { @action("薪资档案-列表查询") queryList = (payload = {}, searchItemsValue = {}, url = "") => { return new Promise((resolve, reject) => { - const { departmentIds, positionIds, subcompanyIds, statuses, ...extra } = searchItemsValue; + const { departmentIds, positionIds, subcompanyIds, statuses, taxAgentIds, ...extra } = searchItemsValue; API.queryList({ departmentIds: departmentIds ? departmentIds.split(",") : [], positionIds: positionIds ? positionIds.split(",") : [], subcompanyIds: subcompanyIds ? subcompanyIds.split(",") : [], + taxAgentIds: taxAgentIds ? taxAgentIds.split(",") : [], statuses: statuses ? statuses.split(",") : [], ...payload, ...extra, url }).then(res => { From 3ee2ece60d015cb4dc01b6ac5d8d93edf84bbabe 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, 26 Jun 2024 10:07:45 +0800 Subject: [PATCH 05/60] hotfix/2.14.2.2406.02 --- .../components/salaryFileAdvanceSearchPannel/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pc4mobx/hrmSalary/pages/payrollFiles/components/salaryFileAdvanceSearchPannel/index.js b/pc4mobx/hrmSalary/pages/payrollFiles/components/salaryFileAdvanceSearchPannel/index.js index d7b43cd5..3f164873 100644 --- a/pc4mobx/hrmSalary/pages/payrollFiles/components/salaryFileAdvanceSearchPannel/index.js +++ b/pc4mobx/hrmSalary/pages/payrollFiles/components/salaryFileAdvanceSearchPannel/index.js @@ -41,7 +41,7 @@ class salaryFileAdvanceSearchPannel extends Component { ...child, options: _.map(userStatusList, o => ({ key: String(o.value), showname: o.defaultLabel })) }; - } else if (getKey(child) === "taxAgentId") { + } else if (getKey(child) === "taxAgentIds") { return { ...child, options: _.map(taxAgentList, o => ({ key: o.id, showname: o.content })) From 230aea8d622981f10a5b044d252afee387234d05 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, 28 Jun 2024 16:57:05 +0800 Subject: [PATCH 06/60] hotfix/2.14.2.2406.02 --- pc4mobx/hrmSalary/pages/salaryItem/salaryItemForm.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pc4mobx/hrmSalary/pages/salaryItem/salaryItemForm.js b/pc4mobx/hrmSalary/pages/salaryItem/salaryItemForm.js index 12d0c7bf..4a1ed275 100644 --- a/pc4mobx/hrmSalary/pages/salaryItem/salaryItemForm.js +++ b/pc4mobx/hrmSalary/pages/salaryItem/salaryItemForm.js @@ -88,7 +88,7 @@ class SalaryItemForm extends Component { return { ...item, type: dataType === "number" ? "INPUTNUMBER" : "INPUT", - display: valueType && valueType.toString() === "1", + display: valueType && valueType.toString() === "1" && useInEmployeeSalary == 0, viewAttr: (isLedger && record.canEdit) || (editable && record.canEdit) || isAdd ? 2 : 1 }; case "formulaContent": 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 07/60] 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; From 92d72d3eac14866300a447959968dca8b5930535 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, 3 Jul 2024 11:12:15 +0800 Subject: [PATCH 08/60] =?UTF-8?q?release/2.14.4.2406.02-=E4=B8=AA=E7=A8=8E?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pc4mobx/hrmSalary/pages/dataAcquisition/cumSituation/index.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/dataAcquisition/cumSituation/index.js b/pc4mobx/hrmSalary/pages/dataAcquisition/cumSituation/index.js index e9968ff5..73bda8ff 100644 --- a/pc4mobx/hrmSalary/pages/dataAcquisition/cumSituation/index.js +++ b/pc4mobx/hrmSalary/pages/dataAcquisition/cumSituation/index.js @@ -530,7 +530,7 @@ class Index extends Component { }; render() { - const { taxAgentStore: { showOperateBtn }, cumSituationStore: { form } } = this.props; + const { taxAgentStore: { showOperateBtn, taxAgentOption }, cumSituationStore: { form } } = this.props; const { declareMonth, taxAgentId, slidePayload, saveLoading, exportPayloadUrl, advanceCondition, importPayload, year, exportPayloadType, cumTaxPeriodDialog, targetid @@ -549,7 +549,7 @@ class Index extends Component { targetid={targetid} onClearTargrtid={() => this.setState({ targetid: "" })} > this.setState({ cumTaxPeriodDialog: { ...cumTaxPeriodDialog, visible: false, title: "", type: "" } })} From 4e29c4ed936b9804a0f0d3dea4b65676a7d079da 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, 4 Jul 2024 18:50:31 +0800 Subject: [PATCH 09/60] =?UTF-8?q?feature/2.14.4.2406.02-=E4=B8=AA=E7=A8=8E?= =?UTF-8?q?=E9=83=A8=E5=88=86=E6=8E=A5=E5=8F=A3=E6=94=B9=E9=80=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../declareDetail/components/paymentBtn.js | 19 ++++++++++--------- .../hrmSalary/pages/declareDetail/index.js | 6 +++--- .../pages/employeedeclareDetail/index.js | 6 ++++-- 3 files changed, 17 insertions(+), 14 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/declareDetail/components/paymentBtn.js b/pc4mobx/hrmSalary/pages/declareDetail/components/paymentBtn.js index 4f6ad59f..e187d81d 100644 --- a/pc4mobx/hrmSalary/pages/declareDetail/components/paymentBtn.js +++ b/pc4mobx/hrmSalary/pages/declareDetail/components/paymentBtn.js @@ -332,15 +332,16 @@ class PaymentBtn extends Component { const { paymentDialog } = this.state; return ( - - {getLabel(111, "银行端凭证缴款")} - {getLabel(111, "作废缴款凭证")} - - } - type="ghost">{getLabel(111, "三方缴款")} + + {/**/} + {/* {getLabel(111, "银行端凭证缴款")}*/} + {/* {getLabel(111, "作废缴款凭证")}*/} + {/* */} + {/* }*/} + {/* type="ghost">{getLabel(111, "三方缴款")}*/} confirmDialog("cancel", () => this.handleOperateDeclare("cancel", { reportType }))}>{getLabel(111, "作废申报")}, - + // )); if (!intelCalcSalaryStatus) { if (["NOT_DECLARE", "DECLARE_FAIL"].includes(declareInfo.declareStatus)) { diff --git a/pc4mobx/hrmSalary/pages/employeedeclareDetail/index.js b/pc4mobx/hrmSalary/pages/employeedeclareDetail/index.js index ed7805cf..f9783c57 100644 --- a/pc4mobx/hrmSalary/pages/employeedeclareDetail/index.js +++ b/pc4mobx/hrmSalary/pages/employeedeclareDetail/index.js @@ -21,7 +21,8 @@ import { employeedeclareList4Add, employeedeclareList4Update, employeedeclareRefresh, - employeeDelete, employeeInvalid, + employeeDelete, + employeeInvalid, getDeclareFeedback } from "../../apis/declare"; import { advanceConditions, submitStatus } from "./constants"; @@ -146,7 +147,8 @@ class Index extends Component { "总计": getLabel(523, "总计"), "编辑": getLabel(501169, "编辑"), "操作": getLabel(30585, "操作"), "删除": getLabel(535052, "删除"), "共": getLabel(83698, "共"), "条": getLabel(18256, "条"), - "加载中": getLabel(83698, "加载中"), "作废": getLabel(111, "作废") + "加载中": getLabel(83698, "加载中") + // "作废": getLabel(111, "作废") }; const childFrameObj = document.getElementById("atdTable"); childFrameObj && childFrameObj.contentWindow.postMessage(JSON.stringify({ ...payload, i18n }), "*"); From 5f4d52761af705ee6e358c8dd6259ef52ed5b8be 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, 10 Jul 2024 14:35:11 +0800 Subject: [PATCH 10/60] =?UTF-8?q?custom/=E4=B8=8A=E6=B5=B7=E6=B8=AF?= =?UTF-8?q?=E6=B9=BE=E5=A4=9A=E8=AF=AD=E8=A8=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/paymentFeedbackBtn.js | 4 +-- .../components/taxDeclarationInfo.js | 28 +++++++++---------- 2 files changed, 16 insertions(+), 16 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/declareDetail/components/paymentFeedbackBtn.js b/pc4mobx/hrmSalary/pages/declareDetail/components/paymentFeedbackBtn.js index fca56898..ee0bdf44 100644 --- a/pc4mobx/hrmSalary/pages/declareDetail/components/paymentFeedbackBtn.js +++ b/pc4mobx/hrmSalary/pages/declareDetail/components/paymentFeedbackBtn.js @@ -152,8 +152,8 @@ class PaymentFeedbackBtn extends Component { return { ...it, options: [ - { key: "WITHHOLDING_PAY", showname: getLabel(111, "三方缴款") }, - { key: "WITHHOLDING_VOUCHER", showname: getLabel(111, "缴款凭证打印") } + { key: "WITHHOLDING_PAY", showname: getLabel(111, "三方缴款"), selected: true }, + // { key: "WITHHOLDING_VOUCHER", showname: getLabel(111, "缴款凭证打印") } ] }; }) diff --git a/pc4mobx/hrmSalary/pages/declareDetail/components/taxDeclarationInfo.js b/pc4mobx/hrmSalary/pages/declareDetail/components/taxDeclarationInfo.js index ec5edc9c..16eb0b9b 100644 --- a/pc4mobx/hrmSalary/pages/declareDetail/components/taxDeclarationInfo.js +++ b/pc4mobx/hrmSalary/pages/declareDetail/components/taxDeclarationInfo.js @@ -55,20 +55,20 @@ class TaxDeclarationInfo extends Component { ]; let dropMenuDatas = []; if (["DECLARE_SUCCESS_NO_PAY", "DECLARE_SUCCESS_UNPAID", "DECLARE_SUCCESS_PAID", "DECLARE_SUCCESS_PAYING"].includes(declareInfo.declareStatus)) { - dropMenuDatas = dropMenuDatas.concat([ - { - key: "exportGetDeclareTaxResultFeedback", - icon: , - content: getLabel(111, "下载申报内置算税结果"), - onClick: onOperate - }, - { - key: "onlineComparison", - icon: , - content: getLabel(111, "在线对比"), - onClick: onOperate - } - ]); + // dropMenuDatas = dropMenuDatas.concat([ + // { + // key: "exportGetDeclareTaxResultFeedback", + // icon: , + // content: getLabel(111, "下载申报内置算税结果"), + // onClick: onOperate + // }, + // { + // key: "onlineComparison", + // icon: , + // content: getLabel(111, "在线对比"), + // onClick: onOperate + // } + // ]); } return (
From 4d2058b180951384bc3d6cfb8003fdb32edff7ef 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, 11 Jul 2024 15:05:00 +0800 Subject: [PATCH 11/60] hotfix/2.14.2.2406.02 --- .../reportView/components/reportContent.js | 22 +++++++++++++------ 1 file changed, 15 insertions(+), 7 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/reportView/components/reportContent.js b/pc4mobx/hrmSalary/pages/reportView/components/reportContent.js index a7808410..98486950 100644 --- a/pc4mobx/hrmSalary/pages/reportView/components/reportContent.js +++ b/pc4mobx/hrmSalary/pages/reportView/components/reportContent.js @@ -6,7 +6,7 @@ */ import React, { Component } from "react"; import { Spin } from "antd"; -import { WeaEchart } from "ecCom"; +import { WeaEchart, WeaLocaleProvider } from "ecCom"; import RightOptions from "./rightOptions"; import ChartsRangeSettingsModal from "./chartsRangeSettingsModal"; import { mapBarOptions, mapLineOptions, mapPieOptions } from "./condition"; @@ -15,6 +15,8 @@ import PovitpivotChartModal from "./povitpivotChartModal"; import { getSalaryMonthValue } from "./statisticalMicroSettingsSlide"; import "../index.less"; +const getLabel = WeaLocaleProvider.getLabel; + class ReportContent extends Component { constructor(props) { super(props); @@ -33,7 +35,8 @@ class ReportContent extends Component { rangSet: { visible: false, reportId: "", rangeVal: {} - } + }, + pageInfo: { current: 0, pageSize: 10, total: 0 } }; } @@ -76,24 +79,29 @@ class ReportContent extends Component { } }; postMessageToChild = (payload) => { + const i18n = { + "共": getLabel(18609, "共"), "条": getLabel(18256, "条"), + "总计": getLabel(523, "总计") + }; const childFrameObj = document.getElementById("atdTable"); const { dataSource, columns, showSum, countResult } = payload; childFrameObj && childFrameObj.contentWindow.postMessage(JSON.stringify({ - dataSource, columns, showSum, countResult + dataSource, columns, showSum, countResult, i18n }), "*"); }; reportStatisticsReportGetData = (params) => { + const { pageInfo } = this.state; const { id, dimensionId, isShare, timeType, salaryEndMonth: end, salaryStartMonth: start } = params; const [salaryStartMonth, salaryEndMonth] = getSalaryMonthValue(timeType); const payload = { - id, dimensionId, isShare, + id, dimensionId, isShare, ...pageInfo, salaryStartMonth: (salaryStartMonth || start) + "-01", salaryEndMonth: (salaryEndMonth || end) + "-01" }; this.setState({ loading: true }); reportStatisticsReportGetData(payload).then(({ status, data }) => { this.setState({ loading: false }); if (status && id.toString() === data.reportId.toString()) { - const { countResult, columns, pageInfo: { list } } = data; + const { countResult, columns, pageInfo: { list, pageNum, pageSize, total } } = data; this.setState({ countResult, columns: _.map(columns, it => ({ @@ -244,8 +252,8 @@ class ReportContent extends Component { viewType === "dataView" ?