check for the correct path when showing entities sidenav item (#7141)
* check for the correct path when showing entities sidenav item * update tests to check for correct api path * remove trailing slash
This commit is contained in:
parent
1d14832cad
commit
c5b5127fc4
|
@ -4,8 +4,8 @@ import { task } from 'ember-concurrency';
|
||||||
const API_PATHS = {
|
const API_PATHS = {
|
||||||
access: {
|
access: {
|
||||||
methods: 'sys/auth',
|
methods: 'sys/auth',
|
||||||
entities: 'identity/entities',
|
entities: 'identity/entity/id',
|
||||||
groups: 'identity/groups',
|
groups: 'identity/group/id',
|
||||||
leases: 'sys/leases/lookup',
|
leases: 'sys/leases/lookup',
|
||||||
namespaces: 'sys/namespaces',
|
namespaces: 'sys/namespaces',
|
||||||
'control-groups': 'sys/control-group/',
|
'control-groups': 'sys/control-group/',
|
||||||
|
@ -35,8 +35,8 @@ const API_PATHS = {
|
||||||
|
|
||||||
const API_PATHS_TO_ROUTE_PARAMS = {
|
const API_PATHS_TO_ROUTE_PARAMS = {
|
||||||
'sys/auth': ['vault.cluster.access.methods'],
|
'sys/auth': ['vault.cluster.access.methods'],
|
||||||
'identity/entities': ['vault.cluster.access.identity', 'entities'],
|
'identity/entity/id': ['vault.cluster.access.identity', 'entities'],
|
||||||
'identity/groups': ['vault.cluster.access.identity', 'groups'],
|
'identity/group/id': ['vault.cluster.access.identity', 'groups'],
|
||||||
'sys/leases/lookup': ['vault.cluster.access.leases'],
|
'sys/leases/lookup': ['vault.cluster.access.leases'],
|
||||||
'sys/namespaces': ['vault.cluster.access.namespaces'],
|
'sys/namespaces': ['vault.cluster.access.namespaces'],
|
||||||
'sys/control-group/': ['vault.cluster.access.control-groups'],
|
'sys/control-group/': ['vault.cluster.access.control-groups'],
|
||||||
|
|
|
@ -148,7 +148,7 @@ module('Unit | Service | permissions', function(hooks) {
|
||||||
'sys/auth': {
|
'sys/auth': {
|
||||||
capabilities: ['deny'],
|
capabilities: ['deny'],
|
||||||
},
|
},
|
||||||
'identity/entities': {
|
'identity/entity/id': {
|
||||||
capabilities: ['read'],
|
capabilities: ['read'],
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue