diff --git a/src/BootstrapBlazor/BootstrapBlazor.csproj b/src/BootstrapBlazor/BootstrapBlazor.csproj index 06c667e546a..faa3ef8bcb6 100644 --- a/src/BootstrapBlazor/BootstrapBlazor.csproj +++ b/src/BootstrapBlazor/BootstrapBlazor.csproj @@ -1,7 +1,7 @@ - 8.1.6-beta07 + 8.1.6-beta08 diff --git a/src/BootstrapBlazor/Components/Table/Table.razor.Toolbar.cs b/src/BootstrapBlazor/Components/Table/Table.razor.Toolbar.cs index 22d3bbdf24f..039423acbda 100644 --- a/src/BootstrapBlazor/Components/Table/Table.razor.Toolbar.cs +++ b/src/BootstrapBlazor/Components/Table/Table.razor.Toolbar.cs @@ -1002,6 +1002,7 @@ private void QueryDynamicItems(IDynamicObjectContext? context) } TotalCount = items.Count(); PageCount = (int)Math.Ceiling(TotalCount * 1.0 / Math.Max(1, PageItems)); + PageIndex = Math.Max(1, Math.Min(PageIndex, int.Parse(Math.Ceiling((TotalCount - SelectedRows.Count) * 1d / PageItems).ToString()))); items = items.Skip((PageIndex - 1) * PageItems).Take(PageItems); } QueryItems = items.Cast();