From 778e58360ce20b3678a09ab12422a060f16d4761 Mon Sep 17 00:00:00 2001 From: Andrei Pohilko Date: Wed, 22 Feb 2023 11:24:03 +0000 Subject: [PATCH] Fix the values not considered correctly when loading the upgrade preview --- pkg/dashboard/static/actions.js | 6 ++++-- pkg/dashboard/static/index.html | 3 +-- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/pkg/dashboard/static/actions.js b/pkg/dashboard/static/actions.js index bafed306..111d1798 100644 --- a/pkg/dashboard/static/actions.js +++ b/pkg/dashboard/static/actions.js @@ -102,11 +102,11 @@ function popUpUpgrade(elm, ns, name, verCur, lastRev) { $('#upgradeModal select').append(opt) } - $('#upgradeModal select').val(elm.version).trigger("change").parent().show() + $('#upgradeModal select').val(elm.version).parent().show() upgrPopUpCommon(verCur, ns, lastRev, name) }) } else { // chart without repo reconfigure - $('#upgradeModal select').empty().trigger("change").parent().hide() + $('#upgradeModal select').empty().parent().hide() upgrPopUpCommon(verCur, ns, lastRev, name) } } @@ -121,9 +121,11 @@ function upgrPopUpCommon(verCur, ns, lastRev, name) { reportError("Failed to get charts values info", xhr) }).done(function (data) { $("#upgradeModal textarea").val(data).data("dirty", false) + $('#upgradeModal select').trigger("change") }) } else { $("#upgradeModal textarea").val("").data("dirty", true) + $('#upgradeModal select').trigger("change") } } diff --git a/pkg/dashboard/static/index.html b/pkg/dashboard/static/index.html index 2eb94553..ea59ee40 100644 --- a/pkg/dashboard/static/index.html +++ b/pkg/dashboard/static/index.html @@ -64,10 +64,9 @@ -