feat: restrict admin areas and show mobile pickups

Limit monitoring and journal access to admins, reduce regular-user navigation,
and show the latest pickup directly in mobile configuration cards.
This commit is contained in:
2026-08-05 20:10:22 +02:00
parent 713f52caa0
commit a64bfe2d3f
10 changed files with 103 additions and 47 deletions

View File

@@ -1037,7 +1037,7 @@ async function checkWatchedStores(sessionId, settings = DEFAULT_SETTINGS, option
return [];
}
const session = sessionStore.get(sessionId);
if (!session?.profile?.id) {
if (!session?.profile?.id || !session.isAdmin) {
return [];
}
const watchers = readStoreWatch(session.profile.id);
@@ -1132,7 +1132,7 @@ async function checkWatchedStores(sessionId, settings = DEFAULT_SETTINGS, option
function scheduleStoreWatchers(sessionId, settings) {
const effectiveSettings = settings || DEFAULT_SETTINGS;
const session = sessionStore.get(sessionId);
if (!session?.profile?.id) {
if (!session?.profile?.id || !session.isAdmin) {
return false;
}
const watchers = readStoreWatch(session.profile.id);