Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 2 additions & 11 deletions packages/editor-ui/src/views/SettingsSso.vue
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { Notification } from 'element-ui';
import { useSSOStore } from '@/stores/sso';
import { useUsageStore } from '@/stores/usage';
import { useUIStore } from '@/stores/ui';
import { BaseTextKey, i18n as locale } from '@/plugins/i18n';
import { i18n as locale } from '@/plugins/i18n';
import CopyInput from '@/components/CopyInput.vue';

const ssoStore = useSSOStore();
Expand Down Expand Up @@ -56,16 +56,7 @@ const onTest = async () => {
};

const goToUpgrade = () => {
const linkUrlTranslationKey = uiStore.contextBasedTranslationKeys.upgradeLinkUrl as BaseTextKey;
let linkUrl = locale.baseText(linkUrlTranslationKey);

if (linkUrlTranslationKey.endsWith('.upgradeLinkUrl')) {
linkUrl = `${usageStore.viewPlansUrl}&source=sso`;
} else if (linkUrlTranslationKey.endsWith('.desktop')) {
linkUrl = `${linkUrl}&utm_campaign=upgrade-sso`;
}

window.open(linkUrl, '_blank');
uiStore.goToUpgrade('sso', 'upgrade-sso`');
};

onBeforeMount(async () => {
Expand Down