Tables crash when property column is nullable enum
lazar-essentaildots opened this issue · comments
Description
Tables crash when property column is nullable enum in 0.19.0
Exception:
crit: Microsoft.AspNetCore.Components.WebAssembly.Rendering.WebAssemblyRenderer[100]
Unhandled exception rendering component: The type initializer for 'AntDesign.EnumHelper1' threw an exception. System.TypeInitializationException: The type initializer for 'AntDesign.EnumHelper
1' threw an exception.
---> System.ArgumentException: Method 'Boolean HasFlag(System.Enum)' declared on type 'System.Enum' cannot be called with instance of type 'System.Nullable1[YYY.Domain.Model.ZZZType]' at System.Linq.Expressions.Expression.ValidateCallInstanceType(Type instanceType, MethodInfo method) at System.Linq.Expressions.Expression.ValidateStaticOrInstanceMethod(Expression instance, MethodInfo method) at System.Linq.Expressions.Expression.ValidateMethodAndGetParameters(Expression instance, MethodInfo method) at System.Linq.Expressions.Expression.Call(Expression instance, MethodInfo method, Expression arg0) at System.Linq.Expressions.Expression.Call(Expression instance, MethodInfo method, IEnumerable
1 arguments)
at System.Linq.Expressions.Expression.Call(Expression instance, MethodInfo method, Expression[] arguments)
at AntDesign.EnumHelper1[[System.Nullable
1[[YYY.Domain.Model.ZZZType, YYY, Version=0.3.0.0, Culture=neutral, PublicKeyToken=null]], System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].BuildHasFlagFunction()
at AntDesign.EnumHelper1[[System.Nullable
1[[YYY.Domain.Model.ZZZType, YYY, Version=0.3.0.0, Culture=neutral, PublicKeyToken=null]], System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]]..cctor()
Further technical details
AntDesign Nuget Package version 0.19.0
Thanks for contacting us @lazar-essentaildots , this issue have been fix in 0.19.1. Please update and try again.
I can confirm that it works now.