mirror of
https://github.com/apache/superset.git
synced 2026-06-01 21:59:26 +00:00
fix(sqllab): prevent unwanted tab switching when autocompleting table names on SQL Lab (#35992)
This commit is contained in:
committed by
GitHub
parent
d123249bd2
commit
9fbfcf0ccd
@@ -950,7 +950,13 @@ export function mergeTable(table, query, prepend) {
|
||||
return { type: MERGE_TABLE, table, query, prepend };
|
||||
}
|
||||
|
||||
export function addTable(queryEditor, tableName, catalogName, schemaName) {
|
||||
export function addTable(
|
||||
queryEditor,
|
||||
tableName,
|
||||
catalogName,
|
||||
schemaName,
|
||||
expanded = true,
|
||||
) {
|
||||
return function (dispatch, getState) {
|
||||
const { dbId } = getUpToDateQuery(getState(), queryEditor, queryEditor.id);
|
||||
const table = {
|
||||
@@ -964,7 +970,7 @@ export function addTable(queryEditor, tableName, catalogName, schemaName) {
|
||||
mergeTable({
|
||||
...table,
|
||||
id: nanoid(11),
|
||||
expanded: true,
|
||||
expanded,
|
||||
}),
|
||||
);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user