This commit is contained in:
Timothy Jaeryang Baek 2026-08-13 17:26:38 -06:00
parent 7593698080
commit 2c01d59335
3 changed files with 11 additions and 17 deletions

View file

@ -15,7 +15,7 @@ from open_webui.models.automations import (
AutomationRuns,
Automations,
)
from open_webui.models.access_grants import AccessGrants
from open_webui.models.access_grants import AccessGrants, has_public_write_access_grant
from open_webui.models.channels import Channels
from open_webui.models.config import Config
from open_webui.models.folders import Folders
@ -134,12 +134,8 @@ async def check_automation_channel_access(form_data: AutomationForm, user, db: A
if channel.type in ['group', 'dm']:
allowed = await Channels.is_user_channel_member(channel.id, user.id, db=db)
else:
allowed = await AccessGrants.has_access(
user_id=user.id,
resource_type='channel',
resource_id=channel.id,
permission='write',
db=db,
allowed = has_public_write_access_grant(channel.access_grants) or await AccessGrants.has_access(
user_id=user.id, resource_type='channel', resource_id=channel.id, permission='write', db=db
)
if not allowed:
raise HTTPException(

View file

@ -304,11 +304,10 @@
<div class="scrollbar-hidden relative whitespace-nowrap overflow-x-auto max-w-full">
{#if (items ?? []).length === 0}
<div class="w-full h-full flex flex-col justify-center items-center my-16 mb-24">
<div class="max-w-md text-center">
<div class="text-3xl mb-3">😕</div>
<div class="text-lg font-normal mb-1">{$i18n.t('No feedback found')}</div>
<div class="text-gray-500 text-center text-xs">
<div class="flex w-full flex-col items-center justify-center py-16 pb-24">
<div class="max-w-sm text-center text-gray-900 dark:text-gray-100">
<div class="mb-1.5 text-sm">{$i18n.t('No feedback found')}</div>
<div class="text-center text-xs leading-5 text-gray-500">
{$i18n.t('Try adjusting your search or filter to find what you are looking for.')}
</div>
</div>

View file

@ -184,11 +184,10 @@
{/each}
</div>
{:else}
<div class="w-full h-full flex flex-col justify-center items-center my-16 mb-24">
<div class="max-w-md text-center">
<div class="text-3xl mb-3">👥</div>
<div class="text-lg font-normal mb-1">{$i18n.t('No groups found')}</div>
<div class="text-gray-500 text-center text-xs">
<div class="flex w-full flex-col items-center justify-center py-16 pb-24">
<div class="max-w-sm text-center text-gray-900 dark:text-gray-100">
<div class="mb-1.5 text-sm">{$i18n.t('No groups found')}</div>
<div class="text-center text-xs leading-5 text-gray-500">
{$i18n.t('Use groups to organize your users and assign permissions.')}
</div>
</div>