fix: wrong hidden menu condition
This commit is contained in:
parent
519b0d7e94
commit
a0013bdbe0
1 changed files with 6 additions and 9 deletions
|
|
@ -1,5 +1,5 @@
|
|||
<script setup lang="ts">
|
||||
import { computed, ref, onMounted, watch, nextTick } from 'vue';
|
||||
import { computed, ref, onMounted, watch } from 'vue';
|
||||
import { useRouter } from 'vue-router';
|
||||
import { storeToRefs } from 'pinia';
|
||||
import { Icon } from '@iconify/vue';
|
||||
|
|
@ -105,28 +105,25 @@ onMounted(async () => {
|
|||
{
|
||||
label: 'branch',
|
||||
route: '/branch-management',
|
||||
hidden:
|
||||
hidden: !(
|
||||
role.value.includes('admin') ||
|
||||
role.value.includes('branch_admin') ||
|
||||
role.value.includes('branch_manager') ||
|
||||
role.value.includes('head_of_admin') ||
|
||||
role.value.includes('system') ||
|
||||
role.value.includes('owner') ||
|
||||
role.value.includes('head_of_account')
|
||||
? false
|
||||
: true,
|
||||
),
|
||||
},
|
||||
{
|
||||
label: 'personnel',
|
||||
route: '/personnel-management',
|
||||
hidden:
|
||||
hidden: !(
|
||||
role.value.includes('admin') ||
|
||||
role.value.includes('branch_admin') ||
|
||||
role.value.includes('head_of_admin') ||
|
||||
role.value.includes('system') ||
|
||||
role.value.includes('owner') ||
|
||||
role.value.includes('branch_manager')
|
||||
? false
|
||||
: true,
|
||||
),
|
||||
},
|
||||
{ label: 'workflow', route: '/workflow' },
|
||||
{ label: 'productService', route: '/product-service' },
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue