From e1fb2be835fc2e9da877c89a5414ecca6b260db3 Mon Sep 17 00:00:00 2001 From: Bryan Lima <42067040+BryanMLima@users.noreply.github.com> Date: Mon, 27 Jun 2022 08:24:37 -0300 Subject: [PATCH] Add check for update only name and/or description of disk offering (#6410) * Add check for update only name and/or description of disk offering * Add check to update only name and/or description of service offerings as well --- ui/src/views/AutogenView.vue | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/ui/src/views/AutogenView.vue b/ui/src/views/AutogenView.vue index ff75a6d2697..8d2d1353c30 100644 --- a/ui/src/views/AutogenView.vue +++ b/ui/src/views/AutogenView.vue @@ -1358,6 +1358,20 @@ export default { if ('id' in this.resource && action.params.map(i => { return i.name }).includes('id')) { params.id = this.resource.id } + + if (['updateDiskOffering'].includes(action.api) && values.tags === this.resource.tags) { + delete values.tags + } + + if (['updateServiceOffering'].includes(action.api)) { + if (values.hosttags === this.resource.hosttags) { + delete values.hosttags + } + if (values.storagetags === this.resource.storagetags) { + delete values.tags + } + } + for (const key in values) { const input = values[key] for (const param of action.params) {