fix: only show Invite Member settings page if manager
This commit is contained in:
parent
fb6246e1f2
commit
6dc2199a81
@ -53,6 +53,7 @@ import WhatsAppSettings from '@/components/Settings/WhatsAppSettings.vue'
|
|||||||
import ERPNextSettings from '@/components/Settings/ERPNextSettings.vue'
|
import ERPNextSettings from '@/components/Settings/ERPNextSettings.vue'
|
||||||
import TwilioSettings from '@/components/Settings/TwilioSettings.vue'
|
import TwilioSettings from '@/components/Settings/TwilioSettings.vue'
|
||||||
import SidebarLink from '@/components/SidebarLink.vue'
|
import SidebarLink from '@/components/SidebarLink.vue'
|
||||||
|
import { usersStore } from '@/stores/users'
|
||||||
import {
|
import {
|
||||||
isWhatsappInstalled,
|
isWhatsappInstalled,
|
||||||
showSettings,
|
showSettings,
|
||||||
@ -61,6 +62,8 @@ import {
|
|||||||
import { Dialog, Plans, Billing } from 'frappe-ui'
|
import { Dialog, Plans, Billing } from 'frappe-ui'
|
||||||
import { ref, markRaw, computed, watch } from 'vue'
|
import { ref, markRaw, computed, watch } from 'vue'
|
||||||
|
|
||||||
|
const { isManager } = usersStore()
|
||||||
|
|
||||||
const tabs = computed(() => {
|
const tabs = computed(() => {
|
||||||
let _tabs = [
|
let _tabs = [
|
||||||
{
|
{
|
||||||
@ -76,6 +79,7 @@ const tabs = computed(() => {
|
|||||||
label: __('Invite Members'),
|
label: __('Invite Members'),
|
||||||
icon: 'user-plus',
|
icon: 'user-plus',
|
||||||
component: markRaw(InviteMemberPage),
|
component: markRaw(InviteMemberPage),
|
||||||
|
condition: () => isManager(),
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user