feat(web): add association between models and conversation features

This commit is contained in:
zhaoying
2026-03-24 11:06:27 +08:00
parent cbec2c1356
commit 3369b702e4
8 changed files with 125 additions and 75 deletions

View File

@@ -2,7 +2,7 @@
* @Author: ZhaoYing
* @Date: 2026-03-13 17:20:21
* @Last Modified by: ZhaoYing
* @Last Modified time: 2026-03-18 15:38:59
* @Last Modified time: 2026-03-24 11:00:25
*/
import { type FC, useRef } from 'react';
import { useTranslation } from 'react-i18next';
@@ -11,6 +11,7 @@ import { Button } from 'antd';
import FeaturesConfigModal from './FeaturesConfigModal'
import type { FeaturesConfigModalRef, FeaturesConfigForm } from '../../types'
import type { Application } from '@/views/ApplicationManagement/types';
import type { Capability } from '@/views/ModelManagement/types'
/** Props for the FeaturesConfig component */
interface FeaturesConfigProps {
@@ -19,12 +20,14 @@ interface FeaturesConfigProps {
/** Callback to propagate updated config back to the parent */
refresh: (value: FeaturesConfigForm) => void;
source?: Application['type'];
capability?: Capability[];
}
const FeaturesConfig: FC<FeaturesConfigProps> = ({
value,
refresh,
source
source,
capability
}) => {
const { t } = useTranslation();
// Ref used to imperatively open the config modal
@@ -46,6 +49,7 @@ const FeaturesConfig: FC<FeaturesConfigProps> = ({
ref={funConfigModalRef}
refresh={refresh}
source={source}
capability={capability}
/>
</>
)