Public-Recht: formats auch bei show_check lesbar
Anonyme Leseberechtigung auf formats filterte nur active=true, wodurch die nicht oeffentlich bestellbaren Check-Formate (A5, DIN lang) im oeffentlichen Textmengencheck unsichtbar blieben. Jetzt: active ODER show_check. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -1196,8 +1196,11 @@ async function applyPermissions() {
|
||||
// Public (Gast): nur aktive Kataloge lesen
|
||||
const pubPol = await ensurePolicy('Public (Skrift)', { app: false });
|
||||
await ensureAccess(null, pubPol.id);
|
||||
for (const col of ['products', 'formats', 'motifs', 'price_items'])
|
||||
for (const col of ['products', 'motifs', 'price_items'])
|
||||
await ensurePermission(pubPol.id, col, 'read', ['*'], { active: { _eq: true } });
|
||||
// formats: aktiv (Konfigurator) ODER show_check (Textmengencheck). Sonst blieben die
|
||||
// nicht öffentlich bestellbaren Check-Formate (A5, DIN lang) für Anonyme unsichtbar.
|
||||
await ensurePermission(pubPol.id, 'formats', 'read', ['*'], { _or: [{ active: { _eq: true } }, { show_check: { _eq: true } }] });
|
||||
await ensurePermission(pubPol.id, 'pricing_settings', 'read');
|
||||
|
||||
// Service (Backend + Produktion): Jobs/Orders lesen + Status schreiben
|
||||
|
||||
Reference in New Issue
Block a user