feat(cooked): „Heute gekocht" räumt Wunschliste für das Rezept
All checks were successful
Build & Publish Docker Image / build-and-push (push) Successful in 1m18s
All checks were successful
Build & Publish Docker Image / build-and-push (push) Successful in 1m18s
Wenn ein Rezept heute gekocht wurde, ist der Wunsch eingelöst — raus damit aus der Wunschliste aller Profile. Server tut das beim POST in einem Rutsch (removeFromWishlistForAll) und meldet removed_from_wishlist in der Response zurück. Der Client räumt daraufhin den lokalen wishlistProfileIds-State und refresht den Badge-Zähler, damit der Wunschliste-Button und das Header-Badge sofort passen — kein Reload nötig. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -111,6 +111,10 @@
|
||||
});
|
||||
const entry = await res.json();
|
||||
cookingLog = [entry, ...cookingLog];
|
||||
if (entry.removed_from_wishlist) {
|
||||
wishlistProfileIds = [];
|
||||
void wishlistStore.refresh();
|
||||
}
|
||||
}
|
||||
|
||||
async function addComment() {
|
||||
|
||||
Reference in New Issue
Block a user