feature/2.12.1.2403.02-个税-外籍人员信息报送

This commit is contained in:
黎永顺 2024-03-28 17:25:39 +08:00
parent a27beae87e
commit 668a8aed54
2 changed files with 54 additions and 6 deletions

View File

@ -84,7 +84,7 @@ class EmployeeDeclareDetailSchemaEditDialog extends Component {
]
};
}
if (child.conditionType === "SELECT" && getKey(child) !== "gender" && getKey(child) !== "employmentStatus" && getKey(child) !== "employmentType") {
if (child.conditionType === "SELECT" && getKey(child) !== "gender" && getKey(child) !== "employmentStatus" && getKey(child) !== "employmentType" && getKey(child) !== "taxReasons") {
return {
...child,
options: [
@ -213,7 +213,10 @@ class EmployeeDeclareDetailSchemaEditDialog extends Component {
return {
...it,
items: _.map(it.items, child => {
if (getKey(child) === "entryDate" || getKey(child) === "departureDate") {
if (
getKey(child) === "entryDate" || getKey(child) === "departureDate" ||
getKey(child) === "birthplace" || getKey(child) === "taxReasons"
) {
return {
...child,
viewAttr: value !== "RESIDENT_IDENTITY_CARDS" ? 3 : 2
@ -247,15 +250,18 @@ class EmployeeDeclareDetailSchemaEditDialog extends Component {
form.validateForm().then(f => {
if (f.isValid) {
const {
employmentType, employmentDate, employmentStatus, dismissDate, cardType, entryDate, departureDate, ...params
employmentType, employmentDate, employmentStatus, dismissDate, cardType, entryDate, departureDate,
birthplace, taxReasons, ...params
} = form.getFormParams();
if ((employmentType !== "OTHER" && !employmentDate) || (employmentStatus === "ABNORMAL" && !dismissDate)) {
form.showError("dismissDate", getLabel(111, "\"离职日期\"未填写"));
return;
}
if ((cardType !== "RESIDENT_IDENTITY_CARDS" && !entryDate && !departureDate)) {
if ((cardType !== "RESIDENT_IDENTITY_CARDS" && !entryDate && !departureDate && !birthplace && !taxReasons)) {
form.showError("entryDate", getLabel(111, "\"首次入境时间\"未填写"));
form.showError("departureDate", getLabel(111, "\"预计离境时间\"未填写"));
form.showError("birthplace", getLabel(111, "\"出生地\"未填写"));
form.showError("taxReasons", getLabel(111, "\"涉税事由\"未填写"));
return;
}
if ((cardType !== "RESIDENT_IDENTITY_CARDS" && !entryDate)) {
@ -266,10 +272,19 @@ class EmployeeDeclareDetailSchemaEditDialog extends Component {
form.showError("departureDate", getLabel(111, "\"预计离境时间\"未填写"));
return;
}
if ((cardType !== "RESIDENT_IDENTITY_CARDS" && !birthplace)) {
form.showError("birthplace", getLabel(111, "\"出生地\"未填写"));
return;
}
if ((cardType !== "RESIDENT_IDENTITY_CARDS" && !taxReasons)) {
form.showError("taxReasons", getLabel(111, "\"涉税事由\"未填写"));
return;
}
const payload = {
...form.getFormParams(), id: this.props.id,
taxAgentId: getQueryString("id"),
taxCycle: this.props.taxCycle
taxCycle: this.props.taxCycle,
taxReasons: taxReasons.split(",")
};
this.setState({ loading: true });
getEmployeeSave(payload).then(({ status, errormsg }) => {

View File

@ -1,3 +1,7 @@
import React from "react";
import { WeaLocaleProvider } from "ecCom";
const { getLabel } = WeaLocaleProvider;
export const submitStatus = [
{
key: "ALL",
@ -255,7 +259,7 @@ export const declareConditions = [
lanId: 111,
labelcol: 6,
value: "",
options:[],
options: [],
rules: "required|string",
viewAttr: 3
},
@ -284,6 +288,17 @@ export const declareConditions = [
rules: "required",
options: []
},
{
colSpan: 1,
conditionType: "INPUT",
domkey: ["birthplace"],
fieldcol: 12,
label: "出生地",
lanId: 111,
labelcol: 6,
value: "",
viewAttr: 2
},
{
colSpan: 1,
conditionType: "DATEPICKER",
@ -379,6 +394,24 @@ export const declareConditions = [
value: "",
viewAttr: 2
},
{
colSpan: 1,
conditionType: "SELECT",
domkey: ["taxReasons"],
fieldcol: 12,
label: "涉税事由",
lanId: 111,
labelcol: 6,
value: "",
viewAttr: 2,
options: [
{ key: getLabel(111, "任职受雇"), showname: getLabel(111, "任职受雇") },
{ key: getLabel(111, "提供临时劳务"), showname: getLabel(111, "提供临时劳务") },
{ key: getLabel(111, "转让财产"), showname: getLabel(111, "转让财产") },
{ key: getLabel(111, "从事投资和经营活动"), showname: getLabel(111, "从事投资和经营活动") },
{ key: getLabel(111, "其他"), showname: getLabel(111, "其他") }
]
},
{
colSpan: 1,
conditionType: "SELECT",