demo/Pages/Account/Settings/Components/BaseView.razor.cs
2024-06-21 16:48:24 +08:00

24 lines
600 B
C#

using System.Threading.Tasks;
using antblazorpro.Models;
using antblazorpro.Services;
using Microsoft.AspNetCore.Components;
namespace antblazorpro.Pages.Account.Settings
{
public partial class BaseView
{
private CurrentUser _currentUser = new CurrentUser();
[Inject] protected IUserService UserService { get; set; }
private void HandleFinish()
{
}
protected override async Task OnInitializedAsync()
{
await base.OnInitializedAsync();
_currentUser = await UserService.GetCurrentUserAsync();
}
}
}