From 74c2a3d6e70485db3c954f321e3883e56bb725a7 Mon Sep 17 00:00:00 2001 From: Harshit Mehta Date: Tue, 8 Nov 2022 19:58:13 +0530 Subject: [PATCH] Few UI Enhancements (#79) - Add Install/Upgrade keywork dynamically on popup - Sort Repo list alphabetically - Sort CLuster list alphabetically Co-authored-by: Harshit Mehta --- pkg/dashboard/static/actions.js | 2 ++ pkg/dashboard/static/index.html | 2 +- pkg/dashboard/static/repo.js | 3 ++- pkg/dashboard/static/scripts.js | 1 + 4 files changed, 6 insertions(+), 2 deletions(-) diff --git a/pkg/dashboard/static/actions.js b/pkg/dashboard/static/actions.js index 11e1a25..5535926 100644 --- a/pkg/dashboard/static/actions.js +++ b/pkg/dashboard/static/actions.js @@ -62,10 +62,12 @@ function popUpUpgrade(elm, ns, name, verCur, lastRev) { $("#upgradeModal .rel-cluster").text(getHashParam("context")) if (verCur) { + $("#upgradeModalLabel .type").text("Upgrade") $("#upgradeModal .ver-old").show().find("span").text(verCur) $("#upgradeModal .rel-name").prop("disabled", true).val(name) $("#upgradeModal .rel-ns").prop("disabled", true).val(ns) } else { + $("#upgradeModalLabel .type").text("Install") $("#upgradeModal .ver-old").hide() $("#upgradeModal .rel-name").prop("disabled", false).val(elm.name.split("/").pop()) $("#upgradeModal .rel-ns").prop("disabled", false).val("") diff --git a/pkg/dashboard/static/index.html b/pkg/dashboard/static/index.html index 826fbc2..30d3b57 100644 --- a/pkg/dashboard/static/index.html +++ b/pkg/dashboard/static/index.html @@ -343,7 +343,7 @@