Remove handling of non-ediable fields in backupsite config dialog
This commit is contained in:
@@ -30,13 +30,6 @@ const copyConcurrency = ref(0);
|
||||
|
||||
const accessKeyId = ref('');
|
||||
const secretAccessKey = ref('');
|
||||
const bucket = ref('');
|
||||
const region = ref('');
|
||||
const prefix = ref('');
|
||||
const mountOptionsHost = ref('');
|
||||
const mountOptionsPort = ref(0);
|
||||
const mountOptionsRemoteDir = ref('');
|
||||
const mountOptionsSeal = ref(false);
|
||||
const mountOptionsUsername = ref('');
|
||||
const mountOptionsPassword = ref('');
|
||||
const mountOptionsUser = ref('');
|
||||
@@ -63,19 +56,11 @@ async function onSubmit() {
|
||||
}
|
||||
|
||||
if (provider.value === 'cifs') {
|
||||
data.mountOptions = {};
|
||||
data.mountOptions.host = mountOptionsHost.value;
|
||||
data.mountOptions.remoteDir = mountOptionsRemoteDir.value;
|
||||
data.mountOptions.seal = mountOptionsSeal.value;
|
||||
data.mountOptions.username = mountOptionsUsername.value;
|
||||
if (mountOptionsPassword.value) data.mountOptions.password = mountOptionsPassword.value;
|
||||
}
|
||||
|
||||
if (provider.value === 'sshfs') {
|
||||
data.mountOptions = {};
|
||||
data.mountOptions.host = mountOptionsHost.value;
|
||||
data.mountOptions.port = mountOptionsPort.value;
|
||||
data.mountOptions.remoteDir = mountOptionsRemoteDir.value;
|
||||
data.mountOptions.user = mountOptionsUser.value;
|
||||
if (mountOptionsPrivateKey.value) data.mountOptions.privateKey = mountOptionsPrivateKey.value;
|
||||
}
|
||||
@@ -143,20 +128,11 @@ defineExpose({
|
||||
if (s3like(provider.value)) {
|
||||
accessKeyId.value = t.config.accessKeyId;
|
||||
secretAccessKey.value = null;
|
||||
bucket.value = t.config.bucket;
|
||||
region.value = t.config.region;
|
||||
prefix.value = t.config.prefix;
|
||||
} else if (provider.value === 'cifs') {
|
||||
mountOptionsUsername.value = t.config.mountOptions.username;
|
||||
mountOptionsHost.value = t.config.mountOptions.host;
|
||||
mountOptionsRemoteDir.value = t.config.mountOptions.remoteDir;
|
||||
mountOptionsSeal.value = t.config.mountOptions.seal;
|
||||
mountOptionsPassword.value = null;
|
||||
} else if (provider.value === 'sshfs') {
|
||||
mountOptionsUser.value = t.config.mountOptions.user;
|
||||
mountOptionsHost.value = t.config.mountOptions.host;
|
||||
mountOptionsPort.value = t.config.mountOptions.port;
|
||||
mountOptionsRemoteDir.value = t.config.mountOptions.remoteDir;
|
||||
mountOptionsPrivateKey.value = null;
|
||||
}
|
||||
|
||||
@@ -226,8 +202,6 @@ defineExpose({
|
||||
<MaskedInput id="mountOptionsPasswordInput" v-model="mountOptionsPassword" required />
|
||||
</FormGroup>
|
||||
|
||||
<Checkbox v-if="provider === 'cifs'" v-model="mountOptionsSeal" :label="$t('backups.configureBackupStorage.cifsSealSupport')" />
|
||||
|
||||
<FormGroup v-if="s3like(provider)">
|
||||
<label for="accessKeyIdInput">{{ $t('backups.configureBackupStorage.s3AccessKeyId') }}</label>
|
||||
<TextInput id="accessKeyIdInput" v-model="accessKeyId" required />
|
||||
|
||||
Reference in New Issue
Block a user