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:
@@ -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);
|
||||
|
||||
Reference in New Issue
Block a user