feat: 仅一次加载初始化滚动条

This commit is contained in:
Argo Zhang 2020-01-22 10:24:14 +08:00
parent 261f91683f
commit ef1718360e
No known key found for this signature in database
GPG Key ID: 152E398953DDF19F
2 changed files with 5 additions and 2 deletions

View File

@ -218,7 +218,7 @@ namespace Bootstrap.Admin.Components
if (FixedHeader)
{
// 调用客户端脚本 resetWith
await JSRuntime.InitTableAsync(RetrieveId());
await JSRuntime.InitTableAsync(RetrieveId(), firstRender);
}
}

View File

@ -101,6 +101,9 @@ namespace Bootstrap.Admin.Extensions
/// <summary>
/// 初始化 Table 组件
/// </summary>
public static ValueTask InitTableAsync(this IJSRuntime? jSRuntime, string id) => jSRuntime.InvokeVoidAsync("$.initTable", id);
/// <param name="jSRuntime"></param>
/// <param name="id"></param>
/// <param name="firstRender"></param>
public static ValueTask InitTableAsync(this IJSRuntime? jSRuntime, string id, bool firstRender) => jSRuntime.InvokeVoidAsync("$.initTable", id, firstRender);
}
}