fix: action linkage not work in detail block (#2875)

This commit is contained in:
katherinehhh 2023-10-20 10:34:25 +08:00 committed by GitHub
parent 74a6d49181
commit 7e33912242
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -120,16 +120,20 @@ export const linkageAction = async ({
disabled: disableResult,
};
field.disabled = last(disableResult);
field.componentProps['disabled'] = last(disableResult);
break;
case ActionType.Active:
if (await conditionAnalyses({ rules: condition, formValues: values, variables, localVariables })) {
disableResult.push(false);
} else {
disableResult.push(true);
}
field.linkageProperty = {
...field.linkageProperty,
disabled: disableResult,
};
field.disabled = last(disableResult);
field.componentProps['disabled'] = last(disableResult);
break;
default:
return null;