From d2fe01c7592555d36365191b0d3fdbad06436f38 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, 4 Jul 2023 17:37:04 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BA=A7=E5=93=81-=E5=B7=A5=E8=B5=84=E5=8D=95?= =?UTF-8?q?=E6=A8=A1=E6=9D=BF=E5=AE=9A=E6=97=B6=E5=8F=91=E6=94=BEbug?= =?UTF-8?q?=E5=A4=84=E7=90=86=E4=BB=A5=E5=8F=8A=E8=A7=84=E5=88=99=E8=AE=BE?= =?UTF-8?q?=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pages/payroll/stepForm/baseInformForm.js | 31 ++++++++++++------- 1 file changed, 19 insertions(+), 12 deletions(-) diff --git a/pc4mobx/hrmSalary/pages/payroll/stepForm/baseInformForm.js b/pc4mobx/hrmSalary/pages/payroll/stepForm/baseInformForm.js index 157467d7..251b8e7e 100644 --- a/pc4mobx/hrmSalary/pages/payroll/stepForm/baseInformForm.js +++ b/pc4mobx/hrmSalary/pages/payroll/stepForm/baseInformForm.js @@ -37,7 +37,8 @@ export default class BaseInformForm extends React.Component { msgStatus: !this.props.id ? "1" : data.templateBaseData.msgStatus, reissueRule: data.templateBaseData.replenishRule ? "1" : "0", ...JSON.parse(templateBaseData), - sendEmail: "" + sendEmail: "", + autoSendStatus: !_.isNil(data.templateBaseData.autoSendStatus) ? data.templateBaseData.autoSendStatus : false } }, () => { this.props.onChange && this.props.onChange(this.state.request); @@ -50,7 +51,7 @@ export default class BaseInformForm extends React.Component { JSON.parse(templateBaseData).salarySob && this.getReplenishRuleSetOptions({ salarySobId: JSON.parse(templateBaseData).salarySob }); } - hanldeChange = (params) => { + handleChange = (params) => { let request = { ...this.state.request, ...params }; this.setState({ request @@ -104,7 +105,7 @@ export default class BaseInformForm extends React.Component { options={options} value={salarySob ? salarySob : ""} style={{ width: 200 }} - onChange={value => this.hanldeChange({ salarySob: value })}/> + onChange={value => this.handleChange({ salarySob: value })}/> } this.hanldeChange({ name: value })} + onChange={value => this.handleChange({ name: value })} /> this.hanldeChange({ replenishName: value })} + onChange={value => this.handleChange({ replenishName: value })} /> this.hanldeChange({ reissueRule: value })} + onChange={value => this.handleChange({ reissueRule: value })} /> { @@ -153,7 +154,7 @@ export default class BaseInformForm extends React.Component { options={replenishRuleOptions} value={replenishRule} viewAttr={3} - onChange={value => this.hanldeChange({ replenishRule: value })} + onChange={value => this.handleChange({ replenishRule: value })} /> } @@ -164,7 +165,7 @@ export default class BaseInformForm extends React.Component { > this.hanldeChange({ description: value })} + onChange={value => this.handleChange({ description: value })} /> @@ -172,15 +173,21 @@ export default class BaseInformForm extends React.Component { className="payrollBaseInfoWrapper"> this.hanldeChange({ msgStatus: value === "1" })}/> + onChange={value => this.handleChange({ msgStatus: value === "1" })}/> this.hanldeChange({ emailStatus: value === "1" })}/> + onChange={value => this.handleChange({ emailStatus: value === "1" })}/> this.hanldeChange({ autoSendStatus: value === "1" })}/> + onChange={value => { + this.handleChange({ + autoSendStatus: value === "1", + autoSendDayOfMonth: value === "1" ? "1" : null, + autoSendTimeOfDay: value === "1" ? "09:00" : null + }); + }}/> { autoSendStatus && @@ -190,7 +197,7 @@ export default class BaseInformForm extends React.Component { autoSendDayOfMonth, autoSendTimeOfDay }} - onChange={this.hanldeChange} + onChange={this.handleChange} /> }