diff --git a/framework/src/Volo.Abp.AspNetCore.Components/Volo.Abp.AspNetCore.Components.csproj b/framework/src/Volo.Abp.AspNetCore.Components/Volo.Abp.AspNetCore.Components.csproj index 1b81b8e6d9b..628661a1846 100644 --- a/framework/src/Volo.Abp.AspNetCore.Components/Volo.Abp.AspNetCore.Components.csproj +++ b/framework/src/Volo.Abp.AspNetCore.Components/Volo.Abp.AspNetCore.Components.csproj @@ -15,7 +15,7 @@ - + diff --git a/framework/src/Volo.Abp.AspNetCore.Components/Volo/Abp/AspNetCore/Components/AbpAspNetCoreComponentsModule.cs b/framework/src/Volo.Abp.AspNetCore.Components/Volo/Abp/AspNetCore/Components/AbpAspNetCoreComponentsModule.cs index 677f9d8ccaa..b73432b38a5 100644 --- a/framework/src/Volo.Abp.AspNetCore.Components/Volo/Abp/AspNetCore/Components/AbpAspNetCoreComponentsModule.cs +++ b/framework/src/Volo.Abp.AspNetCore.Components/Volo/Abp/AspNetCore/Components/AbpAspNetCoreComponentsModule.cs @@ -6,13 +6,14 @@ using Volo.Abp.Modularity; using Volo.Abp.ObjectMapping; using Volo.Abp.Security; +using Volo.Abp.Timing; namespace Volo.Abp.AspNetCore.Components; [DependsOn( typeof(AbpObjectMappingModule), typeof(AbpSecurityModule), - typeof(AbpLocalizationModule) + typeof(AbpTimingModule) )] public class AbpAspNetCoreComponentsModule : AbpModule { diff --git a/framework/src/Volo.Abp.AspNetCore.Components/Volo/Abp/AspNetCore/Components/AbpComponentBase.cs b/framework/src/Volo.Abp.AspNetCore.Components/Volo/Abp/AspNetCore/Components/AbpComponentBase.cs index b9c97b30b42..66acd8f171c 100644 --- a/framework/src/Volo.Abp.AspNetCore.Components/Volo/Abp/AspNetCore/Components/AbpComponentBase.cs +++ b/framework/src/Volo.Abp.AspNetCore.Components/Volo/Abp/AspNetCore/Components/AbpComponentBase.cs @@ -11,7 +11,9 @@ using Volo.Abp.AspNetCore.Components.Messages; using Volo.Abp.AspNetCore.Components.Notifications; using Volo.Abp.Localization; +using Volo.Abp.MultiTenancy; using Volo.Abp.ObjectMapping; +using Volo.Abp.Timing; using Volo.Abp.Users; namespace Volo.Abp.AspNetCore.Components; @@ -54,6 +56,9 @@ protected Type LocalizationResource { protected ICurrentUser CurrentUser => LazyGetRequiredService(ref _currentUser); private ICurrentUser _currentUser; + protected ICurrentTenant CurrentTenant => LazyGetRequiredService(ref _currentTenant); + private ICurrentTenant _currentTenant; + protected IUiMessageService Message => LazyGetNonScopedRequiredService(ref _message); private IUiMessageService _message; @@ -66,6 +71,9 @@ protected Type LocalizationResource { protected IAlertManager AlertManager => LazyGetNonScopedRequiredService(ref _alertManager); private IAlertManager _alertManager; + protected IClock Clock => LazyGetNonScopedRequiredService(ref _clock); + private IClock _clock; + protected AlertList Alerts => AlertManager.Alerts; protected IObjectMapper ObjectMapper {