Merge pull request #958 from frappe/mergify/bp/main-hotfix/pr-957

fix: user with System Manager role is admin (backport #957)
This commit is contained in:
Shariq Ansari 2025-06-24 11:57:46 +05:30 committed by GitHub
commit ee6c16c78d
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 2 additions and 2 deletions

View File

@ -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)

View File

@ -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) {