社保福利档案新增编辑页面重构
This commit is contained in:
parent
f2030e971f
commit
03a432266b
|
|
@ -214,20 +214,21 @@ export default class Archives extends React.Component {
|
|||
const { archivesStore: { save, socialSecurityForm, accumulationFundForm, otherForm } } = this.props;
|
||||
if (selectedTab == 1) {
|
||||
const { data } = socialSecurityForm;
|
||||
console.log(socialSecurityForm);
|
||||
if (data.socialSchemeId && !data.socialStartTime) {
|
||||
const { socialName, socialStartTime } = data;
|
||||
if (socialName && !socialStartTime) {
|
||||
Modal.warning({
|
||||
title: "信息确认",
|
||||
content: "必要信息不完整,红色*为必填项!"
|
||||
});
|
||||
return;
|
||||
}
|
||||
// save("SOCIAL_SECURITY").then(() => {
|
||||
// this.query();
|
||||
// });
|
||||
save("SOCIAL_SECURITY").then(() => {
|
||||
this.query();
|
||||
});
|
||||
} else if (selectedTab == 2) {
|
||||
const { data } = accumulationFundForm;
|
||||
if (data.fundSchemeId && !data.fundStartTime) {
|
||||
const { fundSchemeId, fundStartTime } = data;
|
||||
if (fundSchemeId && !fundStartTime) {
|
||||
Modal.warning({
|
||||
title: "信息确认",
|
||||
content: "必要信息不完整,红色*为必填项!"
|
||||
|
|
@ -239,7 +240,8 @@ export default class Archives extends React.Component {
|
|||
});
|
||||
} else if (selectedTab == 3) {
|
||||
const { data } = otherForm;
|
||||
if (data.otherSchemeId && !data.otherStartTime) {
|
||||
const { otherSchemeId, otherStartTime } = data;
|
||||
if (otherSchemeId && !otherStartTime) {
|
||||
Modal.warning({
|
||||
title: "信息确认",
|
||||
content: "必要信息不完整,红色*为必填项!"
|
||||
|
|
|
|||
|
|
@ -207,7 +207,7 @@ export class ArchivesStore {
|
|||
let paymentForm = "";
|
||||
if (welfareType == "SOCIAL_SECURITY") {
|
||||
baseForm = JSON.stringify(this.socialSecurityForm.data);
|
||||
paymentForm = this.socialSecurityForm.data.socialSchemeId ? JSON.stringify(this.socialSecurityPaymentForm.data) : "";
|
||||
paymentForm = this.socialSecurityForm.data.socialName ? JSON.stringify(this.socialSecurityPaymentForm.data) : "";
|
||||
} else if (welfareType == "ACCUMULATION_FUND") {
|
||||
baseForm = JSON.stringify(this.accumulationFundForm.data);
|
||||
paymentForm = this.accumulationFundForm.data.fundSchemeId ? JSON.stringify(this.accumulationFundPaymentForm.data) : "";
|
||||
|
|
|
|||
Loading…
Reference in New Issue