mirror of https://github.com/rancher/dashboard.git
Merge pull request #3281 from codyrancher/cluster-member-is-system
Updating how we check to see if a clusterroletemplatebinding isSystem
This commit is contained in:
commit
0ddba568da
|
|
@ -9,6 +9,8 @@ export const CONTAINER_DEFAULT_RESOURCE_LIMIT = 'field.cattle.io/containerDefaul
|
|||
export const CATTLE_PUBLIC_ENDPOINTS = 'field.cattle.io/publicEndpoints';
|
||||
export const TARGET_WORKLOADS = 'field.cattle.io/targetWorkloadIds';
|
||||
export const UI_MANAGED = 'management.cattle.io/ui-managed';
|
||||
export const CREATOR_ID = 'field.cattle.io/creatorId';
|
||||
export const CREATOR_OWNER_BINDING = 'authz.management.cattle.io/creator-owner-binding';
|
||||
|
||||
export const KUBERNETES = {
|
||||
SERVICE_ACCOUNT_UID: 'kubernetes.io/service-account.uid',
|
||||
|
|
|
|||
|
|
@ -1,3 +1,4 @@
|
|||
import { CREATOR_ID, CREATOR_OWNER_BINDING } from '@/config/labels-annotations';
|
||||
import { _CREATE } from '@/config/query-params';
|
||||
import { MANAGEMENT } from '@/config/types';
|
||||
|
||||
|
|
@ -79,5 +80,9 @@ export default {
|
|||
|
||||
subSearch() {
|
||||
return [{ nameDisplay: this.nameDisplay }];
|
||||
},
|
||||
|
||||
isSystem() {
|
||||
return !this.metadata.annotations[CREATOR_ID] && this.metadata.annotations[CREATOR_OWNER_BINDING] !== 'true';
|
||||
}
|
||||
};
|
||||
|
|
|
|||
|
|
@ -49,7 +49,7 @@ export default {
|
|||
computed: {
|
||||
filteredClusterRoleTemplateBindings() {
|
||||
return this.clusterRoleTemplateBindings
|
||||
.filter(b => !b.user?.isSystem && b.clusterName === this.$store.getters['currentCluster'].id);
|
||||
.filter(b => !b.isSystem && b.clusterName === this.$store.getters['currentCluster'].id);
|
||||
}
|
||||
},
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue