diff --git a/packages/core/client/src/built-in/index.tsx b/packages/core/client/src/built-in/index.tsx index 69ef17cfa..aff04fd14 100644 --- a/packages/core/client/src/built-in/index.tsx +++ b/packages/core/client/src/built-in/index.tsx @@ -341,7 +341,6 @@ export class BuiltInPlugin extends Plugin { ui: { order: 50, component: 'DesignableSwitch', pin: true, snippet: 'ui.*' }, wf: { order: 100, component: 'WorkflowLink', pin: true, snippet: 'pm.*' }, ds: { order: 200, component: 'DatasourceLink', pin: true, snippet: 'pm.*' }, - pm: { order: 300, component: 'PluginManagerLink', pin: true, snippet: 'pm' }, sc: { order: 400, component: 'SettingsCenterDropdown', pin: true, snippet: 'pm.*' }, }, }, diff --git a/packages/core/client/src/built-in/pm/PluginManager.tsx b/packages/core/client/src/built-in/pm/PluginManager.tsx index b93c39835..82e6e98d6 100644 --- a/packages/core/client/src/built-in/pm/PluginManager.tsx +++ b/packages/core/client/src/built-in/pm/PluginManager.tsx @@ -1,7 +1,6 @@ -import React, { useEffect, useMemo, useState } from 'react'; +import React, { useMemo, useState } from 'react'; import { fuzzysearch } from '@tachybase/utils/client'; -import { PageHeader } from '@ant-design/pro-layout'; import { useDebounce } from 'ahooks'; import { Button, @@ -350,25 +349,10 @@ const MarketplacePlugins = () => { }; export const PluginManager = () => { - const params = useParams(); - const navigate = useNavigate(); - const { tabName = 'local' } = params; - const { t } = useTranslation(); const { snippets = [] } = useACLRoleContext(); - const { styles } = useStyles(); - - useEffect(() => { - const { tabName } = params; - if (!tabName) { - navigate(`/admin/pm/list/local/`, { replace: true }); - } - }, []); return snippets.includes('pm') ? ( -
- - -
+ ) : ( ); diff --git a/packages/core/client/src/built-in/pm/PluginManagerLink.tsx b/packages/core/client/src/built-in/pm/PluginManagerLink.tsx index 71cf9422a..252313a1e 100644 --- a/packages/core/client/src/built-in/pm/PluginManagerLink.tsx +++ b/packages/core/client/src/built-in/pm/PluginManagerLink.tsx @@ -9,24 +9,6 @@ import { useApp } from '../../application'; import { useCompile } from '../../schema-component'; import { useToken } from '../../style'; -export const PluginManagerLink = () => { - const { t } = useTranslation(); - const navigate = useNavigate(); - const { token } = useToken(); - return ( - -