diff --git a/pc4mobx/hrmSalary/apis/declare.js b/pc4mobx/hrmSalary/apis/declare.js
index 76709840..a2c7d63f 100644
--- a/pc4mobx/hrmSalary/apis/declare.js
+++ b/pc4mobx/hrmSalary/apis/declare.js
@@ -232,4 +232,11 @@ export const taxdeclarationEdit = (params) => {
export const getTaxdeclarationDetailInfo = (params) => {
return WeaTools.callApi("/api/bs/hrmsalary/taxdeclaration/detailInfo", "GET", params);
};
-
+//人员信息报送-下载人员信息报送导入模板
+export const employeedeclareExportTemplate = params => {
+ return postExportFetch("/api/bs/hrmsalary/employeedeclare/exportTemplate", params);
+};
+//人员信息报送-人员信息报送导入
+export const employeedeclareImportData = (params) => {
+ return postFetch("/api/bs/hrmsalary/employeedeclare/importData", params);
+};
diff --git a/pc4mobx/hrmSalary/components/moreBtnMenu/index.js b/pc4mobx/hrmSalary/components/moreBtnMenu/index.js
new file mode 100644
index 00000000..205b0f8b
--- /dev/null
+++ b/pc4mobx/hrmSalary/components/moreBtnMenu/index.js
@@ -0,0 +1,59 @@
+/*
+ * Author: 黎永顺
+ * name: 更多菜单列表
+ * Description:
+ * Date: 2023/12/28
+ */
+import React, { Component } from "react";
+import { WeaLocaleProvider } from "ecCom";
+import { Menu } from "antd";
+import "./index.less";
+
+const getLabel = WeaLocaleProvider.getLabel;
+
+class Index extends Component {
+ constructor(props) {
+ super(props);
+ this.state = {
+ showDrop: false
+ };
+ }
+
+ render() {
+ const { showDrop } = this.state;
+ const { dropMenuDatas } = this.props;
+ const menu = dropMenuDatas ?
+
: "";
+ return (
+
+
this.setState({ showDrop: true })}>
+
+
+
this.setState({ showDrop: false })}
+ style={{ display: showDrop ? "block" : "none" }}>
+
this.setState({ showDrop: false })}>
+
+
+
+ {menu}
+
+
+ );
+ }
+}
+
+export default Index;
diff --git a/pc4mobx/hrmSalary/components/moreBtnMenu/index.less b/pc4mobx/hrmSalary/components/moreBtnMenu/index.less
new file mode 100644
index 00000000..e1a2fc8c
--- /dev/null
+++ b/pc4mobx/hrmSalary/components/moreBtnMenu/index.less
@@ -0,0 +1,61 @@
+.more-btn-menu-wrapper {
+ position: relative;
+
+ .more-btn {
+ display: inline-block;
+ padding-left: 20px;
+ line-height: 40px;
+ vertical-align: middle;
+ cursor: pointer;
+
+ .more-btn-icon {
+ font-size: 16px;
+ color: #484848;
+ cursor: pointer;
+ }
+ }
+
+ .more-btn-menu {
+ max-width: 200px;
+ position: absolute;
+ right: -14px;
+ top: 45px;
+ border: 1px solid #dadada;
+ -webkit-box-shadow: 0 0 2px #dadada;
+ box-shadow: 0 0 2px #dadada;
+ z-index: 99;
+ -webkit-box-sizing: border-box;
+ box-sizing: border-box;
+
+ .more-btn {
+ display: block;
+ -webkit-box-sizing: border-box;
+ box-sizing: border-box;
+ height: 44px;
+ line-height: 35px;
+ position: absolute;
+ right: -1px;
+ top: -44px;
+ padding: 0 13px;
+ border: 1px solid #dadada;
+ border-bottom: 0;
+ -webkit-box-shadow: 0 -1px 2px -1px #dadada;
+ box-shadow: 0 -1px 2px -1px #dadada;
+ background-color: #fff;
+ }
+
+ .more-btn-menu-icon-background {
+ width: 36px;
+ height: 100%;
+ background-color: #f2f5f7;
+ border: 1px solid #dadada;
+ border-right: 0;
+ position: absolute;
+ top: -1px;
+ left: -1px;
+ z-index: 0;
+ -webkit-box-sizing: content-box;
+ box-sizing: content-box;
+ }
+ }
+}
diff --git a/pc4mobx/hrmSalary/pages/declareDetail/components/taxDeclarationInfo.js b/pc4mobx/hrmSalary/pages/declareDetail/components/taxDeclarationInfo.js
index bf09f80f..a84159dd 100644
--- a/pc4mobx/hrmSalary/pages/declareDetail/components/taxDeclarationInfo.js
+++ b/pc4mobx/hrmSalary/pages/declareDetail/components/taxDeclarationInfo.js
@@ -8,6 +8,7 @@ import React, { Component } from "react";
import { message, Tag } from "antd";
import { WeaLocaleProvider } from "ecCom";
import DeclareResultDialog from "./declareResultDialog";
+import MoreBtnMenu from "../../../components/moreBtnMenu";
import { taxdeclarationUpdateIcon } from "../../../apis/declare";
import { getQueryString } from "../../../util/url";
@@ -92,6 +93,7 @@ class TaxDeclarationInfo extends Component {
onClick={() => this.handleSeeResult([{ key: "list4Fail" }], getLabel(111, "申报失败数据"))}>
{getLabel(111, "申报失败数据")}({declareFailSize || 0})
+
{
diff --git a/pc4mobx/hrmSalary/pages/declareDetail/index.js b/pc4mobx/hrmSalary/pages/declareDetail/index.js
index 86906901..c79603cf 100644
--- a/pc4mobx/hrmSalary/pages/declareDetail/index.js
+++ b/pc4mobx/hrmSalary/pages/declareDetail/index.js
@@ -115,6 +115,8 @@ class Index extends Component {
visible: true, id: params.id,
title: getLabel(501169, "编辑")
});
+ } else if (id === "DELETE") {
+
}
}
};
@@ -123,7 +125,7 @@ class Index extends Component {
const i18n = {
"总计": getLabel(523, "总计"), "编辑": getLabel(501169, "编辑"),
"操作": getLabel(30585, "操作"), "共": getLabel(83698, "共"),
- "条": getLabel(18256, "条")
+ "条": getLabel(18256, "条"), "删除": getLabel(535052, "删除")
};
const declareStatus = intelCalcSalaryStatus ? declareInfo.declareStatus : "";
const childFrameObj = document.getElementById("atdTable");
diff --git a/pc4mobx/hrmSalary/pages/employeedeclareDetail/components/employeeDeclareDetailImportDialog.js b/pc4mobx/hrmSalary/pages/employeedeclareDetail/components/employeeDeclareDetailImportDialog.js
new file mode 100644
index 00000000..9b7191a5
--- /dev/null
+++ b/pc4mobx/hrmSalary/pages/employeedeclareDetail/components/employeeDeclareDetailImportDialog.js
@@ -0,0 +1,116 @@
+/*
+ * Author: 黎永顺
+ * name: 人员信息报送-导入
+ * Description:
+ * Date: 2023/12/28
+ */
+import React, { Component } from "react";
+import { WeaCheckbox, WeaLocaleProvider, WeaSelect } from "ecCom";
+import { message } from "antd";
+import ImportDialog from "../../../components/importDialog";
+import * as API from "../../../apis/declare";
+
+const getLabel = WeaLocaleProvider.getLabel;
+
+class EmployeeDeclareDetailImportDialog extends Component {
+ constructor(props) {
+ super(props);
+ this.state = {
+ importDialog: {
+ visible: false, title: "", nextloading: false, checkType: "jobNum",
+ link: null, importResult: {}, imageId: "", tempPayload: {},
+ previewUrl: "/api/bs/hrmsalary/employeedeclare/preview"
+ }
+ };
+ }
+
+ handleImportEmployeeDeclare = (tempPayload) => {
+ this.setState({
+ importDialog: {
+ ...this.state.importDialog, link: this.handleExportTemp,
+ tempPayload, visible: true, title: getLabel(24023, "数据导入")
+ }
+ });
+ };
+ handleImport = (payload) => {
+ const { importDialog } = this.state;
+ const { tempPayload, checkType } = importDialog;
+ this.setState({ importDialog: { ...importDialog, nextloading: true } });
+ API.employeedeclareImportData({ ...payload, ...tempPayload, checkType })
+ .then(({ data, status }) => {
+ this.setState({ importDialog: { ...importDialog, nextloading: false } });
+ if (status) {
+ this.setState({
+ importDialog: { ...importDialog, ...payload, importResult: data }
+ }, () => this.props.onSuccess());
+ }
+ }).catch(() => this.setState({ importDialog: { ...importDialog, nextloading: false } }));
+ };
+ handleExportTemp = () => {
+ const { importDialog: { tempPayload } } = this.state;
+ message.destroy();
+ message.loading(getLabel(111, "下载中"), 0);
+ const promise = API.employeedeclareExportTemplate(tempPayload);
+ message.destroy();
+ };
+ handleCancel = () => {
+ this.setState({
+ importDialog: {
+ visible: false, title: "", nextloading: false, checkType: "jobNum",
+ link: null, importResult: {}, imageId: "", tempPayload: {},
+ previewUrl: "/api/bs/hrmsalary/employeedeclare/preview"
+ }
+ });
+ };
+ renderFormComponent = () => {
+ const { importDialog } = this.state;
+ const { checkType } = importDialog;
+ return
+
+
+
{getLabel(111, "校验字段")}
+
{
+ this.setState(({ importDialog: { ...importDialog, checkType } }));
+ }} options={[
+ { key: "jobNum", showname: getLabel(1933, "工号") },
+ { key: "sfz", showname: getLabel(1887, "身份证号码") }
+ ]}
+ />
+
+
+
;
+ };
+
+ render() {
+ const { importDialog } = this.state;
+ return (
+ this.setState(({
+ importDialog: { ...importDialog, importResult: {}, imageId: "" }
+ }))}
+ importParams={this.renderFormComponent()}
+ exportDataDom={
+ {
+ this.setState(({
+ importDialog: {
+ ...importDialog,
+ tempPayload: { ...importDialog.tempPayload, exportData: String(val === "1") }
+ }
+ }));
+ }}
+ />
+ }
+ nextCallback={imageId => this.setState({ importDialog: { ...importDialog, imageId } })}
+ nextUplaodCallback={imageId => this.handleImport({ imageId })}
+ />
+ );
+ }
+}
+
+export default EmployeeDeclareDetailImportDialog;
diff --git a/pc4mobx/hrmSalary/pages/employeedeclareDetail/index.js b/pc4mobx/hrmSalary/pages/employeedeclareDetail/index.js
index c32277ec..d6e68376 100644
--- a/pc4mobx/hrmSalary/pages/employeedeclareDetail/index.js
+++ b/pc4mobx/hrmSalary/pages/employeedeclareDetail/index.js
@@ -11,6 +11,7 @@ import { WeaDatePicker, WeaLocaleProvider, WeaSelect, WeaTab, WeaTop } from "ecC
import { Button, Dropdown, Menu, message, Modal, Spin } from "antd";
import BaseInfo from "./components/baseInfo";
import EmployeeDeclareDetailSchemaEditDialog from "./components/employeeDeclareDetailSchemaEditDialog";
+import EmployeeDeclareDetailSchemaImportDialog from "./components/employeeDeclareDetailImportDialog";
import { commonEnumList } from "../../apis/payrollFiles";
import {
employeedeclareDeclare,
@@ -51,6 +52,7 @@ class Index extends Component {
selectedRowKeys: [], exportPayload: {}
};
this.baseInfoRef = null;
+ this.importRef = null;
this.timer = null;
}
@@ -399,6 +401,19 @@ class Index extends Component {
}, ["current", "total", "pageSize"]));
this.setState({ loading: { ...this.state.loading, exportLoading: false } });
};
+ handleEmployeedeclare = ({ key }) => {
+ switch (key) {
+ case "import":
+ const tmplateExpPayload = {
+ exportData: "false", taxAgentId: getQueryString("id"),
+ taxCycle: moment(this.state.taxCycle).startOf("month").format("YYYY-MM-DD")
+ };
+ this.importRef.handleImportEmployeeDeclare(tmplateExpPayload);
+ break;
+ default:
+ break;
+ }
+ };
render() {
const {
@@ -417,11 +432,7 @@ class Index extends Component {
const buttons = [
this.setState({
- taxCycle: val,
- pageInfo: {
- ...pageInfo,
- current: 1
- }
+ taxCycle: val, pageInfo: { ...pageInfo, current: 1 }
}, () => this.queryEmployeeList())}/>,
,
@@ -442,8 +453,8 @@ class Index extends Component {
- {getLabel(32935, "导入")}
+
}
type="primary">{getLabel(1421, "新增")},
@@ -544,6 +555,9 @@ class Index extends Component {
});
}}
/>
+ {/*人员信息报送导入*/}
+ this.importRef = dom}
+ onSuccess={this.queryEmployeeList}/>
diff --git a/pc4mobx/hrmSalary/pages/employeedeclareDetail/index.less b/pc4mobx/hrmSalary/pages/employeedeclareDetail/index.less
index e0118144..af9ffbdc 100644
--- a/pc4mobx/hrmSalary/pages/employeedeclareDetail/index.less
+++ b/pc4mobx/hrmSalary/pages/employeedeclareDetail/index.less
@@ -178,3 +178,23 @@
.a-center {
align-items: center;
}
+
+.weapp-salary-tb-filter {
+ display: flex;
+ align-items: center;
+
+ .tbf-item {
+ display: flex;
+ align-items: center;
+
+ .tbfi-label {
+ flex-basis: 100px;
+ flex-shrink: 0;
+ }
+
+ .wea-select {
+ flex-basis: 200px;
+ flex-shrink: 0;
+ }
+ }
+}