mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-04-19 16:36:00 +00:00
SYNC: new cloud file
This commit is contained in:
committed by
Diflow
parent
fa321d3e8d
commit
d004e6e86c
@@ -40,8 +40,7 @@
|
||||
import runCommand from '../commands/runCommand';
|
||||
import SaveFileModal from '../modals/SaveFileModal.svelte';
|
||||
import newQuery from '../query/newQuery';
|
||||
import openNewTab from '../utility/openNewTab';
|
||||
|
||||
|
||||
let filter = '';
|
||||
let domSqlObjectList = null;
|
||||
|
||||
@@ -115,7 +114,7 @@
|
||||
command: 'new.connectionOnCloud',
|
||||
},
|
||||
{
|
||||
text: 'New SQL file',
|
||||
text: 'New SQL script',
|
||||
onClick: () => {
|
||||
const data = '';
|
||||
showModal(SaveFileModal, {
|
||||
@@ -124,21 +123,14 @@
|
||||
folid: privateFolderId,
|
||||
folder: 'sql',
|
||||
onSave: (name, { savedFile, savedFolder, savedFilePath, savedCloudFolderId, savedCloudContentId }) => {
|
||||
openNewTab(
|
||||
{
|
||||
title: name,
|
||||
icon: 'img sql-file',
|
||||
tabComponent: 'QueryTab',
|
||||
props: {
|
||||
savedFolder: 'sql',
|
||||
savedFormat: 'text',
|
||||
savedFile,
|
||||
savedCloudFolderId,
|
||||
savedCloudContentId,
|
||||
},
|
||||
},
|
||||
{ editor: data }
|
||||
);
|
||||
newQuery({
|
||||
// @ts-ignore
|
||||
savedFolder: 'sql',
|
||||
savedFormat: 'text',
|
||||
savedFile,
|
||||
savedCloudFolderId,
|
||||
savedCloudContentId,
|
||||
});
|
||||
},
|
||||
});
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user