-
Notifications
You must be signed in to change notification settings - Fork 526
Expand file tree
/
Copy pathScriptExportService.ts
More file actions
32 lines (28 loc) · 1.01 KB
/
ScriptExportService.ts
File metadata and controls
32 lines (28 loc) · 1.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
/*
* CloudBeaver - Cloud Database Manager
* Copyright (C) 2020-2026 DBeaver Corp and others
*
* Licensed under the Apache License, Version 2.0.
* you may not use this file except in compliance with the License.
*/
import { injectable } from '@cloudbeaver/core-di';
import { TabsContainer } from '@cloudbeaver/core-ui';
import { CommonDialogService } from '@cloudbeaver/core-dialogs';
import { ExportScriptDialog } from './ExportScriptDialog/ExportScriptDialogLazy.js';
export interface IScriptExportTabProps {
script: string;
fileName: string;
editorId: string;
projectId?: string;
connectionId?: string;
}
@injectable(() => [CommonDialogService])
export class ScriptExportService {
readonly tabsContainer: TabsContainer<IScriptExportTabProps>;
constructor(private readonly commonDialogService: CommonDialogService) {
this.tabsContainer = new TabsContainer('script_export_tabs');
}
openExportDialog(props: IScriptExportTabProps) {
return this.commonDialogService.open(ExportScriptDialog, props);
}
}