mirror of
https://github.com/open-webui/open-webui.git
synced 2025-12-15 13:55:19 +00:00
feat: 屏蔽选项中的部分功能,默认启用记忆功能
This commit is contained in:
parent
4f6de98909
commit
574da93e1a
5 changed files with 14 additions and 2 deletions
|
|
@ -168,6 +168,7 @@ class UsersTable:
|
||||||
"email": email,
|
"email": email,
|
||||||
"role": role,
|
"role": role,
|
||||||
"profile_image_url": profile_image_url,
|
"profile_image_url": profile_image_url,
|
||||||
|
"settings": {"ui": {"memory": True}},
|
||||||
"last_active_at": int(time.time()),
|
"last_active_at": int(time.time()),
|
||||||
"created_at": int(time.time()),
|
"created_at": int(time.time()),
|
||||||
"updated_at": int(time.time()),
|
"updated_at": int(time.time()),
|
||||||
|
|
|
||||||
|
|
@ -241,8 +241,10 @@
|
||||||
<UpdatePassword />
|
<UpdatePassword />
|
||||||
</div>
|
</div>
|
||||||
{/if}
|
{/if}
|
||||||
|
|
||||||
{#if ($config?.features?.enable_api_key ?? true) || $user?.role === 'admin'}
|
<!-- ai-friend 屏蔽api显示 -->
|
||||||
|
{#if $user?.role === 'admin'}
|
||||||
|
<!-- {#if ($config?.features?.enable_api_key ?? true) || $user?.role === 'admin'} -->
|
||||||
<div class="flex justify-between items-center text-sm mt-2">
|
<div class="flex justify-between items-center text-sm mt-2">
|
||||||
<div class=" font-medium">{$i18n.t('API keys')}</div>
|
<div class=" font-medium">{$i18n.t('API keys')}</div>
|
||||||
<button
|
<button
|
||||||
|
|
|
||||||
|
|
@ -713,6 +713,8 @@
|
||||||
</button>
|
</button>
|
||||||
{/if}
|
{/if}
|
||||||
{:else if tabId === 'personalization'}
|
{:else if tabId === 'personalization'}
|
||||||
|
<!-- ai-friend 屏蔽个性化选项 -->
|
||||||
|
{#if $user?.role === 'admin'}
|
||||||
<button
|
<button
|
||||||
role="tab"
|
role="tab"
|
||||||
aria-controls="tab-personalization"
|
aria-controls="tab-personalization"
|
||||||
|
|
@ -736,6 +738,7 @@
|
||||||
</div>
|
</div>
|
||||||
<div class=" self-center">{$i18n.t('Personalization')}</div>
|
<div class=" self-center">{$i18n.t('Personalization')}</div>
|
||||||
</button>
|
</button>
|
||||||
|
{/if}
|
||||||
{:else if tabId === 'audio'}
|
{:else if tabId === 'audio'}
|
||||||
<button
|
<button
|
||||||
role="tab"
|
role="tab"
|
||||||
|
|
|
||||||
|
|
@ -53,11 +53,14 @@
|
||||||
{/if}
|
{/if}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<!-- ai-friend 屏蔽管理员账号显示 -->
|
||||||
|
{#if false}
|
||||||
{#if adminDetails}
|
{#if adminDetails}
|
||||||
<div class="mt-4 text-sm font-medium text-center">
|
<div class="mt-4 text-sm font-medium text-center">
|
||||||
<div>{$i18n.t('Admin')}: {adminDetails.name} ({adminDetails.email})</div>
|
<div>{$i18n.t('Admin')}: {adminDetails.name} ({adminDetails.email})</div>
|
||||||
</div>
|
</div>
|
||||||
{/if}
|
{/if}
|
||||||
|
{/if}
|
||||||
|
|
||||||
<div class=" mt-6 mx-auto relative group w-fit">
|
<div class=" mt-6 mx-auto relative group w-fit">
|
||||||
<button
|
<button
|
||||||
|
|
|
||||||
|
|
@ -295,6 +295,8 @@
|
||||||
{/if}
|
{/if}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<!-- ai-friend 暂时不支持option -->
|
||||||
|
{#if false}
|
||||||
{#if focused && (filteredOptions.length > 0 || filteredItems.length > 0)}
|
{#if focused && (filteredOptions.length > 0 || filteredItems.length > 0)}
|
||||||
<!-- svelte-ignore a11y-no-static-element-interactions -->
|
<!-- svelte-ignore a11y-no-static-element-interactions -->
|
||||||
<div
|
<div
|
||||||
|
|
@ -385,4 +387,5 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
{/if}
|
{/if}
|
||||||
|
{/if}
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue