translation-clipboard, exportMenu, macros, datagrid commands

This commit is contained in:
Stela Augustinova
2025-10-31 15:10:17 +01:00
parent 9884ace309
commit 82a4b2c769
16 changed files with 406 additions and 212 deletions

View File

@@ -40,7 +40,16 @@
$: dataLabeled = _.compact(
(list || []).map(data => {
const matchResult = matcher ? matcher(data) : true;
const dataCopy = { ...data };
if (dataCopy?.group && _.isFunction(dataCopy.group)) dataCopy.group = dataCopy.group();
if (dataCopy?.title && _.isFunction(dataCopy.title)) dataCopy.title = dataCopy.title();
if (dataCopy?.description && _.isFunction(dataCopy.description)) dataCopy.description = dataCopy.description();
(dataCopy?.args || []).map(x => {
if(x?.label && _.isFunction(x.label)) x.label = x.label();
})
const matchResult = matcher ? matcher(dataCopy) : true;
let isMatched = true;
let isMainMatched = true;
@@ -62,8 +71,8 @@
isChildMatched = !module.disableShowChildrenWithParentMatch;
}
const group = groupFunc ? groupFunc(data) : undefined;
return { group, data, isMatched, isChildMatched, isMainMatched };
const group = groupFunc ? groupFunc(dataCopy) : undefined;
return { group, data: dataCopy, isMatched, isChildMatched, isMainMatched };
})
);

View File

