From bbd9ce568e9e23f1a73e82a922a1288924e9f5f1 Mon Sep 17 00:00:00 2001 From: maliming Date: Wed, 29 Jul 2026 10:38:31 +0800 Subject: [PATCH] Notify Blazor components when application configuration cache is reset --- ...verCurrentApplicationConfigurationCacheResetService.cs | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/framework/src/Volo.Abp.AspNetCore.Components.Server/Volo/Abp/AspNetCore/Components/Server/Configuration/BlazorServerCurrentApplicationConfigurationCacheResetService.cs b/framework/src/Volo.Abp.AspNetCore.Components.Server/Volo/Abp/AspNetCore/Components/Server/Configuration/BlazorServerCurrentApplicationConfigurationCacheResetService.cs index 144d975cb5..e550d75858 100644 --- a/framework/src/Volo.Abp.AspNetCore.Components.Server/Volo/Abp/AspNetCore/Components/Server/Configuration/BlazorServerCurrentApplicationConfigurationCacheResetService.cs +++ b/framework/src/Volo.Abp.AspNetCore.Components.Server/Volo/Abp/AspNetCore/Components/Server/Configuration/BlazorServerCurrentApplicationConfigurationCacheResetService.cs @@ -1,6 +1,7 @@ using System; using System.Threading.Tasks; using Volo.Abp.AspNetCore.Components.Web.Configuration; +using Volo.Abp.AspNetCore.Components.Web.Security; using Volo.Abp.AspNetCore.Mvc.ApplicationConfigurations; using Volo.Abp.DependencyInjection; using Volo.Abp.EventBus.Local; @@ -13,15 +14,20 @@ public class BlazorServerCurrentApplicationConfigurationCacheResetService : ITransientDependency { private readonly ILocalEventBus _localEventBus; + private readonly ApplicationConfigurationChangedService _applicationConfigurationChangedService; public BlazorServerCurrentApplicationConfigurationCacheResetService( - ILocalEventBus localEventBus) + ILocalEventBus localEventBus, + ApplicationConfigurationChangedService applicationConfigurationChangedService) { _localEventBus = localEventBus; + _applicationConfigurationChangedService = applicationConfigurationChangedService; } public async Task ResetAsync(Guid? userId = null) { await _localEventBus.PublishAsync(new CurrentApplicationConfigurationCacheResetEventData(userId)); + + _applicationConfigurationChangedService.NotifyChanged(); } }