diff --git a/packages/frontend-core/src/components/grid/lib/websocket.js b/packages/frontend-core/src/components/grid/lib/websocket.js index b0fd236989..e7b89ff58a 100644 --- a/packages/frontend-core/src/components/grid/lib/websocket.js +++ b/packages/frontend-core/src/components/grid/lib/websocket.js @@ -61,6 +61,15 @@ export const createGridWebsocket = context => { } } ) + socket.on( + GridSocketEvent.DatasourceChange, + ({ datasource: newDatasource }) => { + // Listen builder renames, as these aren't handled otherwise + if (newDatasource?.name !== get(definition).name) { + definition.set(newDatasource) + } + } + ) // Change websocket connection when table changes datasource.subscribe(connectToDatasource)