case 4203

This commit is contained in:
2022-09-30 23:57:14 +00:00
parent e560743683
commit 8b93e985d3

View File

@@ -31,7 +31,7 @@
></v-checkbox>
</v-col>
<v-col cols="12" sm="6" lg="4" xl="3">
<v-col v-if="!subscriptionMode" cols="12" sm="6" lg="4" xl="3">
<v-text-field
ref="backupSetsToKeep"
v-model="obj.backupSetsToKeep"
@@ -117,7 +117,7 @@ export default {
id: 1,
concurrency: 0,
backupTime: null,
backupSetsToKeep: null,
backupSetsToKeep: 1,
backupAttachments: null
},
formState: {
@@ -140,6 +140,10 @@ export default {
computed: {
canSave: function() {
return this.formState.valid && this.formState.dirty;
},
//case 4203
subscriptionMode() {
return window.$gz.store.state.globalSettings.sBuild;
}
},
watch: {
@@ -187,6 +191,7 @@ export default {
beforeDestroy() {
window.$gz.eventBus.$off("menu-click", clickHandler);
},
methods: {
translation() {
return window.$gz.translation;
@@ -306,7 +311,13 @@ export default {
try {
if (vm.canSave) {
vm.formState.loading = true;
window.$gz.form.deleteAllErrorBoxErrors(vm);
//case 4203
//always 1 if a subscription
if (this.subscriptionMode) {
vm.obj.backupSetsToKeep = 1;
}
const res = await window.$gz.api.upsert(
"global-ops-backup-setting",
vm.obj