hotfix/2.12.1.2403.02

规则设置-加密解密修改
This commit is contained in:
黎永顺 2024-04-15 16:07:41 +08:00
parent f8e78a97ac
commit 709ec6abd7
1 changed files with 8 additions and 3 deletions

View File

@ -38,7 +38,8 @@ class RuleConfig extends Component {
const optionsList = { matchRule, orderRule, ascOrDesc, rule };
this.setState({
sysinfo, conditions: _.map(conditions, item => ({
...item, items: _.map(item.items, o => {
...item,
items: _.map(item.items, o => {
if (getKey(o) === "matchRule" || getKey(o) === "orderRule" || getKey(o) === "ascOrDesc" || getKey(o) === "rule") {
return { ...o, options: _.map(optionsList[getKey(o)], g => ({ key: g.value, showname: g.defaultLabel })) };
} else if (getKey(o) === "OPEN_APPLICATION_ENCRYPT") {
@ -70,6 +71,8 @@ class RuleConfig extends Component {
form.updateFields({ [item]: { value: sysinfo["taxDeclarationFunction"] === "0" ? "0" : "1" } });
} else if (item === "taxAgentShowStatus" || item === "salaryShowStatus" || item === "adjustShowStatus") {
form.updateFields({ [item]: { value: sysinfo[item] || "1" } });
} else if (item === "OPEN_APPLICATION_ENCRYPT") {
form.updateFields({ [item]: { value: _.isNil(sysinfo[item]) ? "1" : (sysinfo[item] || "") } });
} else {
form.updateFields({ [item]: { value: sysinfo[item] || "" } });
}
@ -297,13 +300,15 @@ class RuleConfig extends Component {
render() {
const { baseFormStore: { form } } = this.props;
const { conditions, progressVisible, progress } = this.state;
const { conditions, progressVisible, progress, sysinfo } = this.state;
const ruleConditions = sysinfo.showEncryptOperationButton === "true" ? conditions :
_.filter(conditions, o => o.title !== getLabel(543358, "加密规则"));
return (
<WeaTop
title={<span>{getLabel(543355, "规则配置")}</span>} icon={<i className="icon-coms-Flow-setting"/>}
iconBgcolor="#F14A2D" buttons={[]} className="ruleWrapper-layout"
>
<div className="ruleWrapper">{renderRuleForm(form, conditions, this.handleChange)}</div>
<div className="ruleWrapper">{renderRuleForm(form, ruleConditions, this.handleChange)}</div>
{/*加解密进度条*/}
{
progressVisible &&