You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Field is incorrectly shown in validate() method. (Expected: Field should not be shown in validate() method since ifShow is false.)
Explanation:
Scenario 1: The field "user" is hidden (ifShow is false). When the form is submitted, the field does not appear in the validate() method, which is the expected behavior.
Scenario 2: Initially, the field "user" is hidden (ifShow is false). When the form is submitted, the field does not appear in the validate() method. Then, a button is clicked to show the "user" field (ifShow is true), and a value is selected. After selecting a value, the field is hidden again (ifShow is false). When the form is submitted, the field should not appear in the validate() method since ifShow is false. However, it incorrectly appears in the validation, which is not the correct behavior.
System Info
Operating System: 11
Node version: 20.11.0
pnpm version: 9.0.6
The text was updated successfully, but these errors were encountered:
Validate method should not consider ifShow is hidden
In this scenario, the "User" field is initially hidden with the condition ifShow being false. Despite being hidden, it still retains its default value.
doraemonxxx
changed the title
Hidden Form Fields Incorrectly Included in Validation After Conditional Visibility Changes Using ifShow
Hidden form fields incorrectly included in validation after conditional visibility changes using ifShow
May 29, 2024
Describe the bug
Scenario 1
ifShow
Valuefalse
false
validate()
method.Scenario 2
ifShow
Valuefalse
false
validate()
method.true
true
false
false
validate()
method. (Expected: Field should not be shown invalidate()
method sinceifShow
isfalse
.)Explanation:
Scenario 1: The field "user" is hidden (
ifShow
isfalse
). When the form is submitted, the field does not appear in thevalidate()
method, which is the expected behavior.Scenario 2: Initially, the field "user" is hidden (
ifShow
isfalse
). When the form is submitted, the field does not appear in thevalidate()
method. Then, a button is clicked to show the "user" field (ifShow
istrue
), and a value is selected. After selecting a value, the field is hidden again (ifShow
isfalse
). When the form is submitted, the field should not appear in thevalidate()
method sinceifShow
isfalse
. However, it incorrectly appears in the validation, which is not the correct behavior.System Info
The text was updated successfully, but these errors were encountered: