From 286cbe3c723b4bcddf4fa5ba662e56251fdd75ba Mon Sep 17 00:00:00 2001 From: Richard Cox Date: Tue, 12 Mar 2024 11:48:30 +0000 Subject: [PATCH 1/9] Fix Legacy / Project group - fixed scenario exposed by the project virtual type where call to allTypes ruled out all virt / spoofed types if basic mode has an inavalid entry (!groupForBasicType) - however also removed the project virtual type. the nav item comes from `Project` group specified in `basicTypes` call) - fixed a few things around the project group - add label for project group - explicitely set project group root of app - fixed display of namespace icon for a menu item if there are no counts --- shell/assets/translations/en-us.yaml | 1 + shell/components/nav/Type.vue | 13 ++++++++----- shell/config/product/legacy.js | 13 ++----------- shell/store/type-map.js | 2 +- 4 files changed, 12 insertions(+), 17 deletions(-) diff --git a/shell/assets/translations/en-us.yaml b/shell/assets/translations/en-us.yaml index eeb2138382a..3df531e2f2f 100644 --- a/shell/assets/translations/en-us.yaml +++ b/shell/assets/translations/en-us.yaml @@ -168,6 +168,7 @@ nav: RBAC: RBAC Scheduling: Scheduling Storage: Storage + Project: Project ns: all: All Namespaces clusterLevel: Only Cluster Resources diff --git a/shell/components/nav/Type.vue b/shell/components/nav/Type.vue index 872bf72d2ec..5ee401bfc32 100644 --- a/shell/components/nav/Type.vue +++ b/shell/components/nav/Type.vue @@ -92,7 +92,7 @@ export default { }, showCount() { - return this.count !== undefined; + return this.count !== undefined && this.count !== null; }, namespaceIcon() { @@ -170,7 +170,7 @@ export default { :class="{'no-icon': !type.icon}" /> - {{ count }} + {{ count }} @@ -207,7 +210,7 @@ export default {