RAGFlow is an agent-native database: a Retrieval-Augmented Generation (RAG) engine that grew into context infrastructure.
Go agent-harnessagent-native-databaseagentic-aiagentic-retrievalagentic-searchaiai-agentscontext-enginecontext-engineeringcontext-managementharness-engineeringknowledge-compilationragretrieval-augmented-generationretrieval-harnesssearch-harness
Fix: hide model settings button and related functionality (#16563)
chanx16b8c79a2b5a
diff --git a/web/src/pages/user-setting/setting-model/components/used-model.tsx b/web/src/pages/user-setting/setting-model/components/used-model.tsxindex fa8365c1e8..0e02a87b52 100644--- a/web/src/pages/user-setting/setting-model/components/used-model.tsx+++ b/web/src/pages/user-setting/setting-model/components/used-model.tsx@@ -14,7 +14,6 @@ import {useEditInstanceModel,useFetchAddedProviders,useFetchInstanceModels,- useFetchProviderInstance,useFetchProviderInstances,useUpdateModelStatus,} from '@/hooks/use-llm-request';@@ -25,13 +24,7 @@ import {} from '@/interfaces/database/llm';import { IProviderModelItem } from '@/interfaces/request/llm';import { cn } from '@/lib/utils';-import {- ChevronsDown,- ChevronsUp,- Pencil,- Settings,- Trash2,-} from 'lucide-react';+import { ChevronsDown, ChevronsUp, Pencil, Trash2 } from 'lucide-react';import { useCallback, useMemo, useState } from 'react';import { useTranslation } from 'react-i18next';import { AddCustomModelDialog } from '../modal/provider-modal/components/add-custom-model-dialog';@@ -204,8 +197,8 @@ function InstanceRow({function InstanceModelList({providerName,instanceName,- instance,- onEditInstance,+ // instance,+ // onEditInstance,}: {providerName: string;instanceName: string;@@ -220,25 +213,25 @@ function InstanceModelList({// Lazily fetches the full instance details (incl. baseUrl) only when// the user opens the settings dialog — keeps the collapsed section// cheap and avoids the extra request for users who never click it.- const { refetch: fetchInstanceDetails } = useFetchProviderInstance(- providerName,- instanceName,- );+ // const { refetch: fetchInstanceDetails } = useFetchProviderInstance(+ // providerName,+ // instanceName,+ // );- const handleSettingsClick = useCallback(async () => {- let details: IProviderInstance = instance;- try {- const ret = await fetchInstanceDetails();- if (ret.data) {- details = { ...instance, ...(ret.data as IProviderInstance) };- }- } catch {- // Fall back to the list-level instance data if the show request- // fails (e.g. network error) — the modal still gets a usable- // baseline.- }- onEditInstance?.(providerName, details, models);- }, [fetchInstanceDetails, instance, models, onEditInstance, providerName]);+ // const handleSettingsClick = useCallback(async () => {+ // let details: IProviderInstance = instance;+ // try {+ // const ret = await fetchInstanceDetails();+ // if (ret.data) {+ // details = { ...instance, ...(ret.data as IProviderInstance) };+ // }+ // } catch {+ // // Fall back to the list-level instance data if the show request+ // // fails (e.g. network error) — the modal still gets a usable+ // // baseline.+ // }+ // onEditInstance?.(providerName, details, models);+ // }, [fetchInstanceDetails, instance, models, onEditInstance, providerName]);const modelTypes = useMemo(() => {const types = new Set<string>();@@ -265,9 +258,9 @@ function InstanceModelList({</span>))}</div>- <Button size="icon" variant="ghost" onClick={handleSettingsClick}>+ {/* <Button size="icon" variant="ghost" onClick={handleSettingsClick}><Settings size={12} />- </Button>+ </Button> */}</div>)}