File tree 16 files changed +72
-289
lines changed
src/Client/Logistics.AdminAppWasm
16 files changed +72
-289
lines changed Original file line number Diff line number Diff line change 1
- <CascadingAuthenticationState >
1
+ <CascadingAuthenticationState >
2
2
<Router AppAssembly =" @typeof(App).Assembly" >
3
3
<Found Context =" routeData" >
4
4
<AuthorizeRouteView RouteData =" @routeData" DefaultLayout =" @typeof(MainLayout)" >
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1
- @using Microsoft .AspNetCore .Components .WebAssembly .Authentication
1
+ @using Microsoft .AspNetCore .Components .WebAssembly .Authentication
2
2
@inject NavigationManager Navigation
3
3
4
- <AuthorizeView >
5
- <Authorized >
6
- Hello, @context.User.Identity ?.Name
7
- <button class =" nav-link btn btn-link" @onclick =" BeginLogOut" >Log out</button >
8
- </Authorized >
9
- <NotAuthorized >
10
- <a href =" authentication/login" >Log in</a >
11
- </NotAuthorized >
12
- </AuthorizeView >
4
+ <RadzenStack Orientation =" Orientation.Horizontal" AlignItems =" AlignItems.Center" >
5
+ <AuthorizeView >
6
+ <Authorized >
7
+ <RadzenLink Icon =" account_circle" >@context.User.Identity ?.Name</RadzenLink >
8
+ <RadzenLink Icon =" login" Path =" authentication/logout" >Sign Out</RadzenLink >
9
+ </Authorized >
10
+ <NotAuthorized >
11
+ <RadzenLink Icon =" login" Path =" authentication/login" >Sign In</RadzenLink >
12
+ </NotAuthorized >
13
+ </AuthorizeView >
14
+ </RadzenStack >
13
15
14
16
@code {
15
17
private void BeginLogOut ()
Original file line number Diff line number Diff line change 1
- @inherits LayoutComponentBase
1
+ @inherits LayoutComponentBase
2
2
3
3
<PageTitle >Logistics Admin</PageTitle >
4
4
<Toast @ref =" _toastRef" ToastPosition =" Toast.Position.BottomRight" ></Toast >
5
5
6
- <div class =" page" >
7
- <div class =" sidebar" >
8
- <NavMenu />
9
- </div >
10
-
11
- <main >
12
- <div class =" top-row px-4 auth" >
13
- <LoginDisplay />
14
- <a href =" https://learn.microsoft.com/aspnet/core/" target =" _blank" >About</a >
15
- </div >
16
-
17
- <article class =" content px-4" >
6
+ <RadzenLayout >
7
+ <RadzenHeader >
8
+ <RadzenRow >
9
+ <RadzenColumn Size =" 2" >
10
+ <RadzenStack Orientation =" Orientation.Horizontal" AlignItems =" AlignItems.Center" Gap =" 0.5rem" >
11
+ <RadzenSidebarToggle Click =" @(() => _sidebarExpanded = !_sidebarExpanded)" />
12
+ <RadzenLabel Text =" Logistics Admin" />
13
+ </RadzenStack >
14
+ </RadzenColumn >
15
+ <RadzenColumn Size =" 2" Offset =" 8" class =" d-flex justify-content-end pe-2" >
16
+ <LoginDisplay />
17
+ </RadzenColumn >
18
+ </RadzenRow >
19
+
20
+ </RadzenHeader >
21
+ <RadzenSidebar @bind-Expanded =" @_sidebarExpanded" >
22
+ <RadzenPanelMenu >
23
+ <RadzenPanelMenuItem Text =" Home" Icon =" home" Path =" /" />
24
+ <RadzenPanelMenuItem Text =" Tenants" Icon =" home" Path =" /tenants" />
25
+ <RadzenPanelMenuItem Text =" Subscriptions" Icon =" subscriptions" />
26
+ <RadzenPanelMenuItem Text =" Users" Icon =" subscriptions" />
27
+ </RadzenPanelMenu >
28
+ </RadzenSidebar >
29
+ <RadzenBody >
30
+ <div class =" rz-p-4" >
18
31
<Alert @ref =" _alertRef" />
19
32
<CascadingValue Value =" _toastRef" >
20
33
<CascadingValue Value =" _alertRef" >
21
34
@Body
22
35
</CascadingValue >
23
36
</CascadingValue >
24
- </article >
25
- </main >
26
- </div >
37
+ </div >
38
+ </RadzenBody >
39
+ </RadzenLayout >
27
40
28
41
@code {
42
+ private bool _sidebarExpanded = true ;
29
43
private Toast ? _toastRef ;
30
44
private Alert ? _alertRef ;
31
45
}
Load Diff This file was deleted.
Load Diff This file was deleted.
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 11
11
<PackageReference Include =" Microsoft.AspNetCore.Components.WebAssembly" Version =" 8.0.0" />
12
12
<PackageReference Include =" Microsoft.AspNetCore.Components.WebAssembly.DevServer" Version =" 8.0.0" PrivateAssets =" all" />
13
13
<PackageReference Include =" Microsoft.AspNetCore.Components.WebAssembly.Authentication" Version =" 8.0.0" />
14
+ <PackageReference Include =" Radzen.Blazor" Version =" 4.22.1" />
14
15
</ItemGroup >
15
16
16
17
<ItemGroup >
17
18
<ProjectReference Include =" ..\Logistics.BlazorComponents\Logistics.BlazorComponents.csproj" />
18
19
<ProjectReference Include =" ..\Logistics.Client\Logistics.Client.csproj" />
19
20
</ItemGroup >
20
-
21
- <ItemGroup >
22
- <_ContentIncludedByDefault Remove =" wwwroot\sample-data\weather.json" />
23
- </ItemGroup >
24
-
25
21
</Project >
Original file line number Diff line number Diff line change 1
- @page " /authentication/{action}"
1
+ @page " /authentication/{action}"
2
2
@using Microsoft .AspNetCore .Components .WebAssembly .Authentication
3
3
<RemoteAuthenticatorView Action =" @Action" />
4
4
Original file line number Diff line number Diff line change 1
- @page " /"
1
+ @page " /"
2
2
@attribute [Authorize]
3
3
4
4
<PageTitle >Logistics Admin</PageTitle >
5
-
6
- <h1 >Site Administration</h1 >
5
+ <RadzenText TextStyle =" TextStyle.H3" >Dashboard</RadzenText >
7
6
8
7
<table class =" table table-hover" >
9
8
<thead >
Original file line number Diff line number Diff line change 1
- @page " /edit-tenant /{id?}"
1
+ @page " /tenants /{id?}"
2
2
@inherits PageBase
3
3
4
4
@{
Original file line number Diff line number Diff line change 1
- @page " /list-tenant "
1
+ @page " /tenants "
2
2
@using Logistics .Shared .Models
3
+ @using TextAlign = Logistics .BlazorComponents .Grids .TextAlign
3
4
@inherits PageBase
4
5
5
6
<h2 >Tenants List</h2 >
You can’t perform that action at this time.
0 commit comments