Compare commits
2 Commits
052792a789
...
397713d4a8
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
397713d4a8 | ||
|
|
1cc4b74b2e |
@ -51,15 +51,18 @@ const BACKUP_LOC_FIELD_DEFS = {
|
||||
KEEP_YEARLY: { title: 'Keep yearly', description: 'One snapshot per year for this many years.' }
|
||||
};
|
||||
|
||||
// Type leads each list: it's the choice that shapes the rest of the form, so
|
||||
// it renders before the friendly Name. ENGINE stays here but is filtered into
|
||||
// the Advanced tab by locFieldGroups.
|
||||
const BACKUP_LOC_FIELDS_BY_TYPE = {
|
||||
local: ['NAME', 'ENGINE', 'TYPE', 'PATH_MODE', 'PATH', 'APPEND_ONLY'],
|
||||
sftp: ['NAME', 'ENGINE', 'TYPE', 'SSH_USER', 'SSH_HOST', 'SSH_PORT', 'SSH_PATH', 'SSH_AUTH', 'SSH_PASS', 'URI', 'APPEND_ONLY'],
|
||||
rest: ['NAME', 'ENGINE', 'TYPE', 'URI', 'APPEND_ONLY'],
|
||||
s3: ['NAME', 'ENGINE', 'TYPE', 'URI', 'S3_ACCESS_KEY', 'S3_SECRET_KEY', 'APPEND_ONLY'],
|
||||
b2: ['NAME', 'ENGINE', 'TYPE', 'URI', 'B2_ACCOUNT_ID', 'B2_ACCOUNT_KEY', 'APPEND_ONLY'],
|
||||
gs: ['NAME', 'ENGINE', 'TYPE', 'URI', 'APPEND_ONLY'],
|
||||
azure: ['NAME', 'ENGINE', 'TYPE', 'URI', 'APPEND_ONLY'],
|
||||
rclone: ['NAME', 'ENGINE', 'TYPE', 'URI', 'APPEND_ONLY']
|
||||
local: ['TYPE', 'NAME', 'ENGINE', 'PATH_MODE', 'PATH', 'APPEND_ONLY'],
|
||||
sftp: ['TYPE', 'NAME', 'ENGINE', 'SSH_USER', 'SSH_HOST', 'SSH_PORT', 'SSH_PATH', 'SSH_AUTH', 'SSH_PASS', 'URI', 'APPEND_ONLY'],
|
||||
rest: ['TYPE', 'NAME', 'ENGINE', 'URI', 'APPEND_ONLY'],
|
||||
s3: ['TYPE', 'NAME', 'ENGINE', 'URI', 'S3_ACCESS_KEY', 'S3_SECRET_KEY', 'APPEND_ONLY'],
|
||||
b2: ['TYPE', 'NAME', 'ENGINE', 'URI', 'B2_ACCOUNT_ID', 'B2_ACCOUNT_KEY', 'APPEND_ONLY'],
|
||||
gs: ['TYPE', 'NAME', 'ENGINE', 'URI', 'APPEND_ONLY'],
|
||||
azure: ['TYPE', 'NAME', 'ENGINE', 'URI', 'APPEND_ONLY'],
|
||||
rclone: ['TYPE', 'NAME', 'ENGINE', 'URI', 'APPEND_ONLY']
|
||||
};
|
||||
|
||||
// Suffixes that live in the editor's "Advanced" tab. configs.json can flag
|
||||
@ -1541,7 +1544,6 @@ class BackupPage {
|
||||
if (!modal || !body) return;
|
||||
body.innerHTML = `
|
||||
<div class="backup-form-grid">
|
||||
${this.formInput('__add_name', 'Friendly name', '', 'text', 'e.g. Office NAS')}
|
||||
${this.formSelect('__add_type', 'Type', 'local', [
|
||||
['local', 'Local / mounted path'],
|
||||
['sftp', 'SFTP'],
|
||||
@ -1552,6 +1554,7 @@ class BackupPage {
|
||||
['azure', 'Azure'],
|
||||
['rclone', 'rclone']
|
||||
])}
|
||||
${this.formInput('__add_name', 'Friendly name', '', 'text', 'e.g. Office NAS')}
|
||||
</div>
|
||||
<p class="backup-card-hint" style="margin-top:12px">The location starts disabled — fill in its connection details on the next screen, then toggle Enabled.</p>
|
||||
`;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user