refactor: 重命名 BlazorTable 为 AdminTable
This commit is contained in:
parent
d542c4675e
commit
9946294160
|
@ -4,7 +4,7 @@
|
|||
///
|
||||
/// </summary>
|
||||
[CascadingTypeParameter(nameof(TItem))]
|
||||
public partial class BlazorTable<TItem> where TItem : class, new()
|
||||
public partial class AdminTable<TItem> where TItem : class, new()
|
||||
{
|
||||
/// <summary>
|
||||
///
|
|
@ -1,6 +1,6 @@
|
|||
@page "/Admin/Dicts"
|
||||
|
||||
<BlazorTable TItem="DataAccess.Models.Dict" TableSearchModel="DictsSearchModel">
|
||||
<AdminTable TItem="DataAccess.Models.Dict" TableSearchModel="DictsSearchModel">
|
||||
<ColumnsTemplete>
|
||||
<TableColumn @bind-Field="context.Category" Filterable="true" Searchable="true" Sortable="true"></TableColumn>
|
||||
<TableColumn @bind-Field="context.Name" Filterable="true" Searchable="true" Sortable="true"></TableColumn>
|
||||
|
@ -13,4 +13,4 @@
|
|||
<DictSearch @bind-Value="@searchModel"></DictSearch>
|
||||
}
|
||||
</CustomerSearchTemplate>
|
||||
</BlazorTable>
|
||||
</AdminTable>
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
@page "/Admin/Groups"
|
||||
|
||||
<BlazorTable TItem="DataAccess.Models.Group" ExtendButtonColumnWidth="260">
|
||||
<AdminTable TItem="DataAccess.Models.Group" ExtendButtonColumnWidth="260">
|
||||
<TableToolbarTemplate>
|
||||
<TableToolbarButton TItem="DataAccess.Models.Group" IsEnableWhenSelectedOneRow="true" Color="Color.Warning" Icon="fa fa-user" Text="分配用户" OnClickCallback="groups => OnAssignmentUsers(groups.First())" />
|
||||
<TableToolbarButton TItem="DataAccess.Models.Group" IsEnableWhenSelectedOneRow="true" Color="Color.Info" Icon="fa fa-sitemap" Text="分配角色" OnClickCallback="groups => OnAssignmentRoles(groups.First())" />
|
||||
|
@ -14,4 +14,4 @@
|
|||
<TableCellButton Size="Size.ExtraSmall" Color="Color.Warning" Icon="fa fa-user" Text="分配用户" OnClick="() => OnAssignmentUsers(context)" />
|
||||
<TableCellButton Size="Size.ExtraSmall" Color="Color.Info" Icon="fa fa-sitemap" Text="分配角色" OnClick="() => OnAssignmentRoles(context)" />
|
||||
</RowButtonTemplate>
|
||||
</BlazorTable>
|
||||
</AdminTable>
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
@page "/Admin/Menus"
|
||||
|
||||
<BlazorTable TItem="DataAccess.Models.Navigation" IsTree="true" OnTreeExpand="OnTreeExpand" ExtendButtonColumnWidth="200" OnQueryAsync="OnQueryAsync">
|
||||
<AdminTable TItem="DataAccess.Models.Navigation" IsTree="true" OnTreeExpand="OnTreeExpand" ExtendButtonColumnWidth="200" OnQueryAsync="OnQueryAsync">
|
||||
<TableToolbarTemplate>
|
||||
<TableToolbarButton TItem="DataAccess.Models.Navigation" IsEnableWhenSelectedOneRow="true" Color="Color.Info" Icon="fa fa-sitemap" Text="分配角色" OnClickCallback="menus => OnAssignmentRoles(menus.First())" />
|
||||
</TableToolbarTemplate>
|
||||
|
@ -21,4 +21,4 @@
|
|||
<RowButtonTemplate>
|
||||
<TableCellButton Size="Size.ExtraSmall" Color="Color.Info" Icon="fa fa-sitemap" Text="分配角色" OnClick="() => OnAssignmentRoles(context)" />
|
||||
</RowButtonTemplate>
|
||||
</BlazorTable>
|
||||
</AdminTable>
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
@page "/Admin/Roles"
|
||||
|
||||
<BlazorTable TItem="DataAccess.Models.Role" ExtendButtonColumnWidth="340">
|
||||
<AdminTable TItem="DataAccess.Models.Role" ExtendButtonColumnWidth="340">
|
||||
<TableToolbarTemplate>
|
||||
<TableToolbarButton TItem="DataAccess.Models.Role" IsEnableWhenSelectedOneRow="true" Color="Color.Info" Icon="fa fa-user" Text="用户" OnClickCallback="roles => OnAssignmentUsers(roles.First())" />
|
||||
<TableToolbarButton TItem="DataAccess.Models.Role" IsEnableWhenSelectedOneRow="true" Color="Color.Warning" Icon="fa fa-bank" Text="部门" OnClickCallback="roles => OnAssignmentGroups(roles.First())" />
|
||||
|
@ -17,5 +17,5 @@
|
|||
<TableCellButton Size="Size.ExtraSmall" Color="Color.Success" Icon="fa fa-dashboard" Text="菜单" OnClick="() => OnAssignmentMenus(context)" />
|
||||
<TableCellButton Size="Size.ExtraSmall" Color="Color.Secondary" Icon="fa fa-cubes" Text="应用" OnClick="() => OnAssignmentApps(context)" />
|
||||
</RowButtonTemplate>
|
||||
</BlazorTable>
|
||||
</AdminTable>
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
@page "/Admin/Users"
|
||||
|
||||
<BlazorTable TItem="DataAccess.Models.User" ExtendButtonColumnWidth="260">
|
||||
<AdminTable TItem="DataAccess.Models.User" ExtendButtonColumnWidth="260">
|
||||
<TableToolbarTemplate>
|
||||
<TableToolbarButton TItem="DataAccess.Models.User" IsEnableWhenSelectedOneRow="true" Color="Color.Warning" Icon="fa fa-bank" Text="分配部门" OnClickCallback="users => OnAssignmentGroups(users.First())" />
|
||||
<TableToolbarButton TItem="DataAccess.Models.User" IsEnableWhenSelectedOneRow="true" Color="Color.Info" Icon="fa fa-sitemap" Text="分配角色" OnClickCallback="users => OnAssignmentRoles(users.First())" />
|
||||
|
@ -17,4 +17,4 @@
|
|||
<TableCellButton Size="Size.ExtraSmall" Color="Color.Warning" Icon="fa fa-bank" Text="分配部门" OnClick="() => OnAssignmentGroups(context)" />
|
||||
<TableCellButton Size="Size.ExtraSmall" Color="Color.Info" Icon="fa fa-sitemap" Text="分配角色" OnClick="() => OnAssignmentRoles(context)" />
|
||||
</RowButtonTemplate>
|
||||
</BlazorTable>
|
||||
</AdminTable>
|
||||
|
|
Loading…
Reference in New Issue