release/2.9.9.2312.02-个税

This commit is contained in:
黎永顺 2024-02-02 13:52:37 +08:00
parent a33b47373d
commit 2a85b3e596
3 changed files with 28 additions and 3 deletions

View File

@ -1,5 +1,6 @@
import { WeaTools } from "ecCom";
import { postExportFetch, postFetch } from "../util/request";
import { convertToUrlString } from "../util/url";
//个税申报表-个税申报表列表
export const getDeclareList = params => {
@ -230,7 +231,10 @@ export const taxdeclarationEdit = (params) => {
};
//个税申报表申报数据-详情
export const getTaxdeclarationDetailInfo = (params) => {
return WeaTools.callApi("/api/bs/hrmsalary/taxdeclaration/detailInfo", "GET", params);
return fetch(`/api/bs/hrmsalary/taxdeclaration/detailInfo?${convertToUrlString(params)}`, {
method: "GET",
mode: "cors"
}).then((res) => res.json());
};
//个税申报表申报数据-下载模板
export const taxdeclarationExportTemplate = params => {
@ -260,3 +264,7 @@ export const addTaxDeclaration = (params) => {
export const deleteTaxDeclaration = (params) => {
return postFetch("/api/bs/hrmsalary/taxdeclaration/deleteTaxDeclaration", params);
};
//个税申报表-删除申报表
export const deleteInfo = (params) => {
return postFetch("/api/bs/hrmsalary/taxdeclaration/deleteInfo", params);
};

View File

@ -104,7 +104,7 @@ class IncomeTaxDeclarationPersonnelSlide extends Component {
});
};
getTaxdeclarationDetailInfo = (id) => {
API.getTaxdeclarationDetailInfo({ id }).then(({ status, data }) => {
API.getTaxdeclarationDetailInfo({ id }).then(({ status, data, errormsg }) => {
if (status) {
const { conditions } = this.state;
const { declareStore: { taxDecForm } } = this.props;
@ -118,6 +118,9 @@ class IncomeTaxDeclarationPersonnelSlide extends Component {
});
});
});
} else {
message.error(errormsg);
this.props.onClose();
}
});
};

View File

@ -12,6 +12,7 @@ import { apiflowBillingConfigStatus } from "../../apis/intelligentCalculateSalar
import PaymentBtn from "./components/paymentBtn";
import PaymentFeedbackBtn from "./components/paymentFeedbackBtn";
import {
deleteInfo,
deleteTaxDeclaration,
exportGetDeclareTaxResultFeedback,
getDeclareInfo,
@ -124,7 +125,20 @@ class Index extends Component {
title: getLabel(501169, "编辑")
});
} else if (id === "DELETE") {
Modal.confirm({
title: getLabel(131329, "信息确认"),
content: getLabel(543548, "确认删除吗?"),
onOk: () => {
deleteInfo({ id: params.id }).then(({ status, errormsg }) => {
if (status) {
message.success(getLabel(502230, "删除成功!"));
this.getDetailList();
} else {
message.error(errormsg || getLabel(20462, "删除失败!"));
}
});
}
});
}
}
};