Skip to content

Commit

Permalink
Don't allow selection of Not in a Project
Browse files Browse the repository at this point in the history
  • Loading branch information
richard-cox committed May 18, 2023
1 parent 936d35b commit 5feb263
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion shell/components/nav/NamespaceFilter.vue
Original file line number Diff line number Diff line change
Expand Up @@ -96,8 +96,10 @@ export default {
// Are we in restricted resource type mode, if so is this an allowed type?
if (this.namespaceFilterMode?.length) {
const isLastSelected = i.selected && (i.id === ALL || this.value.length === 1);
const kindAllowed = this.namespaceFilterMode.find(f => f === i.kind);
const isNotInProjectGroup = i.id === ALL_ORPHANS;
i.enabled = !isLastSelected && this.namespaceFilterMode.find(f => f === i.kind);
i.enabled = (!isLastSelected && kindAllowed) && !isNotInProjectGroup;
}
});
Expand Down

0 comments on commit 5feb263

Please sign in to comment.