5 Commits

Author SHA1 Message Date
594541a103 Merge pull request 'penry-patch-1' (#47) from penry-patch-1 into main
All checks were successful
Build Docker Linux ARM64 / build-docker-linux-arm64 (push) Successful in 45s
Reviewed-on: #47
2026-02-21 22:39:18 +01:00
ee7bcc1eae README.md aktualisiert 2026-02-21 22:38:01 +01:00
4fe354add0 README.md aktualisiert 2026-02-21 22:36:12 +01:00
c6355d47df Merge pull request 'feat: added Remove Button for removing Privte Entity from PrivateList' (#46) from AddRemovePrivateEntityFromList into main
All checks were successful
Build Docker Linux ARM64 / build-docker-linux-arm64 (push) Successful in 1m35s
Reviewed-on: #46
2026-02-15 23:39:01 +01:00
97a92269ad feat: added Remove Button for removing Privte Entity from PrivateList 2026-02-15 23:38:02 +01:00
2 changed files with 16 additions and 2 deletions

View File

@@ -179,7 +179,9 @@
<h5 class="modal-title">Optionen</h5> <h5 class="modal-title">Optionen</h5>
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button> <button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
</div> </div>
<div class="modal-body">Optionen...</div> <div class="modal-body">
<button type="button" class="btn btn-danger" @onclick="@(e => RemoveEntityFromPrivateList(Entity))" data-bs-dismiss="modal">Aus PrivateList entfernen</button>
</div>
<div class="modal-footer"> <div class="modal-footer">
<button type="button" class="btn btn-secondary" data-bs-dismiss="modal">Schließen</button> <button type="button" class="btn btn-secondary" data-bs-dismiss="modal">Schließen</button>
</div> </div>
@@ -189,6 +191,16 @@
</div> </div>
}; };
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) private async Task UpdateWatchStatus(PrivateEntity entity, object? newValue)
{ {
if (int.TryParse(newValue?.ToString(), out int newId)) if (int.TryParse(newValue?.ToString(), out int newId))

View File

@@ -1,2 +1,4 @@
# Watchlog # Watchlog
## Work in Progress ## Work in Progress
### Information
- This Repo has a Mirror on Codeberg, but the Releases a only available on [Gitea](https://gitea.penry.de/Penry/CouchLog) for now