From 97a92269adb0c9a1e543a203a299c90b5a071144 Mon Sep 17 00:00:00 2001 From: Penry Date: Sun, 15 Feb 2026 23:38:02 +0100 Subject: [PATCH] feat: added Remove Button for removing Privte Entity from PrivateList --- CouchLog/Components/Pages/PrivateList.razor | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/CouchLog/Components/Pages/PrivateList.razor b/CouchLog/Components/Pages/PrivateList.razor index 545671e..293e060 100644 --- a/CouchLog/Components/Pages/PrivateList.razor +++ b/CouchLog/Components/Pages/PrivateList.razor @@ -179,7 +179,9 @@ - + @@ -189,6 +191,16 @@ }; + private async Task RemoveEntityFromPrivateList(PrivateEntity entity) + { + //Delete DB + CouchLogDB.PrivateEntities.Remove(entity); + await CouchLogDB.SaveChangesAsync(); + + //Delete Memory List + PrivateEntities.Remove(entity); + } + private async Task UpdateWatchStatus(PrivateEntity entity, object? newValue) { if (int.TryParse(newValue?.ToString(), out int newId)) -- 2.49.1