1
1
mirror of https://github.com/Fabio286/antares.git synced 2025-06-05 21:59:22 +02:00

fix: custom connection icon disappears during connection, fixes #939

This commit is contained in:
2025-03-31 14:24:34 +02:00
parent d912faa850
commit 1d1be55d3d
3 changed files with 10 additions and 11 deletions

View File

@@ -151,7 +151,7 @@ export const useWorkspacesStore = defineStore('workspaces', {
this.workspaces = (this.workspaces as Workspace[]).map(workspace => workspace.uid === connection.uid
? {
...workspace,
structure: [],
structure: [] as WorkspaceStructure[],
breadcrumbs: {},
loadedSchemas: new Set(),
database: connection.database,
@@ -167,7 +167,7 @@ export const useWorkspacesStore = defineStore('workspaces', {
this.workspaces = (this.workspaces as Workspace[]).map(workspace => workspace.uid === connection.uid
? {
...workspace,
structure: [],
structure: [] as WorkspaceStructure[],
breadcrumbs: {},
loadedSchemas: new Set(),
connectionStatus: 'disconnected'
@@ -187,7 +187,7 @@ export const useWorkspacesStore = defineStore('workspaces', {
this.workspaces = (this.workspaces as Workspace[]).map(workspace => workspace.uid === connection.uid
? {
...workspace,
structure: [],
structure: [] as WorkspaceStructure[],
breadcrumbs: {},
loadedSchemas: new Set(),
connectionStatus: 'failed'
@@ -200,9 +200,7 @@ export const useWorkspacesStore = defineStore('workspaces', {
return reject(new Error('Connection aborted by user'));
else {
let clientCustomizations: Customizations;
const { updateLastConnection } = connectionsStore;
updateLastConnection(connection.uid);
connectionsStore.updateLastConnection(connection.uid);
switch (connection.client) {
case 'mysql':
@@ -418,7 +416,7 @@ export const useWorkspacesStore = defineStore('workspaces', {
this.workspaces = (this.workspaces as Workspace[]).map(workspace => workspace.uid === uid
? {
...workspace,
structure: [],
structure: [] as WorkspaceStructure[],
breadcrumbs: {},
loadedSchemas: new Set(),
connectionStatus: 'disconnected'