From a9f45b0861e451f4c45a141b3368f9a856795cc2 Mon Sep 17 00:00:00 2001 From: Joseph Doherty Date: Wed, 20 May 2026 19:46:09 -0400 Subject: [PATCH] refactor(ui): rename AuditLog viewer to ConfigurationAuditLog under /audit/configuration (#23 M7) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The pre-M1 IAuditService config-change viewer moves out of the Monitoring nav group to make room for the new Audit nav group (issue #23 M7). The old route /monitoring/audit-log returns 404 (no redirect, per plan) — the viewer is now reachable at /audit/configuration and labelled "Configuration Audit Log" to disambiguate from the new Audit Log page (arriving in #23 M7-T9). Inbound references in NavMenu, Dashboard, and the Playwright nav tests are updated to the new route and label. --- src/ScadaLink.CentralUI/Components/Layout/NavMenu.razor | 4 ++-- .../AuditLog.razor => Audit/ConfigurationAuditLog.razor} | 4 ++-- src/ScadaLink.CentralUI/Components/Pages/Dashboard.razor | 4 ++-- .../ScadaLink.CentralUI.PlaywrightTests/NavigationTests.cs | 1 - .../RoleNavigationTests.cs | 6 +++--- 5 files changed, 9 insertions(+), 10 deletions(-) rename src/ScadaLink.CentralUI/Components/Pages/{Monitoring/AuditLog.razor => Audit/ConfigurationAuditLog.razor} (99%) diff --git a/src/ScadaLink.CentralUI/Components/Layout/NavMenu.razor b/src/ScadaLink.CentralUI/Components/Layout/NavMenu.razor index 78fb4f2..851c4f7 100644 --- a/src/ScadaLink.CentralUI/Components/Layout/NavMenu.razor +++ b/src/ScadaLink.CentralUI/Components/Layout/NavMenu.razor @@ -108,11 +108,11 @@ - @* Audit Log — Admin only *@ + @* Configuration Audit Log — Admin only *@ diff --git a/src/ScadaLink.CentralUI/Components/Pages/Monitoring/AuditLog.razor b/src/ScadaLink.CentralUI/Components/Pages/Audit/ConfigurationAuditLog.razor similarity index 99% rename from src/ScadaLink.CentralUI/Components/Pages/Monitoring/AuditLog.razor rename to src/ScadaLink.CentralUI/Components/Pages/Audit/ConfigurationAuditLog.razor index 96d7108..df5e58c 100644 --- a/src/ScadaLink.CentralUI/Components/Pages/Monitoring/AuditLog.razor +++ b/src/ScadaLink.CentralUI/Components/Pages/Audit/ConfigurationAuditLog.razor @@ -1,4 +1,4 @@ -@page "/monitoring/audit-log" +@page "/audit/configuration" @using ScadaLink.Security @using ScadaLink.CentralUI.Components @using ScadaLink.Commons.Entities.Audit @@ -8,7 +8,7 @@ @inject IJSRuntime JS
-

Audit Log

+

Configuration Audit Log

diff --git a/src/ScadaLink.CentralUI/Components/Pages/Dashboard.razor b/src/ScadaLink.CentralUI/Components/Pages/Dashboard.razor index ce24f60..7935084 100644 --- a/src/ScadaLink.CentralUI/Components/Pages/Dashboard.razor +++ b/src/ScadaLink.CentralUI/Components/Pages/Dashboard.razor @@ -70,10 +70,10 @@
- +
-
Recent Audit Log
+
Configuration Audit Log

Browse changes to configuration and deployments.

diff --git a/tests/ScadaLink.CentralUI.PlaywrightTests/NavigationTests.cs b/tests/ScadaLink.CentralUI.PlaywrightTests/NavigationTests.cs index acbc746..962b641 100644 --- a/tests/ScadaLink.CentralUI.PlaywrightTests/NavigationTests.cs +++ b/tests/ScadaLink.CentralUI.PlaywrightTests/NavigationTests.cs @@ -68,7 +68,6 @@ public class NavigationTests [InlineData("Health Dashboard", "/monitoring/health")] [InlineData("Event Logs", "/monitoring/event-logs")] [InlineData("Parked Messages", "/monitoring/parked-messages")] - [InlineData("Audit Log", "/monitoring/audit-log")] public async Task MonitoringNavLinks_NavigateCorrectly(string linkText, string expectedPath) { var page = await _fixture.NewAuthenticatedPageAsync(); diff --git a/tests/ScadaLink.CentralUI.PlaywrightTests/RoleNavigationTests.cs b/tests/ScadaLink.CentralUI.PlaywrightTests/RoleNavigationTests.cs index e394edf..508ec56 100644 --- a/tests/ScadaLink.CentralUI.PlaywrightTests/RoleNavigationTests.cs +++ b/tests/ScadaLink.CentralUI.PlaywrightTests/RoleNavigationTests.cs @@ -158,16 +158,16 @@ public class RoleNavigationTests } [Fact] - public async Task DeploymentUser_SeesMonitoringButNotAuditLog() + public async Task DeploymentUser_SeesMonitoringButNotConfigurationAuditLog() { var page = await _fixture.NewAuthenticatedPageAsync("deployer", "password"); // Event Logs and Parked Messages are Deployment-role gated, so a - // Deployment user sees them; Audit Log is Admin-only. + // Deployment user sees them; Configuration Audit Log is Admin-only. await AssertNavLinkVisible(page, "Health Dashboard"); await AssertNavLinkVisible(page, "Event Logs"); await AssertNavLinkVisible(page, "Parked Messages"); - await AssertNavLinkHidden(page, "Audit Log"); + await AssertNavLinkHidden(page, "Configuration Audit Log"); } // ── Multi-role user (Admin + Design + Deployment) ───────────────