fix(editor): Fix Admin panel icon in the sidebar for cloud deployments (no-changelog) (#7738)
Co-authored-by: ricardo <ricardoespinoza105@gmail.com> Co-authored-by: Mutasem Aldmour <mutasem@n8n.io>
This commit is contained in:
committed by
GitHub
parent
b66b8c18e9
commit
2d039010db
@@ -151,6 +151,12 @@ export const useCloudPlanStore = defineStore(STORES.CLOUD_PLAN, () => {
|
||||
} catch {}
|
||||
};
|
||||
|
||||
const redirectToDashboard = async () => {
|
||||
const adminPanelHost = new URL(window.location.href).host.split('.').slice(1).join('.');
|
||||
const { code } = await getAutoLoginCode();
|
||||
window.location.href = `https://${adminPanelHost}/login?code=${code}`;
|
||||
};
|
||||
|
||||
return {
|
||||
state,
|
||||
getOwnerCurrentPlan,
|
||||
@@ -166,5 +172,6 @@ export const useCloudPlanStore = defineStore(STORES.CLOUD_PLAN, () => {
|
||||
checkForCloudPlanData,
|
||||
fetchUserCloudAccount,
|
||||
getAutoLoginCode,
|
||||
redirectToDashboard,
|
||||
};
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user