fix: user with System Manager role is admin
(cherry picked from commit b5ed9692dff4997335ae389ac4f836bedc3e7898)
This commit is contained in:
parent
9c90f29281
commit
1519b3539c
@ -150,7 +150,7 @@ import { usersStore } from '@/stores/users'
|
||||
import { Avatar, TextInput, toast, call } from 'frappe-ui'
|
||||
import { ref, computed, h, onMounted } from 'vue'
|
||||
|
||||
const { users, getUserRole, isAdmin, isManager } = usersStore()
|
||||
const { users, isAdmin, isManager } = usersStore()
|
||||
|
||||
const showAddExistingModal = ref(false)
|
||||
const searchRef = ref(null)
|
||||
|
||||
@ -50,7 +50,7 @@ export const usersStore = defineStore('crm-users', () => {
|
||||
}
|
||||
|
||||
function isAdmin(email) {
|
||||
return getUser(email).is_admin
|
||||
return getUser(email).role === 'System Manager' || getUser(email).is_admin
|
||||
}
|
||||
|
||||
function isManager(email) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user