From 2cbead8bc4c794a57d2b09299258ce8716125ed1 Mon Sep 17 00:00:00 2001 From: Adria Navarro Date: Mon, 3 Jul 2023 11:47:42 +0100 Subject: [PATCH] Fetch relationships --- .../backend/DataTable/modals/CreateEditColumn.svelte | 5 ++++- .../DataTable/modals/grid/GridCreateColumnModal.svelte | 8 +------- 2 files changed, 5 insertions(+), 8 deletions(-) diff --git a/packages/builder/src/components/backend/DataTable/modals/CreateEditColumn.svelte b/packages/builder/src/components/backend/DataTable/modals/CreateEditColumn.svelte index 318b7d9663..665175a435 100644 --- a/packages/builder/src/components/backend/DataTable/modals/CreateEditColumn.svelte +++ b/packages/builder/src/components/backend/DataTable/modals/CreateEditColumn.svelte @@ -186,7 +186,10 @@ saveColumn.type === LINK_TYPE && saveColumn.relationshipType === RelationshipTypes.MANY_TO_MANY ) { - dispatch("updatetables") + // Fetching the new tables + tables.fetch() + // Fetching the new relationships + datasources.fetch() } if (originalName) { notifications.success("Column updated successfully") diff --git a/packages/builder/src/components/backend/DataTable/modals/grid/GridCreateColumnModal.svelte b/packages/builder/src/components/backend/DataTable/modals/grid/GridCreateColumnModal.svelte index d0d3b81d84..9e386ae140 100644 --- a/packages/builder/src/components/backend/DataTable/modals/grid/GridCreateColumnModal.svelte +++ b/packages/builder/src/components/backend/DataTable/modals/grid/GridCreateColumnModal.svelte @@ -1,7 +1,6 @@ - { - tables.fetch() - }} - /> +