diff --git a/pc4mobx/hrmSalary/pages/appConfig/index.js b/pc4mobx/hrmSalary/pages/appConfig/index.js index a2b663c6..97054546 100644 --- a/pc4mobx/hrmSalary/pages/appConfig/index.js +++ b/pc4mobx/hrmSalary/pages/appConfig/index.js @@ -14,7 +14,7 @@ class AppConfig extends Component { super(props); this.state = { openAcctResultSum: "0", - displayPersonalInfo: "0", + displayEmpInfoReport: "0", loading: false }; } @@ -26,27 +26,27 @@ class AppConfig extends Component { queryAppsetting = () => { API.queryAppsetting().then(({ status, data }) => { if (status) { - const { openAcctResultSum } = data; - this.setState({ openAcctResultSum }); + const { openAcctResultSum, displayEmpInfoReport } = data; + this.setState({ openAcctResultSum, displayEmpInfoReport }); } }); }; appSettingSave = () => { - const { openAcctResultSum } = this.state; + const { openAcctResultSum, displayEmpInfoReport } = this.state; this.setState({ loading: true }); - API.appSettingSave({ openAcctResultSum }).then(({ status }) => { + API.appSettingSave({ openAcctResultSum, displayEmpInfoReport }).then(({ status, errormsg }) => { this.setState({ loading: false }); if (status) { message.success("设置成功!"); this.queryAppsetting(); } else { - message.error("设置失败!"); + message.error(errormsg || "设置失败!"); } }); }; render() { - const { openAcctResultSum,displayPersonalInfo, loading } = this.state; + const { openAcctResultSum, displayEmpInfoReport, loading } = this.state; const btns = []; const items = [ { @@ -61,9 +61,9 @@ class AppConfig extends Component { { com: CheckBox({ label: "是否显示脱敏表人员信息", - value: displayPersonalInfo, - onChange: (displayPersonalInfo) => { - this.setState({ displayPersonalInfo }); + value: displayEmpInfoReport, + onChange: (displayEmpInfoReport) => { + this.setState({ displayEmpInfoReport }); } }) }