From bec9e3eb7d1b92a8aa647b9409852aeac5d32197 Mon Sep 17 00:00:00 2001 From: kolaente Date: Mon, 18 Mar 2024 14:21:52 +0100 Subject: [PATCH] fix(views): set current project after modifying views --- frontend/src/stores/projects.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/frontend/src/stores/projects.ts b/frontend/src/stores/projects.ts index 4448a657e..e6b436e6a 100644 --- a/frontend/src/stores/projects.ts +++ b/frontend/src/stores/projects.ts @@ -216,10 +216,13 @@ export const useProjectStore = defineStore('project', () => { const viewPos = projects.value[view.projectId].views.findIndex(v => v.id === view.id) if (viewPos !== -1) { projects.value[view.projectId].views[viewPos] = view + setProject(projects.value[view.projectId]) return } projects.value[view.projectId].views.push(view) + + setProject(projects.value[view.projectId]) } function removeProjectView(projectId: IProject['id'], viewId: IProjectView['id']) {