mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-04-25 09:45:59 +00:00
SYNC: #1092 - mysql backup arguments
This commit is contained in:
committed by
Diflow
parent
f312237bd5
commit
3d8c732258
@@ -240,6 +240,19 @@ const mysqlDriverBase = {
|
|||||||
if (options.force) {
|
if (options.force) {
|
||||||
args.push('--force');
|
args.push('--force');
|
||||||
}
|
}
|
||||||
|
if (options.lockTables) {
|
||||||
|
args.push('--lock-tables');
|
||||||
|
}
|
||||||
|
if (options.skipLockTables) {
|
||||||
|
args.push('--skip-lock-tables');
|
||||||
|
}
|
||||||
|
if (options.singleTransaction) {
|
||||||
|
args.push('--single-transaction');
|
||||||
|
}
|
||||||
|
if (options.customArgs?.trim()) {
|
||||||
|
const customArgs = options.customArgs.split(/\s+/).filter(arg => arg.trim() != '');
|
||||||
|
args.push(...customArgs);
|
||||||
|
}
|
||||||
args.push(database);
|
args.push(database);
|
||||||
return { command, args };
|
return { command, args };
|
||||||
},
|
},
|
||||||
@@ -312,6 +325,32 @@ const mysqlDriverBase = {
|
|||||||
default: true,
|
default: true,
|
||||||
disabledFn: values => values.noStructure,
|
disabledFn: values => values.noStructure,
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
type: 'checkbox',
|
||||||
|
label: 'Lock tables',
|
||||||
|
name: 'lockTables',
|
||||||
|
default: false,
|
||||||
|
disabledFn: values => values.skipLockTables || values.singleTransaction,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
type: 'checkbox',
|
||||||
|
label: 'Skip lock tables',
|
||||||
|
name: 'skipLockTables',
|
||||||
|
default: false,
|
||||||
|
disabledFn: values => values.lockTables || values.singleTransaction,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
type: 'checkbox',
|
||||||
|
label: 'Single transaction',
|
||||||
|
name: 'singleTransaction',
|
||||||
|
default: false,
|
||||||
|
disabledFn: values => values.lockTables || values.skipLockTables,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
type: 'text',
|
||||||
|
label: 'Custom arguments',
|
||||||
|
name: 'customArgs',
|
||||||
|
},
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
return null;
|
return null;
|
||||||
|
|||||||
Reference in New Issue
Block a user