修改密码页面 旧密码与新密码字段映射错误

pull/72/head
布拉德皮怪 1 year ago committed by Friday
parent feddb454a3
commit 69a48a256d

@ -71,8 +71,8 @@ const ModifyPassword = (props: {
}}
onFinish={async (formData: Record<string, any>) => {
const { success, result, status, message } = await changePassword({
oldPassword: formData[FieldNames.NEW_PASSWORD] as string,
newPassword: formData[FieldNames.OLD_PASSWORD] as string,
oldPassword: formData[FieldNames.OLD_PASSWORD] as string,
newPassword: formData[FieldNames.NEW_PASSWORD] as string,
});
if (!success && status === ServerExceptionStatus.PASSWORD_VALIDATED_FAIL_ERROR) {
formRef.current?.setFields([{ name: FieldNames.OLD_PASSWORD, errors: [`${message}`] }]);

Loading…
Cancel
Save