mirror of
https://github.com/csunny/DB-GPT.git
synced 2025-09-11 05:49:22 +00:00
Merge branch 'dbgpts_hub_dev' of https://github.com/eosphoros-ai/DB-GPT into dbgpts_hub_dev
This commit is contained in:
@@ -362,9 +362,9 @@ export const postAgentUninstall = (pluginName: string, user?: string) => {
|
||||
timeout: 60000,
|
||||
});
|
||||
};
|
||||
export const postDbgptsUninstall = (pluginName: string, user?: string) => {
|
||||
export const postDbgptsUninstall = (data: { name: string, type: string }, user?: string) => {
|
||||
return POST("/api/v1/serve/dbgpts/my/uninstall", undefined, {
|
||||
params: { name: pluginName, user },
|
||||
params: { ...data, user },
|
||||
timeout: 60000,
|
||||
});
|
||||
};
|
||||
|
@@ -325,6 +325,7 @@ export const CommonEn = {
|
||||
Copy_Btn: 'Copy',
|
||||
Delete_Btn: 'Delete',
|
||||
dbgpts_community: 'DBGPTS Community',
|
||||
community_dbgpts: 'Community DBGPTS',
|
||||
my_dbgpts: 'My DBGPTS',
|
||||
Refresh_dbgpts: 'Refresh from the community Git repository',
|
||||
workflow: 'Workflow',
|
||||
|
@@ -327,6 +327,7 @@ export const CommonZh: Resources["translation"] = {
|
||||
Copy_Btn: '复制',
|
||||
Delete_Btn: '删除',
|
||||
dbgpts_community: 'DBGPTS社区',
|
||||
community_dbgpts: '社区DBGPTS',
|
||||
my_dbgpts: '我的DBGPTS',
|
||||
Refresh_dbgpts: '从社区Git仓库刷新',
|
||||
workflow: '工作流',
|
||||
|
@@ -52,7 +52,7 @@ const BlurredCard: React.FC<{
|
||||
<span
|
||||
className="line-clamp-1 text-ellipsis font-semibold text-base"
|
||||
style={{
|
||||
// maxWidth: '60%',
|
||||
maxWidth: '60%',
|
||||
}}
|
||||
>
|
||||
{name}
|
||||
@@ -62,7 +62,7 @@ const BlurredCard: React.FC<{
|
||||
<span
|
||||
className="line-clamp-1 text-ellipsis font-semibold text-base"
|
||||
style={{
|
||||
// maxWidth: '60%',
|
||||
maxWidth: '60%',
|
||||
}}
|
||||
>
|
||||
{name}
|
||||
|
@@ -81,7 +81,7 @@ function Agent() {
|
||||
}, [activeKey, typeStr]);
|
||||
|
||||
const pluginAction = useCallback(
|
||||
async (agent: { name: string }, index: number, isInstall: boolean) => {
|
||||
async (agent: { name: string, type: string }, index: number, isInstall: boolean) => {
|
||||
if (actionIndex) return;
|
||||
setActionIndex(index);
|
||||
setLoading(true);
|
||||
@@ -90,7 +90,10 @@ function Agent() {
|
||||
const [err] = await apiInterceptors(postDbgptsInstall(agent));
|
||||
errs = err;
|
||||
} else {
|
||||
const [err] = await apiInterceptors(postDbgptsUninstall(agent.name));
|
||||
const [err] = await apiInterceptors(postDbgptsUninstall({
|
||||
name: agent.name,
|
||||
type: agent.type
|
||||
}));
|
||||
errs = err;
|
||||
}
|
||||
setLoading(false);
|
||||
@@ -105,7 +108,7 @@ function Agent() {
|
||||
const items: SegmentedProps['options'] = [
|
||||
{
|
||||
value: 'market',
|
||||
label: 'DBGPTS',
|
||||
label: t('community_dbgpts'),
|
||||
},
|
||||
{
|
||||
value: 'my',
|
||||
|
Reference in New Issue
Block a user