Closed dantronik-bugreporting closed 3 years ago
Describe the bug Sorting the DataGrid by clicking the column headers does not work in ASP.NET 6.0
To Reproduce Steps to reproduce the behavior:
crit: Microsoft.AspNetCore.Components.WebAssembly.Rendering.WebAssemblyRenderer[100] Unhandled exception rendering component: TypeInitialization_Type, System.Linq.Dynamic.Core.DynamicQueryableExtensions System.TypeInitializationException: TypeInitialization_Type, System.Linq.Dynamic.Core.DynamicQueryableExtensions ---> System.Exception: Specific method not found: FirstOrDefault ---> System.InvalidOperationException: MoreThanOneMatch at System.Linq.ThrowHelper.ThrowMoreThanOneMatchException() at System.Linq.Enumerable.TryGetSingle[MethodInfo](IEnumerable`1 source, Func`2 predicate, Boolean& found) at System.Linq.Enumerable.Single[MethodInfo](IEnumerable`1 source, Func`2 predicate) at System.Linq.Dynamic.Core.DynamicQueryableExtensions.GetMethod(String name, Int32 parameterCount, Func`2 predicate) Exception_EndOfInnerExceptionStack at System.Linq.Dynamic.Core.DynamicQueryableExtensions.GetMethod(String name, Int32 parameterCount, Func`2 predicate) at System.Linq.Dynamic.Core.DynamicQueryableExtensions..cctor() Exception_EndOfInnerExceptionStack at Radzen.Blazor.RadzenGrid`1[[IKON_2_0.Shared.Models.T103_GZPROD_AN_STHF, IKON_2_0.Shared, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]].get_View() at Radzen.PagedDataBoundComponent`1[[IKON_2_0.Shared.Models.T103_GZPROD_AN_STHF, IKON_2_0.Shared, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]].get_PagedView() at Radzen.Blazor.RadzenGrid`1[[IKON_2_0.Shared.Models.T103_GZPROD_AN_STHF, IKON_2_0.Shared, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null]].BuildRenderTree(RenderTreeBuilder __builder) at Microsoft.AspNetCore.Components.ComponentBase.<.ctor>b__6_0(RenderTreeBuilder ) at Microsoft.AspNetCore.Components.Rendering.ComponentState.RenderIntoBatch(RenderBatchBuilder , RenderFragment , Exception& )
Alternatively link your repo with a sample project that can be run.
Expected behavior DataGrid should be sorted.
Desktop (please complete the following information):
Additional context Issue only occurs in net6. net5 works properly.
We can't do much until this issue is addressed: https://github.com/zzzprojects/System.Linq.Dynamic.Core/issues/493
Describe the bug Sorting the DataGrid by clicking the column headers does not work in ASP.NET 6.0
To Reproduce Steps to reproduce the behavior:
Alternatively link your repo with a sample project that can be run.
Expected behavior DataGrid should be sorted.
Desktop (please complete the following information):
Additional context Issue only occurs in net6. net5 works properly.