mirror of
https://github.com/CodePhiliaX/Chat2DB.git
synced 2025-08-06 01:36:46 +08:00
Merge remote-tracking branch 'origin/team' into team
This commit is contained in:
@ -148,7 +148,7 @@ export const dataSourceFormConfigs: IConnectionConfig[] = [
|
||||
inputType: InputType.SELECT,
|
||||
labelNameCN: '环境',
|
||||
labelNameEN: 'Env',
|
||||
name: 'env',
|
||||
name: 'environmentId',
|
||||
required: true,
|
||||
selects: [],
|
||||
styles: {
|
||||
|
@ -77,8 +77,9 @@ export default forwardRef(function CreateConnection(props: IProps, ref: Forwarde
|
||||
return t.type === backfillData.type
|
||||
});
|
||||
data.baseInfo.items.forEach((t: IFormItem) => {
|
||||
if (t.name === 'env' && envList?.length) {
|
||||
if (t.name === 'environmentId' && envList?.length) {
|
||||
t.selects = envList;
|
||||
t.defaultValue = envList[0].value;
|
||||
}
|
||||
})
|
||||
return data;
|
||||
|
@ -135,10 +135,7 @@ function DataSourceManagement() {
|
||||
if (JSON.stringify(connectionInfo.current) === '{}') {
|
||||
return;
|
||||
}
|
||||
connectionInfo.current = {
|
||||
...data,
|
||||
environmentId: 2,
|
||||
}
|
||||
connectionInfo.current = data;
|
||||
|
||||
const isUpdate = isValid(connectionInfo?.current?.id);
|
||||
const requestApi = isUpdate ? updateDataSource : createDataSource;
|
||||
|
@ -181,7 +181,7 @@ function UniversalDrawer(props: IProps) {
|
||||
type: AffiliationType.TEAM_DATASOURCE,
|
||||
searchType: SearchType.DATASOURCE,
|
||||
title: '归属链接',
|
||||
byIdKey: 'userId',
|
||||
byIdKey: 'teamId',
|
||||
queryListApi: getDataSourceListFromTeam,
|
||||
updateListApi: updateDataSourceListFromTeam,
|
||||
deleteApi: deleteDataSourceFromTeam,
|
||||
|
Reference in New Issue
Block a user