diff --git a/components/ConfigForm.vue b/components/ConfigForm.vue index d89d6e9..97cab08 100644 --- a/components/ConfigForm.vue +++ b/components/ConfigForm.vue @@ -86,12 +86,21 @@ export default { this.networkingDomain = '' } }, - selectServices(services) { - services.forEach((s) => { - if (this.nixinServices.indexOf(s) === -1) { - this.nixinServices.push(s) - } - }) + selectServices(bundleId, services) { + if (this.nixinBundles.includes(bundleId)) { + services.forEach((s) => { + if (this.nixinServices.indexOf(s) === -1) { + this.nixinServices.push(s) + } + }) + } else { + services.forEach((s) => { + const index = this.nixinServices.indexOf(s); + if (index > -1) { + this.nixinServices.splice(index, 1); + } + }) + } } } } @@ -144,7 +153,7 @@ export default {