mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-04-27 19:36:00 +00:00
better DB export UI
This commit is contained in:
@@ -95,7 +95,7 @@
|
|||||||
{#if electron}
|
{#if electron}
|
||||||
<FormStyledButton type="button" value="Browse" on:click={handleBrowse} />
|
<FormStyledButton type="button" value="Browse" on:click={handleBrowse} />
|
||||||
{:else}
|
{:else}
|
||||||
<FormStyledButton type="button" value="Download" on:click={handleDownload} />
|
<FormStyledButton type="button" value="Set download" on:click={handleDownload} />
|
||||||
{/if}
|
{/if}
|
||||||
<FormStyledButton type="button" value="Files folder" on:click={handleFilesFolder} />
|
<FormStyledButton type="button" value="Files folder" on:click={handleFilesFolder} />
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -4,8 +4,10 @@
|
|||||||
import FormStyledButton from '../buttons/FormStyledButton.svelte';
|
import FormStyledButton from '../buttons/FormStyledButton.svelte';
|
||||||
|
|
||||||
import FormProvider from '../forms/FormProvider.svelte';
|
import FormProvider from '../forms/FormProvider.svelte';
|
||||||
|
import FontIcon from '../icons/FontIcon.svelte';
|
||||||
import SocketMessageView from '../query/SocketMessageView.svelte';
|
import SocketMessageView from '../query/SocketMessageView.svelte';
|
||||||
import { apiCall, apiOff, apiOn } from '../utility/api';
|
import { apiCall, apiOff, apiOn } from '../utility/api';
|
||||||
|
import { showSnackbarError } from '../utility/snackbar';
|
||||||
import ModalBase from './ModalBase.svelte';
|
import ModalBase from './ModalBase.svelte';
|
||||||
import { closeCurrentModal } from './modalTools';
|
import { closeCurrentModal } from './modalTools';
|
||||||
|
|
||||||
@@ -24,6 +26,7 @@
|
|||||||
const handleStop = async () => {
|
const handleStop = async () => {
|
||||||
closeCurrentModal();
|
closeCurrentModal();
|
||||||
apiCall('runners/cancel', { runid });
|
apiCall('runners/cancel', { runid });
|
||||||
|
isCanceled = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
const handleClose = () => {
|
const handleClose = () => {
|
||||||
@@ -39,12 +42,9 @@
|
|||||||
function handleRunnerDone() {
|
function handleRunnerDone() {
|
||||||
isRunning = false;
|
isRunning = false;
|
||||||
apiOff(`runner-done-${runid}`, handleRunnerDone);
|
apiOff(`runner-done-${runid}`, handleRunnerDone);
|
||||||
// if (isCanceled) {
|
if (isCanceled) {
|
||||||
// showSnackbarError(canceledMessage);
|
showSnackbarError('Process canceled');
|
||||||
// } else {
|
}
|
||||||
// showSnackbarInfo(finishedMessage);
|
|
||||||
// if (afterFinish) afterFinish();
|
|
||||||
// }
|
|
||||||
}
|
}
|
||||||
|
|
||||||
apiOn(`runner-done-${runid}`, handleRunnerDone);
|
apiOn(`runner-done-${runid}`, handleRunnerDone);
|
||||||
@@ -58,7 +58,12 @@
|
|||||||
<FormProvider>
|
<FormProvider>
|
||||||
<ModalBase {...$$restProps}>
|
<ModalBase {...$$restProps}>
|
||||||
<svelte:fragment slot="header">
|
<svelte:fragment slot="header">
|
||||||
|
<div class="flex">
|
||||||
{header}
|
{header}
|
||||||
|
{#if isRunning}
|
||||||
|
<FontIcon icon="icon loading" padLeft />
|
||||||
|
{/if}
|
||||||
|
</div>
|
||||||
</svelte:fragment>
|
</svelte:fragment>
|
||||||
|
|
||||||
<div class="messages">
|
<div class="messages">
|
||||||
|
|||||||
Reference in New Issue
Block a user