enhance: permission handling
This commit is contained in:
parent
35fd8a8e82
commit
4ee16c624a
2 changed files with 22 additions and 7 deletions
|
@ -48,7 +48,7 @@ export const useNavigationStore = defineStore("navigation", {
|
|||
updateTopLevel() {
|
||||
const abilityStore = useAbilityStore();
|
||||
this.topLevel = [
|
||||
...(abilityStore.canSection("read", "club")
|
||||
...(abilityStore.canAccessSection("club")
|
||||
? [
|
||||
{
|
||||
key: "club",
|
||||
|
@ -57,7 +57,7 @@ export const useNavigationStore = defineStore("navigation", {
|
|||
} as topLevelNavigationModel,
|
||||
]
|
||||
: []),
|
||||
...(abilityStore.canSection("read", "configuration")
|
||||
...(abilityStore.canAccessSection("configuration")
|
||||
? [
|
||||
{
|
||||
key: "configuration",
|
||||
|
@ -66,7 +66,7 @@ export const useNavigationStore = defineStore("navigation", {
|
|||
} as topLevelNavigationModel,
|
||||
]
|
||||
: []),
|
||||
...(abilityStore.canSection("read", "management")
|
||||
...(abilityStore.canAccessSection("management")
|
||||
? [
|
||||
{
|
||||
key: "management",
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue