Skip to content

Commit

Permalink
fix(Table): search model initialize twice (#4379)
Browse files Browse the repository at this point in the history
* fix: 修复顶栏搜索自定义模型初始化问题

* chore: bump version 8.10.2-beta01
  • Loading branch information
ArgoZhang authored Sep 29, 2024
1 parent edb667c commit 3739e9b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/BootstrapBlazor/BootstrapBlazor.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk.Razor">

<PropertyGroup>
<Version>8.10.1</Version>
<Version>8.10.2-beta01</Version>
</PropertyGroup>

<ItemGroup Condition="'$(TargetFramework)' == 'net6.0'">
Expand Down
4 changes: 2 additions & 2 deletions src/BootstrapBlazor/Components/Table/Table.razor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -737,8 +737,6 @@ protected override void OnInitialized()

// 初始化节点缓存
TreeNodeCache ??= new(Equals);
SearchModel = CreateTItem();

OnInitLocalization();

// 设置 OnSort 回调方法
Expand Down Expand Up @@ -860,6 +858,8 @@ private void OnInitParameters()
TreeExpandIcon ??= IconTheme.GetIconByKey(ComponentIcons.TableTreeExpandIcon);
TreeNodeLoadingIcon ??= IconTheme.GetIconByKey(ComponentIcons.TableTreeNodeLoadingIcon);
AdvancedSortButtonIcon ??= IconTheme.GetIconByKey(ComponentIcons.TableAdvancedSortButtonIcon);

SearchModel ??= CreateTItem();
}

/// <summary>
Expand Down

0 comments on commit 3739e9b

Please sign in to comment.