revert https://github.com/langgenius/dify/pull/19497 (19497) (#19807)
Co-authored-by: qingguo <qingguo@lexin.com>
This commit is contained in:
@@ -4,7 +4,7 @@ import { useTranslation } from 'react-i18next'
|
||||
import { Menu, MenuButton, MenuItems, Transition } from '@headlessui/react'
|
||||
import { RiArrowDownSLine } from '@remixicon/react'
|
||||
import cn from '@/utils/classnames'
|
||||
import { WEB_PREFIX } from '@/config'
|
||||
import { basePath } from '@/utils/var'
|
||||
import PlanBadge from '@/app/components/header/plan-badge'
|
||||
import { switchWorkspace } from '@/service/common'
|
||||
import { useWorkspacesContext } from '@/context/workspace-context'
|
||||
@@ -23,7 +23,7 @@ const WorkplaceSelector = () => {
|
||||
return
|
||||
await switchWorkspace({ url: '/workspaces/switch', body: { tenant_id } })
|
||||
notify({ type: 'success', message: t('common.actionMsg.modifiedSuccessfully') })
|
||||
location.assign(WEB_PREFIX)
|
||||
location.assign(`${location.origin}${basePath}`)
|
||||
}
|
||||
catch {
|
||||
notify({ type: 'error', message: t('common.provider.saveFailed') })
|
||||
|
||||
Reference in New Issue
Block a user