@@ -1,6 +1,6 @@
<script context="module">
function getCommandTitle(command) {
let res = command.text;
let res = _.isFunction(command.text) ? command.text() : command.text;
if (command.keyText || command.keyTextFromGroup) {
res += ` (${formatKeyText(command.keyText || command.keyTextFromGroup)})`;
}
@@ -12,6 +12,7 @@
import { commandsCustomized } from '../stores';
import { formatKeyText } from '../utility/common';
import ToolStripButton from './ToolStripButton.svelte';
import _ from 'lodash';
export let command;
export let component = ToolStripButton;
@@ -32,6 +33,6 @@
{iconAfter}
{...$$restProps}
>
{buttonLabel || cmd.toolbarName || cmd.name}
{(_.isFunction(buttonLabel) ? buttonLabel() : buttonLabel) || (_.isFunction(cmd?.toolbarName) ? cmd.toolbarName() : cmd.toolbarName) || (_.isFunction(cmd?.name) ? cmd.name() : cmd.name)}
</svelte:component>
{/if}

View File

@@ -23,7 +23,7 @@
import hasPermission from '../utility/hasPermission';
import ToolStripCommandButton from './ToolStripCommandButton.svelte';
import ToolStripDropDownButton from './ToolStripDropDownButton.svelte';
import _ from 'lodash';
export let quickExportHandlerRef = null;
export let command = 'sqlDataGrid.export';
export let label = 'Export';
@@ -39,7 +39,7 @@
{#if hasPermission('dbops/export')}
{#if quickExportHandlerRef}
<ToolStripDropDownButton menu={getExportMenu} {label} icon="icon export" />
<ToolStripDropDownButton menu={getExportMenu} label={_.isFunction(label) ? label() : label} icon="icon export" />
{:else}
<ToolStripCommandButton {command} />
{/if}

View File

@@ -1,5 +1,6 @@
import { commands } from '../stores';
import { invalidateCommandDefinitions } from './invalidateCommands';
import _ from 'lodash';
export interface SubCommand {
text: string;
@@ -8,7 +9,7 @@ export interface SubCommand {
export interface GlobalCommand {
id: string;
category: string; // null for group commands
category: string | (() => string); // null for group commands
isGroupCommand?: boolean;
name: string | (() => string);
text?: string | (() => string);
@@ -23,7 +24,7 @@ export interface GlobalCommand {
toolbar?: boolean;
enabled?: boolean;
showDisabled?: boolean;
toolbarName?: string;
toolbarName?: string | (() => string);
menuName?: string;
toolbarOrder?: number;
disableHandleKeyText?: string;
@@ -41,7 +42,13 @@ export default function registerCommand(command: GlobalCommand) {
return {
...x,
[command.id]: {
text: `${command.category}: ${command.name}`,
text:
_.isFunction(command.category) || _.isFunction(command.name)
? () =>
`${_.isFunction(command.category) ? command.category() : command.category}: ${
_.isFunction(command.name) ? command.name() : command.name
}`
: `${command.category}: ${command.name}`,
...command,
enabled: !testEnabled,
},

View File

@@ -3,8 +3,8 @@
registerCommand({
id: 'dataGrid.switchToForm',
category: 'Data grid',
name: 'Switch to form',
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.switchToform', { defaultMessage: 'Switch to form' }),
icon: 'icon form',
keyText: 'F4',
testEnabled: () => getCurrentEditor()?.switchViewEnabled('form'),
@@ -13,8 +13,8 @@
registerCommand({
id: 'dataGrid.switchToJson',
category: 'Data grid',
name: 'Switch to JSON',
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.switchToJSON', { defaultMessage: 'Switch to JSON' }),
icon: 'icon json',
keyText: 'F4',
testEnabled: () => getCurrentEditor()?.switchViewEnabled('json'),
@@ -23,8 +23,8 @@
registerCommand({
id: 'dataGrid.switchToTable',
category: 'Data grid',
name: 'Switch to table',
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.witchToTable', { defaultMessage: 'Switch to table'}),
icon: 'icon table',
keyText: 'F4',
testEnabled: () => getCurrentEditor()?.switchViewEnabled('table'),
@@ -33,8 +33,8 @@
registerCommand({
id: 'dataGrid.toggleLeftPanel',
category: 'Data grid',
name: 'Toggle left panel',
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.toggleLeftPanel', { defaultMessage: 'Toggle left panel' }),
keyText: 'CtrlOrCommand+L',
testEnabled: () => getCurrentEditor()?.canShowLeftPanel(),
onClick: () => getCurrentEditor().toggleLeftPanel(),
@@ -68,7 +68,7 @@
import registerCommand from '../commands/registerCommand';
import { registerMenu } from '../utility/contextMenu';
import { getLocalStorage, setLocalStorage } from '../utility/storageCache';
import { _t } from '../translations';
import { __t, _t } from '../translations';
export let config;
export let setConfig;

View File

@@ -3,8 +3,8 @@
registerCommand({
id: 'dataGrid.refresh',
category: 'Data grid',
name: _t('common.refresh', { defaultMessage: 'Refresh' }),
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('common.refresh', { defaultMessage: 'Refresh' }),
keyText: 'F5 | CtrlOrCommand+R',
toolbar: true,
isRelatedToTab: true,
@@ -15,8 +15,8 @@
registerCommand({
id: 'dataGrid.deepRefresh',
category: 'Data grid',
name: 'Refresh with structure',
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('common.datagrid.deepRefresh', { defaultMessage: 'Refresh with structure' }),
keyText: 'Ctrl+F5',
toolbar: true,
isRelatedToTab: true,
@@ -27,8 +27,8 @@
registerCommand({
id: 'dataGrid.revertRowChanges',
category: 'Data grid',
name: _t('command.datagrid.revertRowChanges', { defaultMessage: 'Revert row changes' }),
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.revertRowChanges', { defaultMessage: 'Revert row changes' }),
keyText: 'CtrlOrCommand+U',
testEnabled: () => getCurrentDataGrid()?.getGrider()?.containsChanges,
onClick: () => getCurrentDataGrid().revertRowChanges(),
@@ -36,9 +36,9 @@
registerCommand({
id: 'dataGrid.revertAllChanges',
category: 'Data grid',
name: _t('command.datagrid.revertAllChanges', { defaultMessage: 'Revert all changes' }),
toolbarName: _t('command.datagrid.revertAllChanges.toolbar', { defaultMessage: 'Revert all' }),
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.revertAllChanges', { defaultMessage: 'Revert all changes' }),
toolbarName: __t('command.datagrid.revertAllChanges.toolbar', { defaultMessage: 'Revert all' }),
icon: 'icon undo',
testEnabled: () => getCurrentDataGrid()?.getGrider()?.containsChanges,
onClick: () => getCurrentDataGrid().revertAllChanges(),
@@ -46,9 +46,9 @@
registerCommand({
id: 'dataGrid.deleteSelectedRows',
category: 'Data grid',
name: _t('command.datagrid.deleteSelectedRows', { defaultMessage: 'Delete selected rows' }),
toolbarName: _t('command.datagrid.deleteSelectedRows.toolbar', { defaultMessage: 'Delete row(s)' }),
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.deleteSelectedRows', { defaultMessage: 'Delete selected rows' }),
toolbarName: __t('command.datagrid.deleteSelectedRows.toolbar', { defaultMessage: 'Delete row(s)' }),
keyText: isMac() ? 'Command+Backspace' : 'CtrlOrCommand+Delete',
icon: 'icon minus',
testEnabled: () => getCurrentDataGrid()?.getGrider()?.editable,
@@ -57,9 +57,9 @@
registerCommand({
id: 'dataGrid.insertNewRow',
category: 'Data grid',
name: _t('command.datagrid.insertNewRow', { defaultMessage: 'Insert new row' }),
toolbarName: _t('command.datagrid.insertNewRow.toolbar', { defaultMessage: 'New row' }),
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.insertNewRow', { defaultMessage: 'Insert new row' }),
toolbarName: __t('command.datagrid.insertNewRow.toolbar', { defaultMessage: 'New row' }),
icon: 'icon add',
keyText: isMac() ? 'Command+I' : 'Insert',
testEnabled: () => getCurrentDataGrid()?.getGrider()?.editable,
@@ -68,9 +68,9 @@
registerCommand({
id: 'dataGrid.addNewColumn',
category: 'Data grid',
name: _t('command.datagrid.addNewColumn', { defaultMessage: 'Add new column' }),
toolbarName: _t('command.datagrid.addNewColumn.toolbar', { defaultMessage: 'New column' }),
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.addNewColumn', { defaultMessage: 'Add new column' }),
toolbarName: __t('command.datagrid.addNewColumn.toolbar', { defaultMessage: 'New column' }),
icon: 'icon add-column',
testEnabled: () => getCurrentDataGrid()?.addNewColumnEnabled(),
onClick: () => getCurrentDataGrid().addNewColumn(),
@@ -78,9 +78,9 @@
registerCommand({
id: 'dataGrid.cloneRows',
category: 'Data grid',
name: _t('command.datagrid.cloneRows', { defaultMessage: 'Clone rows' }),
toolbarName: _t('command.datagrid.cloneRows.toolbar', { defaultMessage: 'Clone row(s)' }),
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.cloneRows', { defaultMessage: 'Clone rows' }),
toolbarName: __t('command.datagrid.cloneRows.toolbar', { defaultMessage: 'Clone row(s)' }),
keyText: 'CtrlOrCommand+Shift+C',
testEnabled: () => getCurrentDataGrid()?.getGrider()?.editable,
onClick: () => getCurrentDataGrid().cloneRows(),
@@ -88,8 +88,8 @@
registerCommand({
id: 'dataGrid.setNull',
category: 'Data grid',
name: _t('command.datagrid.setNull', { defaultMessage: 'Set NULL' }),
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.setNull', { defaultMessage: 'Set NULL' }),
keyText: 'CtrlOrCommand+0',
testEnabled: () =>
getCurrentDataGrid()?.getGrider()?.editable && !getCurrentDataGrid()?.getEditorTypes()?.supportFieldRemoval,
@@ -98,8 +98,8 @@
registerCommand({
id: 'dataGrid.removeField',
category: 'Data grid',
name: _t('command.datagrid.removeField', { defaultMessage: 'Remove field' }),
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.removeField', { defaultMessage: 'Remove field' }),
keyText: 'CtrlOrCommand+0',
testEnabled: () =>
getCurrentDataGrid()?.getGrider()?.editable && getCurrentDataGrid()?.getEditorTypes()?.supportFieldRemoval,
@@ -108,8 +108,8 @@
registerCommand({
id: 'dataGrid.undo',
category: 'Data grid',
name: _t('command.datagrid.undo', { defaultMessage: 'Undo' }),
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.undo', { defaultMessage: 'Undo' }),
group: 'undo',
icon: 'icon undo',
toolbar: true,
@@ -120,8 +120,8 @@
registerCommand({
id: 'dataGrid.redo',
category: 'Data grid',
name: _t('command.datagrid.redo', { defaultMessage: 'Redo' }),
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.redo', { defaultMessage: 'Redo' }),
group: 'redo',
icon: 'icon redo',
toolbar: true,
@@ -132,16 +132,16 @@
registerCommand({
id: 'dataGrid.reconnect',
category: 'Data grid',
name: _t('command.datagrid.reconnect', { defaultMessage: 'Reconnect' }),
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.reconnect', { defaultMessage: 'Reconnect' }),
testEnabled: () => getCurrentDataGrid() != null,
onClick: () => getCurrentDataGrid().reconnect(),
});
registerCommand({
id: 'dataGrid.copyToClipboard',
category: 'Data grid',
name: _t('command.datagrid.copyToClipboard', { defaultMessage: 'Copy to clipboard' }),
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.copyToClipboard', { defaultMessage: 'Copy to clipboard' }),
keyText: 'CtrlOrCommand+C',
disableHandleKeyText: 'CtrlOrCommand+C',
testEnabled: () => getCurrentDataGrid() != null,
@@ -150,7 +150,7 @@
registerCommand({
id: 'dataGrid.editJsonDocument',
category: 'Data grid',
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
keyText: 'CtrlOrCommand+J',
name: __t('command.datagrid.editJsonDocument', { defaultMessage: 'Edit row as JSON document' }),
testEnabled: () => getCurrentDataGrid()?.editJsonEnabled(),
@@ -159,48 +159,48 @@
registerCommand({
id: 'dataGrid.openSelectionInMap',
category: 'Data grid',
name: _t('command.datagrid.openSelectionInMap', { defaultMessage: 'Open selection in map' }),
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.openSelectionInMap', { defaultMessage: 'Open selection in map' }),
testEnabled: () => getCurrentDataGrid() != null,
onClick: () => getCurrentDataGrid().openSelectionInMap(),
});
registerCommand({
id: 'dataGrid.viewJsonDocument',
category: 'Data grid',
name: _t('command.datagrid.viewJsonDocument', { defaultMessage: 'View row as JSON document' }),
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.viewJsonDocument', { defaultMessage: 'View row as JSON document' }),
testEnabled: () => getCurrentDataGrid()?.viewJsonDocumentEnabled(),
onClick: () => getCurrentDataGrid().viewJsonDocument(),
});
registerCommand({
id: 'dataGrid.viewJsonValue',
category: 'Data grid',
name: _t('command.datagrid.viewJsonValue', { defaultMessage: 'View cell as JSON document' }),
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.viewJsonValue', { defaultMessage: 'View cell as JSON document' }),
testEnabled: () => getCurrentDataGrid()?.viewJsonValueEnabled(),
onClick: () => getCurrentDataGrid().viewJsonValue(),
});
registerCommand({
id: 'dataGrid.openJsonArrayInSheet',
category: 'Data grid',
name: _t('command.datagrid.openJsonArrayInSheet', { defaultMessage: 'Open array as table' }),
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.openJsonArrayInSheet', { defaultMessage: 'Open array as table' }),
testEnabled: () => getCurrentDataGrid()?.openJsonArrayInSheetEnabled(),
onClick: () => getCurrentDataGrid().openJsonArrayInSheet(),
});
registerCommand({
id: 'dataGrid.saveCellToFile',
category: 'Data grid',
name: _t('command.datagrid.saveCellToFile', { defaultMessage: 'Save cell to file' }),
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.saveCellToFile', { defaultMessage: 'Save cell to file' }),
testEnabled: () => getCurrentDataGrid()?.saveCellToFileEnabled(),
onClick: () => getCurrentDataGrid().saveCellToFile(),
});
registerCommand({
id: 'dataGrid.loadCellFromFile',
category: 'Data grid',
name: _t('command.datagrid.loadCellFromFile', { defaultMessage: 'Load cell from file' }),
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.loadCellFromFile', { defaultMessage: 'Load cell from file' }),
testEnabled: () => getCurrentDataGrid()?.loadCellFromFileEnabled(),
onClick: () => getCurrentDataGrid().loadCellFromFile(),
});
@@ -216,62 +216,62 @@
//
registerCommand({
id: 'dataGrid.filterSelected',
category: 'Data grid',
name: 'Filter selected value',
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.filterSelected', { defaultMessage : 'Filter selected value'}),
keyText: 'CtrlOrCommand+Shift+F',
testEnabled: () => getCurrentDataGrid()?.getDisplay().filterable,
onClick: () => getCurrentDataGrid().filterSelectedValue(),
});
registerCommand({
id: 'dataGrid.findColumn',
category: 'Data grid',
name: 'Find column',
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.findColumn', { defaultMessage: 'Find column'}),
keyText: 'CtrlOrCommand+F',
testEnabled: () => getCurrentDataGrid() != null,
getSubCommands: () => getCurrentDataGrid().buildFindMenu(),
});
registerCommand({
id: 'dataGrid.hideColumn',
category: 'Data grid',
name: 'Hide column',
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datgrid.hideColumn', { defaultMessage: 'Hide column' }),
keyText: isMac() ? 'Alt+Command+F' : 'CtrlOrCommand+H',
testEnabled: () => getCurrentDataGrid()?.canShowLeftPanel(),
onClick: () => getCurrentDataGrid().hideColumn(),
});
registerCommand({
id: 'dataGrid.clearFilter',
category: 'Data grid',
name: 'Clear filter',
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.clearFilter', { defaultMessage : 'Clear filter'}),
keyText: 'CtrlOrCommand+Shift+E',
testEnabled: () => getCurrentDataGrid()?.clearFilterEnabled(),
onClick: () => getCurrentDataGrid().clearFilter(),
});
registerCommand({
id: 'dataGrid.generateSqlFromData',
category: 'Data grid',
name: 'Generate SQL',
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.generateSql', { defaultMessage: 'Generate SQL'}),
keyText: 'CtrlOrCommand+G',
testEnabled: () => getCurrentDataGrid()?.generateSqlFromDataEnabled(),
onClick: () => getCurrentDataGrid().generateSqlFromData(),
});
registerCommand({
id: 'dataGrid.openFreeTable',
category: 'Data grid',
name: 'Edit selection as table',
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.editSelection', { defaultMessage: 'Edit selection as table'}),
testEnabled: () => getCurrentDataGrid() != null,
onClick: () => getCurrentDataGrid().openFreeTable(),
});
registerCommand({
id: 'dataGrid.newJson',
category: 'Data grid',
name: 'Add JSON document',
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.addJsonDocument', { defaultMessage: 'Add JSON document'}),
testEnabled: () => getCurrentDataGrid()?.addJsonDocumentEnabled(),
onClick: () => getCurrentDataGrid().addJsonDocument(),
});
registerCommand({
id: 'dataGrid.editCellValue',
category: 'Data grid',
name: 'Edit cell value',
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.editCell', { defaultMessage: 'Edit cell value' }),
testEnabled: () => getCurrentDataGrid()?.editCellValueEnabled(),
onClick: () => getCurrentDataGrid().editCellValue(),
});
@@ -279,8 +279,8 @@
if (isProApp()) {
registerCommand({
id: 'dataGrid.sendToDataDeploy',
category: 'Data grid',
name: 'Send to data deployer',
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.sendToDataDeployer', { defaultMessage: 'Send to data deployer' }),
testEnabled: () => getCurrentDataGrid()?.sendToDataDeployEnabled(),
onClick: () => getCurrentDataGrid().sendToDataDeploy(),
});
@@ -1788,15 +1788,15 @@
{ command: 'dataGrid.refresh' },
{ placeTag: 'copy' },
{
text: 'Copy advanced',
text: _t('datagrid.copyAdvanced', { defaultMessage: 'Copy advanced'}),
submenu: [
_.keys(copyRowsFormatDefs).map(format => ({
text: copyRowsFormatDefs[format].label,
text: _.isFunction(copyRowsFormatDefs[format].label) ? copyRowsFormatDefs[format].label() : copyRowsFormatDefs[format].label,
onClick: () => copyToClipboardCore(format),
})),
{ divider: true },
_.keys(copyRowsFormatDefs).map(format => ({
text: `Set format: ${copyRowsFormatDefs[format].name}`,
text: _t('datagrid.setFormat', { defaultMessage: 'Set format: ' }) + (_.isFunction(copyRowsFormatDefs[format].name) ? copyRowsFormatDefs[format].name() : copyRowsFormatDefs[format].name),
onClick: () => ($copyRowsFormat = format),
})),
@@ -1866,7 +1866,7 @@
return [
menu,
{
text: copyRowsFormatDefs[$copyRowsFormat].label,
text: _.isFunction(copyRowsFormatDefs[$copyRowsFormat].label) ? copyRowsFormatDefs[$copyRowsFormat].label() : copyRowsFormatDefs[$copyRowsFormat].label,
onClick: () => copyToClipboardCore($copyRowsFormat),
keyText: 'CtrlOrCommand+C',
tag: 'copy',

View File

@@ -1,18 +1,19 @@
<script context="module" lang="ts">
import { __t } from '../translations'
const getCurrentEditor = () => getActiveComponent('SqlDataGridCore');
registerCommand({
id: 'sqlDataGrid.openQuery',
category: 'Data grid',
name: 'Open query',
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.openQuery', { defaultMessage : 'Open query' }),
testEnabled: () => getCurrentEditor() != null && hasPermission('dbops/query'),
onClick: () => getCurrentEditor().openQuery(),
});
registerCommand({
id: 'sqlDataGrid.export',
category: 'Data grid',
name: 'Export',
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('common.export', { defaultMessage : 'Export' }),
icon: 'icon export',
keyText: 'CtrlOrCommand+E',
testEnabled: () => getCurrentEditor() != null && hasPermission('dbops/export'),

View File

@@ -368,7 +368,7 @@
{/if}
{/key}
{:else}
{row[col.fieldName] || ''}
{ _.isFunction(row[col.fieldName]) ? row[col.fieldName]() : row[col.fieldName] || ''}
{/if}
</td>
{/each}

View File

@@ -1,39 +1,39 @@
import { _t } from '../translations';
import { __t } from '../translations';
const macros = [
{
title: _t('datagrid.macros.removeDiacritics', { defaultMessage: 'Remove diacritics' }),
title: __t('datagrid.macros.removeDiacritics', { defaultMessage: 'Remove diacritics' }),
name: 'removeDiacritics',
group: 'Text',
description: _t('datagrid.macros.removeDiacriticsDescription', { defaultMessage: 'Removes diacritics from selected cells' }),
group: __t('datagrid.macros.textGroup', { defaultMessage: 'Text' }),
description: __t('datagrid.macros.removeDiacriticsDescription', { defaultMessage: 'Removes diacritics from selected cells' }),
type: 'transformValue',
code: `return modules.lodash.deburr(value)`,
},
{
title: _t('datagrid.macros.searchReplaceText', { defaultMessage: 'Search & replace text' }),
title: __t('datagrid.macros.searchReplaceText', { defaultMessage: 'Search & replace text' }),
name: 'stringReplace',
group: 'Text',
description: _t('datagrid.macros.searchReplaceTextDescription', { defaultMessage: 'Search & replace text or regular expression' }),
group: __t('datagrid.macros.textGroup', { defaultMessage: 'Text' }),
description: __t('datagrid.macros.searchReplaceTextDescription', { defaultMessage: 'Search & replace text or regular expression' }),
type: 'transformValue',
args: [
{
type: 'text',
label: _t('datagrid.macros.searchReplaceTextFind', { defaultMessage: 'Find' }),
label: __t('datagrid.macros.searchReplaceTextFind', { defaultMessage: 'Find' }),
name: 'find',
},
{
type: 'text',
label: _t('datagrid.macros.searchReplaceTextReplaceWith', { defaultMessage: 'Replace with' }),
label: __t('datagrid.macros.searchReplaceTextReplaceWith', { defaultMessage: 'Replace with' }),
name: 'replace',
},
{
type: 'checkbox',
label: _t('datagrid.macros.searchReplaceTextCaseSensitive', { defaultMessage: 'Case sensitive' }),
label: __t('datagrid.macros.searchReplaceTextCaseSensitive', { defaultMessage: 'Case sensitive' }),
name: 'caseSensitive',
},
{
type: 'checkbox',
label: _t('datagrid.macros.searchReplaceTextIsRegex', { defaultMessage: 'Regular expression' }),
label: __t('datagrid.macros.searchReplaceTextIsRegex', { defaultMessage: 'Regular expression' }),
name: 'isRegex',
},
],
@@ -44,16 +44,16 @@ return value ? value.toString().replace(new RegExp(rtext, rflags), args.replace
`,
},
{
title: _t('datagrid.macros.changeTextCase', { defaultMessage: 'Change text case' }),
title: __t('datagrid.macros.changeTextCase', { defaultMessage: 'Change text case' }),
name: 'changeTextCase',
group: 'Text',
description: _t('datagrid.macros.changeTextCaseDescription', { defaultMessage: 'Uppercase, lowercase and other case functions' }),
group: __t('datagrid.macros.textGroup', { defaultMessage: 'Text' }),
description: __t('datagrid.macros.changeTextCaseDescription', { defaultMessage: 'Uppercase, lowercase and other case functions' }),
type: 'transformValue',
args: [
{
type: 'select',
options: ['toUpper', 'toLower', 'lowerCase', 'upperCase', 'kebabCase', 'snakeCase', 'camelCase', 'startCase'],
label: _t('datagrid.macros.changeTextCaseType', { defaultMessage: 'Type' }),
label: __t('datagrid.macros.changeTextCaseType', { defaultMessage: 'Type' }),
name: 'type',
default: 'toUpper',
},
@@ -61,81 +61,81 @@ return value ? value.toString().replace(new RegExp(rtext, rflags), args.replace
code: `return modules.lodash[args.type](value)`,
},
{
title: _t('datagrid.macros.padLeft', { defaultMessage: 'Pad left' }),
title: __t('datagrid.macros.padLeft', { defaultMessage: 'Pad left' }),
name: 'padLeft',
group: 'Text',
group: __t('datagrid.macros.textGroup', { defaultMessage: 'Text' }),
args: [
{
type: 'text',
label: _t('datagrid.macros.padCharacter', { defaultMessage: 'Character' }),
label: __t('datagrid.macros.padCharacter', { defaultMessage: 'Character' }),
name: 'character',
default: '0',
},
{
type: 'text',
label: _t('datagrid.macros.padLength', { defaultMessage: 'Length' }),
label: __t('datagrid.macros.padLength', { defaultMessage: 'Length' }),
name: 'length',
default: '3',
},
],
description:
_t('datagrid.macros.padLeftDescription', { defaultMessage: 'Returns string of a specified length in which the beginning of the current string is padded with spaces or other character' }),
__t('datagrid.macros.padLeftDescription', { defaultMessage: 'Returns string of a specified length in which the beginning of the current string is padded with spaces or other character' }),
type: 'transformValue',
code: `return modules.lodash.padStart(value, +args.length, args.character)`,
},
{
title: _t('datagrid.macros.padRight', { defaultMessage: 'Pad right' }),
title: __t('datagrid.macros.padRight', { defaultMessage: 'Pad right' }),
name: 'padRight',
group: 'Text',
group: __t('datagrid.macros.textGroup', { defaultMessage: 'Text' }),
args: [
{
type: 'text',
label: _t('datagrid.macros.padCharacter', { defaultMessage: 'Character' }),
label: __t('datagrid.macros.padCharacter', { defaultMessage: 'Character' }),
name: 'character',
default: '0',
},
{
type: 'text',
label: _t('datagrid.macros.padLength', { defaultMessage: 'Length' }),
label: __t('datagrid.macros.padLength', { defaultMessage: 'Length' }),
name: 'length',
default: '3',
},
],
description:
_t('datagrid.macros.padRightDescription', { defaultMessage: 'Returns string of a specified length in which the end of the current string is padded with spaces or other character' }),
__t('datagrid.macros.padRightDescription', { defaultMessage: 'Returns string of a specified length in which the end of the current string is padded with spaces or other character' }),
type: 'transformValue',
code: `return modules.lodash.padEnd(value, +args.length, args.character)`,
},
{
title: _t('datagrid.macros.trim', { defaultMessage: 'Trim' }),
title: __t('datagrid.macros.trim', { defaultMessage: 'Trim' }),
name: 'trim',
group: 'Text',
description: _t('datagrid.macros.trimDescription', { defaultMessage: 'Removes leading and trailing whitespace' }),
group: __t('datagrid.macros.textGroup', { defaultMessage: 'Text' }),
description: __t('datagrid.macros.trimDescription', { defaultMessage: 'Removes leading and trailing whitespace' }),
type: 'transformValue',
code: `return modules.lodash.trim(value)`,
},
{
title: _t('datagrid.macros.rowIndex', { defaultMessage: 'Row index' }),
title: __t('datagrid.macros.rowIndex', { defaultMessage: 'Row index' }),
name: 'rowIndex',
group: 'Tools',
description: _t('datagrid.macros.rowIndexDescription', { defaultMessage: 'Index of row from 1 (autoincrement)' }),
group: __t('datagrid.macros.toolsGroup', { defaultMessage: 'Tools' }),
description: __t('datagrid.macros.rowIndexDescription', { defaultMessage: 'Index of row from 1 (autoincrement)' }),
type: 'transformValue',
code: `return rowIndex + 1`,
},
{
title: _t('datagrid.macros.generateUUID', { defaultMessage: 'Generate UUID' }),
title: __t('datagrid.macros.generateUUID', { defaultMessage: 'Generate UUID' }),
name: 'uuidv1',
group: 'Tools',
description: _t('datagrid.macros.generateUUIDDescription', { defaultMessage: 'Generate unique identifier' }),
group: __t('datagrid.macros.toolsGroup', { defaultMessage: 'Tools' }),
description: __t('datagrid.macros.generateUUIDDescription', { defaultMessage: 'Generate unique identifier' }),
type: 'transformValue',
args: [
{
type: 'select',
options: [
{ value: 'uuidv1', name: _t('datagrid.macros.uuidv1', { defaultMessage: 'V1 - from timestamp' }) },
{ value: 'uuidv4', name: _t('datagrid.macros.uuidv4', { defaultMessage: 'V4 - random generated' }) },
{ value: 'uuidv1', name: 'V1 - from timestamp' },
{ value: 'uuidv4', name: 'V4 - random generated'},
],
label: _t('datagrid.macros.version', { defaultMessage: 'Version' }),
label: __t('datagrid.macros.version', { defaultMessage: 'Version' }),
name: 'version',
default: 'uuidv1',
},
@@ -143,26 +143,26 @@ return value ? value.toString().replace(new RegExp(rtext, rflags), args.replace
code: `return modules[args.version]()`,
},
{
title: _t('datagrid.macros.toInt', { defaultMessage: 'Convert to integer' }),
title: __t('datagrid.macros.toInt', { defaultMessage: 'Convert to integer' }),
name: 'toInt',
group: 'Tools',
description: _t('datagrid.macros.toIntDescription', { defaultMessage: 'Converts to integral number' }),
group: __t('datagrid.macros.toolsGroup', { defaultMessage: 'Tools' }),
description: __t('datagrid.macros.toIntDescription', { defaultMessage: 'Converts to integral number' }),
type: 'transformValue',
code: `return modules.lodash.isNaN(parseInt(value)) ? null : parseInt(value)`,
},
{
title: _t('datagrid.macros.toNumber', { defaultMessage: 'Convert to number' }),
title: __t('datagrid.macros.toNumber', { defaultMessage: 'Convert to number' }),
name: 'toNumber',
group: 'Tools',
description: _t('datagrid.macros.toNumberDescription', { defaultMessage: 'Converts to number' }),
group: __t('datagrid.macros.toolsGroup', { defaultMessage: 'Tools' }),
description: __t('datagrid.macros.toNumberDescription', { defaultMessage: 'Converts to number' }),
type: 'transformValue',
code: `return modules.lodash.isNaN(parseFloat(value)) ? null : parseFloat(value)`,
},
{
title: _t('datagrid.macros.toBoolean', { defaultMessage: 'Convert to boolean' }),
title: __t('datagrid.macros.toBoolean', { defaultMessage: 'Convert to boolean' }),
name: 'toBoolean',
group: 'Tools',
description: _t('datagrid.macros.toBooleanDescription', { defaultMessage: 'Converts to boolean' }),
group: __t('datagrid.macros.toolsGroup', { defaultMessage: 'Tools' }),
description: __t('datagrid.macros.toBooleanDescription', { defaultMessage: 'Converts to boolean' }),
type: 'transformValue',
code: `
if (modules.lodash.isString(value)) {
@@ -178,10 +178,10 @@ return !!value;
`,
},
{
title: _t('datagrid.macros.toString', { defaultMessage: 'Convert to string' }),
title: __t('datagrid.macros.toString', { defaultMessage: 'Convert to string' }),
name: 'toString',
group: 'Tools',
description: _t('datagrid.macros.toStringDescription', { defaultMessage: 'Converts to string' }),
group: __t('datagrid.macros.toolsGroup', { defaultMessage: 'Tools' }),
description: __t('datagrid.macros.toStringDescription', { defaultMessage: 'Converts to string' }),
type: 'transformValue',
code: `
if (value==null) return null;
@@ -190,15 +190,15 @@ return !!value;
`,
},
{
title: _t('datagrid.macros.currentDate', { defaultMessage: 'Current date' }),
title: __t('datagrid.macros.currentDate', { defaultMessage: 'Current date' }),
name: 'currentDate',
group: 'Tools',
description: _t('datagrid.macros.currentDateDescription', { defaultMessage: 'Gets current date' }),
group: __t('datagrid.macros.toolsGroup', { defaultMessage: 'Tools' }),
description: __t('datagrid.macros.currentDateDescription', { defaultMessage: 'Gets current date' }),
type: 'transformValue',
args: [
{
type: 'text',
label: _t('datagrid.macros.format', { defaultMessage: 'Format' }),
label: __t('datagrid.macros.format', { defaultMessage: 'Format' }),
name: 'format',
default: 'YYYY-MM-DD HH:mm:ss',
},
@@ -206,10 +206,10 @@ return !!value;
code: `return modules.moment().format(args.format)`,
},
{
title: _t('datagrid.macros.duplicateColumns', { defaultMessage: 'Duplicate columns' }),
title: __t('datagrid.macros.duplicateColumns', { defaultMessage: 'Duplicate columns' }),
name: 'duplicateColumns',
group: 'Tools',
description: _t('datagrid.macros.duplicateColumnsDescription', { defaultMessage: 'Duplicate selected columns' }),
group: __t('datagrid.macros.toolsGroup', { defaultMessage: 'Tools' }),
description: __t('datagrid.macros.duplicateColumnsDescription', { defaultMessage: 'Duplicate selected columns' }),
type: 'transformRow',
code: `
return {
@@ -220,22 +220,22 @@ return !!value;
args: [
{
type: 'text',
label: _t('datagrid.macros.prefix', { defaultMessage: 'Prefix' }),
label: __t('datagrid.macros.prefix', { defaultMessage: 'Prefix' }),
name: 'prefix',
},
{
type: 'text',
label: _t('datagrid.macros.postfix', { defaultMessage: 'Postfix' }),
label: __t('datagrid.macros.postfix', { defaultMessage: 'Postfix' }),
name: 'postfix',
default: '_copy',
},
],
},
{
title: _t('datagrid.macros.splitColumns', { defaultMessage: 'Split columns' }),
title: __t('datagrid.macros.splitColumns', { defaultMessage: 'Split columns' }),
name: 'splitColumns',
group: 'Tools',
description: _t('datagrid.macros.splitColumnsDescription', { defaultMessage: 'Split selected columns' }),
group: __t('datagrid.macros.toolsGroup', { defaultMessage: 'Tools' }),
description: __t('datagrid.macros.splitColumnsDescription', { defaultMessage: 'Split selected columns' }),
type: 'transformRow',
code: `
const res = {...row};
@@ -254,22 +254,22 @@ return !!value;
args: [
{
type: 'text',
label: _t('datagrid.macros.delimiter', { defaultMessage: 'Delimiter' }),
label: __t('datagrid.macros.delimiter', { defaultMessage: 'Delimiter' }),
name: 'delimiter',
default: ',',
},
],
},
{
title: _t('datagrid.macros.calculation', { defaultMessage: 'Calculation' }),
title: __t('datagrid.macros.calculation', { defaultMessage: 'Calculation' }),
name: 'calculation',
group: 'Tools',
description: _t('datagrid.macros.calculationDescription', { defaultMessage: 'Custom expression. Use row.column_name for accessing column values, value for original value' }),
group: __t('datagrid.macros.toolsGroup', { defaultMessage: 'Tools' }),
description: __t('datagrid.macros.calculationDescription', { defaultMessage: 'Custom expression. Use row.column_name for accessing column values, value for original value' }),
type: 'transformValue',
args: [
{
type: 'text',
label: _t('datagrid.macros.expression', { defaultMessage: 'Expression' }),
label: __t('datagrid.macros.expression', { defaultMessage: 'Expression' }),
name: 'expression',
default: 'value',
},
@@ -277,10 +277,10 @@ return !!value;
code: `return eval(args.expression);`,
},
{
title: _t('datagrid.macros.extractDateFields', { defaultMessage: 'Extract date fields' }),
title: __t('datagrid.macros.extractDateFields', { defaultMessage: 'Extract date fields' }),
name: 'extractDateFields',
group: 'Tools',
description: _t('datagrid.macros.extractDateFieldsDescription', { defaultMessage: 'Extract year, month, day and other date/time fields from selection and adds it as new columns' }),
group: __t('datagrid.macros.toolsGroup', { defaultMessage: 'Tools' }),
description: __t('datagrid.macros.extractDateFieldsDescription', { defaultMessage: 'Extract year, month, day and other date/time fields from selection and adds it as new columns' }),
type: 'transformRow',
code: `
let mom = null;
@@ -313,37 +313,37 @@ return !!value;
args: [
{
type: 'text',
label: _t('datagrid.macros.yearName', { defaultMessage: 'Year name' }),
label: __t('datagrid.macros.yearName', { defaultMessage: 'Year name' }),
name: 'year',
default: 'year',
},
{
type: 'text',
label: _t('datagrid.macros.monthName', { defaultMessage: 'Month name' }) ,
label: __t('datagrid.macros.monthName', { defaultMessage: 'Month name' }) ,
name: 'month',
default: 'month',
},
{
type: 'text',
label: _t('datagrid.macros.dayName', { defaultMessage: 'Day name' }),
label: __t('datagrid.macros.dayName', { defaultMessage: 'Day name' }),
name: 'day',
default: 'day',
},
{
type: 'text',
label: _t('datagrid.macros.hourName', { defaultMessage: 'Hour name' }),
label: __t('datagrid.macros.hourName', { defaultMessage: 'Hour name' }),
name: 'hour',
default: 'hour',
},
{
type: 'text',
label: _t('datagrid.macros.minuteName', { defaultMessage: 'Minute name' }),
label: __t('datagrid.macros.minuteName', { defaultMessage: 'Minute name' }),
name: 'minute',
default: 'minute',
},
{
type: 'text',
label: _t('datagrid.macros.secondName', { defaultMessage: 'Second name' }),
label: __t('datagrid.macros.secondName', { defaultMessage: 'Second name' }),
name: 'second',
default: 'second',
},

View File

@@ -1,12 +1,35 @@
<script lang="ts" context="module">
const getCurrentEditor = () => getActiveComponent('TableDataTab');
const INTERVALS = [5, 10, 15, 13, 60];
const INTERVALS = [5, 10, 15, 30, 60];
const INTERVAL_COMMANDS = [
{
time: 5,
name: __t('command.datagrid.setAutoRefresh.5', { defaultMessage: 'Refresh every 5 seconds' }),
},
{
time: 10,
name: __t('command.datagrid.setAutoRefresh.10', { defaultMessage: 'Refresh every 10 seconds' }),
},
{
time: 15,
name: __t('command.datagrid.setAutoRefresh.15', { defaultMessage: 'Refresh every 15 seconds' }),
},
{
time: 30,
name: __t('command.datagrid.setAutoRefresh.30', { defaultMessage: 'Refresh every 30 seconds' }),
},
{
time: 60,
name: __t('command.datagrid.setAutoRefresh.60', { defaultMessage: 'Refresh every 60 seconds' }),
},
]
registerCommand({
id: 'tableData.save',
group: 'save',
category: 'Table data',
name: 'Save',
category: __t('command.tableData', { defaultMessage: 'Table data' }),
name: __t('command.tableData.save', { defaultMessage: 'Save' }),
// keyText: 'CtrlOrCommand+S',
toolbar: true,
isRelatedToTab: true,
@@ -17,28 +40,28 @@
registerCommand({
id: 'tableData.setAutoRefresh.1',
category: 'Data grid',
name: 'Refresh every 1 second',
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.setAutoRefresh.1', { defaultMessage: 'Refresh every 1 second' }),
isRelatedToTab: true,
testEnabled: () => !!getCurrentEditor(),
onClick: () => getCurrentEditor().setAutoRefresh(1),
});
for (const seconds of INTERVALS) {
for (const { time, name } of INTERVAL_COMMANDS) {
registerCommand({
id: `tableData.setAutoRefresh.${seconds}`,
category: 'Data grid',
name: `Refresh every ${seconds} seconds`,
id: `tableData.setAutoRefresh.${time}`,
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name,
isRelatedToTab: true,
testEnabled: () => !!getCurrentEditor(),
onClick: () => getCurrentEditor().setAutoRefresh(seconds),
onClick: () => getCurrentEditor().setAutoRefresh(time),
});
}
registerCommand({
id: 'tableData.stopAutoRefresh',
category: 'Data grid',
name: 'Stop auto refresh',
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.stopAutoRefresh', { defaultMessage: 'Stop auto refresh' }),
isRelatedToTab: true,
keyText: 'CtrlOrCommand+Shift+R',
testEnabled: () => getCurrentEditor()?.isAutoRefresh() === true,
@@ -47,8 +70,8 @@
registerCommand({
id: 'tableData.startAutoRefresh',
category: 'Data grid',
name: 'Start auto refresh',
category: __t('command.datagrid', { defaultMessage: 'Data grid' }),
name: __t('command.datagrid.startAutoRefresh', { defaultMessage: 'Start auto refresh' }),
isRelatedToTab: true,
keyText: 'CtrlOrCommand+Shift+R',
testEnabled: () => getCurrentEditor()?.isAutoRefresh() === false,
@@ -101,6 +124,7 @@
import { markTabSaved, markTabUnsaved } from '../utility/common';
import ToolStripButton from '../buttons/ToolStripButton.svelte';
import { getNumberIcon } from '../icons/FontIcon.svelte';
import { __t, _t } from '../translations';
export let tabid;
export let conid;
@@ -260,7 +284,7 @@
{ command: 'tableData.stopAutoRefresh', hideDisabled: true },
{ command: 'tableData.startAutoRefresh', hideDisabled: true },
'tableData.setAutoRefresh.1',
...INTERVALS.map(seconds => ({ command: `tableData.setAutoRefresh.${seconds}`, text: `...${seconds} seconds` })),
...INTERVALS.map(seconds => ({ command: `tableData.setAutoRefresh.${seconds}`, text: `...${seconds}` + ' ' + _t('command.datagrid.autoRefresh.seconds', { defaultMessage: 'seconds' }) })),
];
}
</script>
@@ -304,7 +328,7 @@
defaultActionId: 'openStructure',
},
});
}}>Structure</ToolStripButton
}}>{_t('datagrid.structure', { defaultMessage: 'Structure' })}</ToolStripButton
>
<ToolStripButton
@@ -378,7 +402,7 @@
<ToolStripButton
icon={$collapsedLeftColumnStore ? 'icon columns-outline' : 'icon columns'}
on:click={() => collapsedLeftColumnStore.update(x => !x)}>View columns</ToolStripButton
on:click={() => collapsedLeftColumnStore.update(x => !x)}>{_t('tableData.viewColumns', { defaultMessage: 'View columns' })}</ToolStripButton
>
</svelte:fragment>
</ToolStripContainer>

View File

@@ -2,6 +2,7 @@ import _ from 'lodash';
import { arrayToHexString, stringifyCellValue } from 'dbgate-tools';
import yaml from 'js-yaml';
import { DataEditorTypesBehaviour } from 'dbgate-types';
import { __t, _t } from '../translations'
export function copyTextToClipboard(text) {
const oldFocus = document.activeElement;
@@ -157,53 +158,53 @@ export function copyRowsToClipboard(format, columns, rows, options) {
export const copyRowsFormatDefs = {
textWithHeaders: {
label: 'Copy with headers',
name: 'With headers',
label: __t('clipboard.copyWithHeaders', { defaultMessage : 'Copy with headers' }),
name: __t('clipboard.withHeaders', { defaultMessage: 'With headers' }),
formatter: clipboardTextFormatter('\t', true),
},
textWithoutHeaders: {
label: 'Copy without headers',
name: 'Without headers',
label: __t('clipboard.copyWithoutHeaders', { defaultMessage : 'Copy without headers' }),
name: __t('clipboard.withoutHeaders', { defaultMessage: 'Without headers' }),
formatter: clipboardTextFormatter('\t', false),
},
headers: {
label: 'Copy only headers',
name: 'Only Headers',
label: __t('clipboard.copyOnlyHeadres', { defaultMessage : 'Copy only headers'}),
name: __t('clipboard.onlyHeaders', { defaultMessage : 'Only Headers' }),
formatter: clipboardHeadersFormatter('\t'),
},
csv: {
label: 'Copy as CSV',
label: __t('clipboard.copyCSV', { defaultMessage : 'Copy as CSV'}),
name: 'CSV',
formatter: clipboardTextFormatter(',', true),
},
json: {
label: 'Copy as JSON',
label: __t('clipboard.copyJSON', { defaultMessage: 'Copy as JSON'}),
name: 'JSON',
formatter: clipboardJsonFormatter(),
},
jsonLines: {
label: 'Copy as JSON lines/NDJSON',
label: __t('clipboard.copyJSONLines', { defaultMessage : 'Copy as JSON lines/NDJSON' }),
name: 'JSON lines/NDJSON',
formatter: clipboardJsonLinesFormatter(),
},
yaml: {
label: 'Copy as YAML',
label: __t('clipboard.copyYAML', { defaultMessage : 'Copy as YAML'}),
name: 'YAML',
formatter: clipboardYamlFormatter(),
},
inserts: {
label: 'Copy as SQL INSERTs',
name: 'SQL INSERTs',
label: __t('clipboard.copySQLInsert', { defaultMessage : 'Copy as SQL INSERTs'}),
name: __t('clipboard.SQLInsert', { defaultMessage : 'SQL INSERTs' }),
formatter: clipboardInsertsFormatter(),
},
updates: {
label: 'Copy as SQL UPDATEs',
name: 'SQL UPDATEs',
label: __t('clipboard.copySQLUpdate', { defaultMessage : 'Copy as SQL UPDATEs'}),
name: __t('clipboard.SQLUpdate', { defaultMessage : 'SQL UPDATEs' }),
formatter: clipboardUpdatesFormatter(),
},
mongoInsert: {
label: 'Copy as Mongo INSERTs',
name: 'Mongo INSERTs',
label: __t('clipboard.copyMongoInsert', { defaultMessage : 'Copy as Mongo INSERTs' }),
name: __t('clipboard.mongoInsert', { defaultMessage : 'Mongo INSERTs' }),
formatter: clipboardMongoInsertFormatter(),
},
};

View File

@@ -1,12 +1,13 @@
import type { QuickExportDefinition } from 'dbgate-types';
import { currentArchive, getCurrentArchive, getExtensions } from '../stores';
import hasPermission from './hasPermission';
import { _t } from '../translations'
export function createQuickExportMenuItems(handler: (fmt: QuickExportDefinition) => Function, advancedExportMenuItem) {
const extensions = getExtensions();
return [
{
text: 'Export advanced...',
text: _t('export.exportAdvanced', { defaultMessage : 'Export advanced...'}),
...advancedExportMenuItem,
},
{ divider: true },
@@ -16,10 +17,10 @@ export function createQuickExportMenuItems(handler: (fmt: QuickExportDefinition)
})),
{ divider: true },
{
text: 'Current archive',
text: _t('export.currentArchive', { defaultMessage : 'Current archive'}),
onClick: handler({
extension: 'jsonl',
label: 'Current archive',
label: _t('export.currentArchive', { defaultMessage : 'Current archive'}),
noFilenameDependency: true,
createWriter: (fileName, dataName) => ({
functionName: 'archiveWriter',

View File

@@ -233,7 +233,7 @@
{/if}
<InlineButton
on:click={handleRefreshDatabase}
title="Refresh database connection and object list"
title={_t('sqlObjectList.refreshDatabase', { defaultMessage: "Refresh database connection and object list" })}
square
data-testid="SqlObjectList_refreshButton"
>

View File

@@ -3,6 +3,22 @@
"app.preparingPlugins": "Příprava pluginů...",
"app.starting": "Spouštění DbGate",
"authToken": "Auth token",
"clipboard.SQLInsert": "SQL INSERT příkazy",
"clipboard.SQLUpdate": "SQL UPDATE příkazy",
"clipboard.copyCSV": "Kopírovat jako CSV",
"clipboard.copyJSON": "Kopírovat jako JSON",
"clipboard.copyJSONLines": "Kopírovat jako JSON lines/NDJSON",
"clipboard.copyMongoInsert": "Kopírovat jako Mongo INSERT příkazy",
"clipboard.copyOnlyHeadres": "Kopírovat pouze hlavičky",
"clipboard.copySQLInsert": "Kopírovat jako SQL INSERT příkazy",
"clipboard.copySQLUpdate": "Kopírovat jako SQL UPDATE příkazy",
"clipboard.copyWithHeaders": "Kopírovat s hlavičkami",
"clipboard.copyWithoutHeaders": "Kopírovat bez hlaviček",
"clipboard.copyYAML": "Kopírovat jako YAML",
"clipboard.mongoInsert": "Kopírovat jako Mongo INSERT příkazy",
"clipboard.onlyHeaders": "Pouze hlavičky",
"clipboard.withHeaders": "S hlavičkami",
"clipboard.withoutHeaders": "Bez hlaviček",
"column.addNew": "Přidat nový sloupec",
"column.copyName": "Kopírovat název",
"column.dropColumn": "Odstranit sloupec",
@@ -11,14 +27,23 @@
"column.renameColumn": "Přejmenovat sloupec",
"column.search": "Hledat sloupce",
"column.variable": "Proměnné sloupce (jako MongoDB)",
"command.datagrid": "Datová mřížka",
"command.datagrid.addJsonDocument": "Přidat JSON dokument",
"command.datagrid.addNewColumn": "Přidat nový sloupec",
"command.datagrid.addNewColumn.toolbar": "Nový sloupec",
"command.datagrid.autoRefresh.seconds": "sekund",
"command.datagrid.clearFilter": "Vymazat filtr",
"command.datagrid.cloneRows": "Klonovat řádky",
"command.datagrid.cloneRows.toolbar": "Klonovat řádek(y)",
"command.datagrid.copyToClipboard": "Kopírovat do schránky",
"command.datagrid.deleteSelectedRows": "Odstranit vybrané řádky",
"command.datagrid.deleteSelectedRows.toolbar": "Odstranit řádek(y)",
"command.datagrid.editCell": "Upravit hodnotu buňky",
"command.datagrid.editJsonDocument": "Upravit řádek jako JSON dokument",
"command.datagrid.editSelection": "Upravit výběr jako tabulku",
"command.datagrid.filterSelected": "Filtrovat vybranou hodnotu",
"command.datagrid.findColumn": "Najít sloupec",
"command.datagrid.generateSql": "Generovat SQL",
"command.datagrid.insertNewRow": "Vložit nový řádek",
"command.datagrid.insertNewRow.toolbar": "Nový řádek",
"command.datagrid.loadCellFromFile": "Načíst buňku ze souboru",
@@ -31,12 +56,29 @@
"command.datagrid.revertAllChanges.toolbar": "Vrátit vše",
"command.datagrid.revertRowChanges": "Vrátit změny řádku",
"command.datagrid.saveCellToFile": "Uložit buňku do souboru",
"command.datagrid.sendToDataDeployer": "Odeslat do data deployer",
"command.datagrid.setAutoRefresh.1": "Obnovit každou sekundu",
"command.datagrid.setAutoRefresh.10": "Obnovit každých 10 sekund",
"command.datagrid.setAutoRefresh.15": "Obnovit každých 15 sekund",
"command.datagrid.setAutoRefresh.30": "Obnovit každých 30 sekund",
"command.datagrid.setAutoRefresh.5": "Obnovit každých 5 sekund",
"command.datagrid.setAutoRefresh.60": "Obnovit každých 60 sekund",
"command.datagrid.setNull": "Nastavit NULL",
"command.datagrid.startAutoRefresh": "Spustit automatické obnovování",
"command.datagrid.stopAutoRefresh": "Zastavit automatické obnovování",
"command.datagrid.switchToJSON": "Přepnout na JSON",
"command.datagrid.switchToform": "Přepnout na formulář",
"command.datagrid.toggleLeftPanel": "Přepnout levý panel",
"command.datagrid.undo": "Krok zpět",
"command.datagrid.viewJsonDocument": "Zobrazit řádek jako JSON dokument",
"command.datagrid.viewJsonValue": "Zobrazit buňku jako JSON dokument",
"command.datagrid.witchToTable": "Přepnout na tabulku",
"command.datgrid.hideColumn": "Skrýt sloupec",
"command.new.duckdbDatabase": "Nová DuckDB databáze",
"command.new.sqliteDatabase": "Nová SQLite databáze",
"command.openQuery": "Otevřít dotaz",
"command.tableData": "Data tabulky",
"command.tableData.save": "Uložit",
"command.tabs.addToFavorites": "Přidat aktuální kartu do oblíbených",
"command.tabs.closeAll": "Zavřít všechny karty",
"command.tabs.closeTab": "Zavřít kartu",
@@ -55,6 +97,7 @@
"common.createNew": "Vytvořit",
"common.database": "Databáze",
"common.databaseChat": "Databázový chat",
"common.datagrid.deepRefresh": "Obnovit se strukturou",
"common.description": "Popis",
"common.erDiagram": "ER Diagram",
"common.execute": "Spustit",
@@ -184,8 +227,9 @@
"database.shellTitle": "Shell #",
"database.showDiagram": "Zobrazit diagram",
"database.sqlGenerator": "SQL generátor",
"datagrid.copyAdvanced": "Pokročilé kopírování",
"datagrid.macros.calculation": "Výpočet",
"datagrid.macros.calculationDescription": "Vlastní výraz. Použijte row.nazev_sloupce pro přístup k hodnotám sloupců, value pro původní hodnotu",
"datagrid.macros.calculationDescription": "Vlastní výraz. Použijte řádek.název_sloupce pro přístup k hodnotám sloupců, value pro původní hodnotu",
"datagrid.macros.changeTextCase": "Změnit velikost písmen",
"datagrid.macros.changeTextCaseDescription": "Funkce pro velká písmena, malá písmena a další úpravy",
"datagrid.macros.changeTextCaseType": "Typ",
@@ -227,6 +271,7 @@
"datagrid.macros.secondName": "Název sekundy",
"datagrid.macros.splitColumns": "Rozdělit sloupce",
"datagrid.macros.splitColumnsDescription": "Rozdělit vybrané sloupce",
"datagrid.macros.textGroup": "Textové",
"datagrid.macros.toBoolean": "Převést na boolean",
"datagrid.macros.toBooleanDescription": "Převede na boolean",
"datagrid.macros.toInt": "Převést na celé číslo",
@@ -235,16 +280,19 @@
"datagrid.macros.toNumberDescription": "Převede na číslo",
"datagrid.macros.toString": "Převést na text",
"datagrid.macros.toStringDescription": "Převede na text",
"datagrid.macros.toolsGroup": "Nástroje",
"datagrid.macros.trim": "Oříznout",
"datagrid.macros.trimDescription": "Odstraní mezery na začátku a konci",
"datagrid.macros.uuidv1": "V1 - z časového razítka",
"datagrid.macros.uuidv4": "V4 - náhodně generované",
"datagrid.macros.version": "Verze",
"datagrid.macros.yearName": "Název roku",
"datagrid.searchMacros": "Hledat makra",
"datagrid.setFormat": "Nastavit formát: ",
"datagrid.structure": "Struktura",
"error.driverNotFound": "Neplatné připojení k databázi, ovladač nebyl nalezen",
"error.selectedCloudConnection": "Vybrané připojení je z DbGate cloudu",
"error.selectedNotCloudConnection": "Vybrané připojení není z DbGate cloudu",
"export.currentArchive": "Aktuální archiv",
"export.exportAdvanced": "Pokročilý export...",
"file.allSupported": "Všechny podporované soubory",
"file.diagramFiles": "Soubory diagramů",
"file.duckdb": "Databáze DuckDB",
@@ -460,6 +508,7 @@
"sqlObject.tableViewProcedureName": "Název tabulky/pohledu/procedury",
"sqlObject.tablesWithRows": "Pouze tabulky s řádky",
"sqlObject.viewProcedureTriggerText": "Text pohledu/procedury/triggeru",
"sqlObjectList.refreshDatabase": "Obnovit připojení k databázi a seznam objektů",
"summaryProcesses.actions": "Akce",
"summaryProcesses.client": "Klient",
"summaryProcesses.connectionId": "ID připojení",
@@ -472,6 +521,7 @@
"summaryVariables.value": "Hodnota",
"summaryVariables.variable": "Proměnná",
"tab.administration": "Administrace",
"tableData.viewColumns": "Zobrazit sloupce",
"widget.databaseContent": "Obsah databáze",
"widget.databases": "Databáze",
"widget.keys": "Klíče",

View File

@@ -3,6 +3,22 @@
"app.preparingPlugins": "Preparing plugins ...",
"app.starting": "Starting DbGate",
"authToken": "Auth token",
"clipboard.SQLInsert": "SQL INSERTs",
"clipboard.SQLUpdate": "SQL UPDATEs",
"clipboard.copyCSV": "Copy as CSV",
"clipboard.copyJSON": "Copy as JSON",
"clipboard.copyJSONLines": "Copy as JSON lines/NDJSON",
"clipboard.copyMongoInsert": "Copy as Mongo INSERTs",
"clipboard.copyOnlyHeadres": "Copy only headers",
"clipboard.copySQLInsert": "Copy as SQL INSERTs",
"clipboard.copySQLUpdate": "Copy as SQL UPDATEs",
"clipboard.copyWithHeaders": "Copy with headers",
"clipboard.copyWithoutHeaders": "Copy without headers",
"clipboard.copyYAML": "Copy as YAML",
"clipboard.mongoInsert": "Mongo INSERTs",
"clipboard.onlyHeaders": "Only Headers",
"clipboard.withHeaders": "With headers",
"clipboard.withoutHeaders": "Without headers",
"column.addNew": "Add new column",
"column.copyName": "Copy name",
"column.dropColumn": "Drop column",
@@ -11,14 +27,23 @@
"column.renameColumn": "Rename column",
"column.search": "Search columns",
"column.variable": "Variable columns (like MongoDB)",
"command.datagrid": "Data grid",
"command.datagrid.addJsonDocument": "Add JSON document",
"command.datagrid.addNewColumn": "Add new column",
"command.datagrid.addNewColumn.toolbar": "New column",
"command.datagrid.autoRefresh.seconds": "seconds",
"command.datagrid.clearFilter": "Clear filter",
"command.datagrid.cloneRows": "Clone rows",
"command.datagrid.cloneRows.toolbar": "Clone row(s)",
"command.datagrid.copyToClipboard": "Copy to clipboard",
"command.datagrid.deleteSelectedRows": "Delete selected rows",
"command.datagrid.deleteSelectedRows.toolbar": "Delete row(s)",
"command.datagrid.editCell": "Edit cell value",
"command.datagrid.editJsonDocument": "Edit row as JSON document",
"command.datagrid.editSelection": "Edit selection as table",
"command.datagrid.filterSelected": "Filter selected value",
"command.datagrid.findColumn": "Find column",
"command.datagrid.generateSql": "Generate SQL",
"command.datagrid.insertNewRow": "Insert new row",
"command.datagrid.insertNewRow.toolbar": "New row",
"command.datagrid.loadCellFromFile": "Load cell from file",
@@ -31,12 +56,29 @@
"command.datagrid.revertAllChanges.toolbar": "Revert all",
"command.datagrid.revertRowChanges": "Revert row changes",
"command.datagrid.saveCellToFile": "Save cell to file",
"command.datagrid.sendToDataDeployer": "Send to data deployer",
"command.datagrid.setAutoRefresh.1": "Refresh every 1 second",
"command.datagrid.setAutoRefresh.10": "Refresh every 10 seconds",
"command.datagrid.setAutoRefresh.15": "Refresh every 15 seconds",
"command.datagrid.setAutoRefresh.30": "Refresh every 30 seconds",
"command.datagrid.setAutoRefresh.5": "Refresh every 5 seconds",
"command.datagrid.setAutoRefresh.60": "Refresh every 60 seconds",
"command.datagrid.setNull": "Set NULL",
"command.datagrid.startAutoRefresh": "Start auto refresh",
"command.datagrid.stopAutoRefresh": "Stop auto refresh",
"command.datagrid.switchToJSON": "Switch to JSON",
"command.datagrid.switchToform": "Switch to form",
"command.datagrid.toggleLeftPanel": "Toggle left panel",
"command.datagrid.undo": "Undo",
"command.datagrid.viewJsonDocument": "View row as JSON document",
"command.datagrid.viewJsonValue": "View cell as JSON document",
"command.datagrid.witchToTable": "Switch to table",
"command.datgrid.hideColumn": "Hide column",
"command.new.duckdbDatabase": "New DuckDB database",
"command.new.sqliteDatabase": "New SQLite database",
"command.openQuery": "Open query",
"command.tableData": "Table data",
"command.tableData.save": "Save",
"command.tabs.addToFavorites": "Add current tab to favorites",
"command.tabs.closeAll": "Close all tabs",
"command.tabs.closeTab": "Close tab",
@@ -55,6 +97,7 @@
"common.createNew": "Create new",
"common.database": "Database",
"common.databaseChat": "Database Chat",
"common.datagrid.deepRefresh": "Refresh with structure",
"common.description": "Description",
"common.erDiagram": "ER Diagram",
"common.execute": "Execute",
@@ -184,6 +227,7 @@
"database.shellTitle": "Shell #",
"database.showDiagram": "Show diagram",
"database.sqlGenerator": "SQL Generator",
"datagrid.copyAdvanced": "Copy advanced",
"datagrid.macros.calculation": "Calculation",
"datagrid.macros.calculationDescription": "Custom expression. Use row.column_name for accessing column values, value for original value",
"datagrid.macros.changeTextCase": "Change text case",
@@ -227,6 +271,7 @@
"datagrid.macros.secondName": "Second name",
"datagrid.macros.splitColumns": "Split columns",
"datagrid.macros.splitColumnsDescription": "Split selected columns",
"datagrid.macros.textGroup": "Text",
"datagrid.macros.toBoolean": "Convert to boolean",
"datagrid.macros.toBooleanDescription": "Converts to boolean",
"datagrid.macros.toInt": "Convert to integer",
@@ -235,16 +280,19 @@
"datagrid.macros.toNumberDescription": "Converts to number",
"datagrid.macros.toString": "Convert to string",
"datagrid.macros.toStringDescription": "Converts to string",
"datagrid.macros.toolsGroup": "Tools",
"datagrid.macros.trim": "Trim",
"datagrid.macros.trimDescription": "Removes leading and trailing whitespace",
"datagrid.macros.uuidv1": "V1 - from timestamp",
"datagrid.macros.uuidv4": "V4 - random generated",
"datagrid.macros.version": "Version",
"datagrid.macros.yearName": "Year name",
"datagrid.searchMacros": "Search macros",
"datagrid.setFormat": "Set format: ",
"datagrid.structure": "Structure",
"error.driverNotFound": "Invalid database connection, driver not found",
"error.selectedCloudConnection": "Selected connection is from DbGate cloud",
"error.selectedNotCloudConnection": "Selected connection is not from DbGate cloud",
"export.currentArchive": "Current archive",
"export.exportAdvanced": "Export advanced...",
"file.allSupported": "All supported files",
"file.diagramFiles": "Diagram files",
"file.duckdb": "DuckDB database",
@@ -460,6 +508,7 @@
"sqlObject.tableViewProcedureName": "Table/view/procedure name",
"sqlObject.tablesWithRows": "Only tables with rows",
"sqlObject.viewProcedureTriggerText": "View/procedure/trigger text",
"sqlObjectList.refreshDatabase": "Refresh database connection and object list",
"summaryProcesses.actions": "Actions",
"summaryProcesses.client": "Client",
"summaryProcesses.connectionId": "Connection ID",
@@ -472,6 +521,7 @@
"summaryVariables.value": "Value",
"summaryVariables.variable": "Variable",
"tab.administration": "Administration",
"tableData.viewColumns": "View columns",
"widget.databaseContent": "Database content",
"widget.databases": "Databases",
"widget.keys": "Keys",

View File

@@ -3,6 +3,22 @@
"app.preparingPlugins": "Príprava pluginov...",
"app.starting": "Spúšťam DbGate",
"authToken": "Autentifikačný token",
"clipboard.SQLInsert": "SQL INSERT príkazy",
"clipboard.SQLUpdate": "SQL UPDATE príkazy",
"clipboard.copyCSV": "Kopírovať ako CSV",
"clipboard.copyJSON": "Kopírovať ako JSON",
"clipboard.copyJSONLines": "Kopírovať ako JSON riadky/NDJSON",
"clipboard.copyMongoInsert": "Kopírovať ako Mongo INSERT príkazy",
"clipboard.copyOnlyHeadres": "Kopírovať iba hlavičky",
"clipboard.copySQLInsert": "Kopírovať ako SQL INSERT príkazy",
"clipboard.copySQLUpdate": "Kopírovať ako SQL UPDATE príkazy",
"clipboard.copyWithHeaders": "Kopírovať s hlavičkami",
"clipboard.copyWithoutHeaders": "Kopírovať bez hlavičiek",
"clipboard.copyYAML": "Kopírovať ako YAML",
"clipboard.mongoInsert": "Mongo INSERT príkazy",
"clipboard.onlyHeaders": "Iba hlavičky",
"clipboard.withHeaders": "S hlavičkami",
"clipboard.withoutHeaders": "Bez hlavičiek",
"column.addNew": "Pridať nový stĺpec",
"column.copyName": "Kopírovať názov",
"column.dropColumn": "Odstrániť stĺpec",
@@ -11,14 +27,23 @@
"column.renameColumn": "Premenovať stĺpec",
"column.search": "Hľadať stĺpce",
"column.variable": "Premenlivé stĺpce (ako MongoDB)",
"command.datagrid": "Dátová mriežka",
"command.datagrid.addJsonDocument": "Pridať JSON dokument",
"command.datagrid.addNewColumn": "Pridať nový stĺpec",
"command.datagrid.addNewColumn.toolbar": "Nový stĺpec",
"command.datagrid.autoRefresh.seconds": "sekúnd",
"command.datagrid.clearFilter": "Vymazať filter",
"command.datagrid.cloneRows": "Klonovať riadky",
"command.datagrid.cloneRows.toolbar": "Klonovať riadok(y)",
"command.datagrid.copyToClipboard": "Kopírovať do schránky",
"command.datagrid.deleteSelectedRows": "Odstrániť vybrané riadky",
"command.datagrid.deleteSelectedRows.toolbar": "Odstrániť riadok(y)",
"command.datagrid.editCell": "Upraviť hodnotu bunky",
"command.datagrid.editJsonDocument": "Upraviť riadok ako JSON dokument",
"command.datagrid.editSelection": "Upraviť výber ako tabuľku",
"command.datagrid.filterSelected": "Filtrovať vybranú hodnotu",
"command.datagrid.findColumn": "Nájsť stĺpec",
"command.datagrid.generateSql": "Generovať SQL",
"command.datagrid.insertNewRow": "Vložiť nový riadok",
"command.datagrid.insertNewRow.toolbar": "Nový riadok",
"command.datagrid.loadCellFromFile": "Načítať bunku zo súboru",
@@ -31,12 +56,29 @@
"command.datagrid.revertAllChanges.toolbar": "Vrátiť všetko",
"command.datagrid.revertRowChanges": "Vrátiť zmeny riadka",
"command.datagrid.saveCellToFile": "Uložiť bunku do súboru",
"command.datagrid.sendToDataDeployer": "Odoslať do data deployer",
"command.datagrid.setAutoRefresh.1": "Obnoviť každú sekundu",
"command.datagrid.setAutoRefresh.10": "Obnoviť každých 10 sekúnd",
"command.datagrid.setAutoRefresh.15": "Obnoviť každých 15 sekúnd",
"command.datagrid.setAutoRefresh.30": "Obnoviť každých 30 sekúnd",
"command.datagrid.setAutoRefresh.5": "Obnoviť každých 5 sekúnd",
"command.datagrid.setAutoRefresh.60": "Obnoviť každých 60 sekúnd",
"command.datagrid.setNull": "Nastaviť NULL",
"command.datagrid.startAutoRefresh": "Spustiť automatické obnovovanie",
"command.datagrid.stopAutoRefresh": "Zastaviť automatické obnovovanie",
"command.datagrid.switchToJSON": "Prepnúť na JSON",
"command.datagrid.switchToform": "Prepnúť na formulár",
"command.datagrid.toggleLeftPanel": "Prepnúť ľavý panel",
"command.datagrid.undo": "Krok späť",
"command.datagrid.viewJsonDocument": "Zobraziť riadok ako JSON dokument",
"command.datagrid.viewJsonValue": "Zobraziť bunku ako JSON dokument",
"command.datagrid.witchToTable": "Prepnúť na tabuľku",
"command.datgrid.hideColumn": "Skryť stĺpec",
"command.new.duckdbDatabase": "Nová DuckDB databáza",
"command.new.sqliteDatabase": "Nová SQLite databáza",
"command.openQuery": "Otvoriť dotaz",
"command.tableData": "Dáta tabuľky",
"command.tableData.save": "Uložiť",
"command.tabs.addToFavorites": "Pridať aktuálnu kartu do obľúbených",
"command.tabs.closeAll": "Zavrieť všetky karty",
"command.tabs.closeTab": "Zavrieť kartu",
@@ -55,6 +97,7 @@
"common.createNew": "Vytvoriť",
"common.database": "Databáza",
"common.databaseChat": "Chat s databázou",
"common.datagrid.deepRefresh": "Obnoviť so štruktúrou",
"common.description": "Popis",
"common.erDiagram": "ER Diagram",
"common.execute": "Spustiť",
@@ -184,8 +227,9 @@
"database.shellTitle": "Shell #",
"database.showDiagram": "Zobraziť",
"database.sqlGenerator": "SQL generátor",
"datagrid.copyAdvanced": "Pokročilé kopírovanie",
"datagrid.macros.calculation": "Výpočet",
"datagrid.macros.calculationDescription": "Vlastný výraz. Použite row.column_name pre prístup k hodnotám stĺpcov, value pre pôvodnú hodnotu",
"datagrid.macros.calculationDescription": "Vlastný výraz. Použite riadok.názov_stĺpca pre prístup k hodnotám stĺpcov, value pre pôvodnú hodnotu",
"datagrid.macros.changeTextCase": "Zmeniť veľkosť písmen",
"datagrid.macros.changeTextCaseDescription": "Funkcie pre veľké, malé a iné formáty písmen",
"datagrid.macros.changeTextCaseType": "Typ",
@@ -227,6 +271,7 @@
"datagrid.macros.secondName": "Názov sekundy",
"datagrid.macros.splitColumns": "Rozdeliť stĺpce",
"datagrid.macros.splitColumnsDescription": "Rozdeliť vybrané stĺpce",
"datagrid.macros.textGroup": "Textové",
"datagrid.macros.toBoolean": "Previesť na boolean",
"datagrid.macros.toBooleanDescription": "Prevedie na boolean",
"datagrid.macros.toInt": "Previesť na celé číslo",
@@ -235,16 +280,19 @@
"datagrid.macros.toNumberDescription": "Prevedie na číslo",
"datagrid.macros.toString": "Previesť na reťazec",
"datagrid.macros.toStringDescription": "Prevedie na reťazec",
"datagrid.macros.toolsGroup": "Nástroje",
"datagrid.macros.trim": "Orezať",
"datagrid.macros.trimDescription": "Odstráni medzery na začiatku a konci",
"datagrid.macros.uuidv1": "V1 - z časovej značky",
"datagrid.macros.uuidv4": "V4 - náhodne vygenerované",
"datagrid.macros.version": "Verzia",
"datagrid.macros.yearName": "Názov roka",
"datagrid.searchMacros": "Vyhľadať makrá",
"datagrid.setFormat": "Nastaviť formát: ",
"datagrid.structure": "Štruktúra",
"error.driverNotFound": "Neplatné pripojenie k databáze, ovládač nenájdený",
"error.selectedCloudConnection": "Vybrané pripojenie je z DbGate cloudu",
"error.selectedNotCloudConnection": "Vybrané pripojenie nie je z DbGate cloudu",
"export.currentArchive": "Aktuálny archív",
"export.exportAdvanced": "Pokročilý export...",
"file.allSupported": "Všetky podporované súbory",
"file.diagramFiles": "Súbory diagramov",
"file.duckdb": "Databáza DuckDB",
@@ -460,6 +508,7 @@
"sqlObject.tableViewProcedureName": "Názov tabuľky/pohľadu/procedúry",
"sqlObject.tablesWithRows": "Iba tabuľky s riadkami",
"sqlObject.viewProcedureTriggerText": "Text pohľadu/procedúry/triggera",
"sqlObjectList.refreshDatabase": "Obnoviť databázové pripojenia a zoznam objektov",
"summaryProcesses.actions": "Akcie",
"summaryProcesses.client": "Klient",
"summaryProcesses.connectionId": "ID pripojenia",
@@ -472,6 +521,7 @@
"summaryVariables.value": "Hodnota",
"summaryVariables.variable": "Premenná",
"tab.administration": "Administrácia",
"tableData.viewColumns": "Zobraziť stĺpce",
"widget.databaseContent": "Obsah databázy",
"widget.databases": "Databázy",
"widget.keys": "Kľúče",