Autocomplete with TValue as Guid fails validation #5133
Unanswered
mdmontesinos
asked this question in
Q&A
Replies: 1 comment 3 replies
-
Converting to issue, possible bug |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Using Autocomplete component with SelectionMode to Multiple and a TValue of type Guid does not correctly apply validation.
When replacing the Validator and printing to console the value, you always get the following:
It doesn't matter how many options you've chosen, the internal value used for validation is always a default Guid converted to string.
Therefore, it's not possible to validate whether the value is empty or not with the ValidationRule.IsNotEmpty.
After taking a brief look at the implementation, I believe the Guid (which does not accept null values) is always converted to its default value and ToString.
Beta Was this translation helpful? Give feedback.
All reactions