mirror of
https://github.com/dbeaver/cloudbeaver.git
synced 2026-09-24 16:04:36 +08:00
fix: CB-2239 metadata tabs opening
This commit is contained in:
@@ -31,17 +31,17 @@ export class TabNavigationContext implements ITabNavigationContext {
|
||||
return this._handlerPriority;
|
||||
}
|
||||
|
||||
get tab(): ITab<any> | null {
|
||||
get tab(): ITab | null {
|
||||
return this._tab;
|
||||
}
|
||||
|
||||
private _isNewlyCreated = false;
|
||||
private _handlerPriority = 0;
|
||||
private readonly _handlerPriority = 0;
|
||||
private _tab: ITab | null = null;
|
||||
|
||||
constructor(
|
||||
private navigationTabsService: NavigationTabsService,
|
||||
private userInfoResource: UserInfoResource
|
||||
private readonly navigationTabsService: NavigationTabsService,
|
||||
private readonly userInfoResource: UserInfoResource
|
||||
) { }
|
||||
|
||||
openNewTab<T = any>(options: ITabOptions<T>): ITab<T> {
|
||||
|
||||
@@ -80,6 +80,7 @@ export class DataViewerTabService {
|
||||
const {
|
||||
nodeInfo,
|
||||
tabInfo,
|
||||
initTab,
|
||||
trySwitchPage,
|
||||
} = await contexts.getContext(this.objectViewerTabService.objectViewerTabContext);
|
||||
|
||||
@@ -89,6 +90,8 @@ export class DataViewerTabService {
|
||||
return;
|
||||
}
|
||||
|
||||
initTab();
|
||||
|
||||
if (tabInfo.isNewlyCreated) {
|
||||
trySwitchPage(this.page);
|
||||
}
|
||||
|
||||
+2
@@ -53,6 +53,8 @@ export class ObjectPropertiesPageService {
|
||||
|
||||
try {
|
||||
const tabContext = await contexts.getContext(this.objectViewerTabService.objectViewerTabContext);
|
||||
|
||||
tabContext.initTab();
|
||||
tabContext.trySwitchPage(this.page);
|
||||
} catch (exception: any) {
|
||||
this.notificationService.logException(exception, 'Object Viewer Error', 'Error in Object Viewer while processing action with database node');
|
||||
|
||||
@@ -126,7 +126,7 @@ export class ObjectViewerTabService {
|
||||
return tabInfo.tab;
|
||||
}
|
||||
|
||||
return null;
|
||||
return tabInfo.tab;
|
||||
};
|
||||
|
||||
const getPage = () => {
|
||||
|
||||
Reference in New Issue
Block a user