fix(权限完善):1.权限优化以下模块按钮查看权限全部归属超级管理员,只有职称角色未超级管理员用户才可以查看进入操作
deploy-hxtesting / build-and-deploy (push) Successful in 1m17s
deploy-hxtesting / build-and-deploy (push) Successful in 1m17s
1)如图一所示点击左下角个人信息弹出框中的“空间设置”、“成员管理“、”模型管理“、”全部设置“、”系统管理“ 2)点击进入”设置“页面中”空间“、”模型“、”发布集成“、”数据与扩展“、”系统管理“这几个大模块相关内容入口 2.成员管理页面增加一个字段”状态“:1-5 在职状态(试用/试用延期/正式/临时/实习)、6离职/7退休(顺便对数据进行清洗,工号首位带字母的都标记为离职其他都标记为正式) 3.检查各业务需求里所有选择员工相关都只能拉取选择正式员工!
This commit is contained in:
1 parent
b762deaf15
commit
7034d93256
49 files changed
+809
-130
No files matched your search
@@ -203,6 +203,7 @@ import { useRoute, useRouter } from 'vue-router'
|
||||
import type { LocationQueryRaw } from 'vue-router'
|
||||
import { useUIStore } from '@/stores/ui'
|
||||
import { useAuthStore } from '@/stores/auth'
|
||||
import { useTrainingRolesStore } from '@/stores/trainingRoles'
|
||||
import { useDeploymentCapabilitiesStore } from '@/stores/deploymentCapabilities'
|
||||
import { useI18n } from 'vue-i18n'
|
||||
import { MessagePlugin } from 'tdesign-vue-next'
|
||||
@@ -239,6 +240,7 @@ import {
|
||||
} from '@/config/integrations'
|
||||
import {
|
||||
SETTINGS_SECTION_MIN_ROLE,
|
||||
SUPER_ADMIN_SETTINGS_SECTIONS,
|
||||
SYSTEM_ADMIN_SETTINGS_SECTIONS,
|
||||
} from '@/config/settingsAccess'
|
||||
import { SETTINGS_SECTION_CAPABILITY, skillSettingsSupported } from '@/config/deploymentCapabilities'
|
||||
@@ -257,6 +259,7 @@ const route = useRoute()
|
||||
const router = useRouter()
|
||||
const uiStore = useUIStore()
|
||||
const authStore = useAuthStore()
|
||||
const trainingRolesStore = useTrainingRolesStore()
|
||||
const deploymentCapabilities = useDeploymentCapabilitiesStore()
|
||||
const { t, te } = useI18n()
|
||||
const hostSkills = computed(() => hostSkillsOnly(
|
||||
@@ -331,7 +334,15 @@ const isSectionSupported = (key: string): boolean => {
|
||||
}
|
||||
|
||||
const canSeeSection = (key: string): boolean => {
|
||||
// 000167 权限收口:「空间 / 模型 / 数据与扩展 / 系统管理」分组的分区与
|
||||
// 「发布集成」分组整体仅超级管理员可见(培训职称角色=超级管理员 或 平台
|
||||
// 超管,判定在 stores/trainingRoles.ts)。深链直入受限分区会落到
|
||||
// 「权限不足」提示块,入口与内容同口径。
|
||||
if (SUPER_ADMIN_SETTINGS_SECTIONS.has(key)) {
|
||||
return trainingRolesStore.isSuperAdmin
|
||||
}
|
||||
if (isIntegrationSection(key)) {
|
||||
if (!trainingRolesStore.isSuperAdmin) return false
|
||||
const min = INTEGRATION_TAB_MIN_ROLE[integrationTabFromSection(key)]
|
||||
if (!min) return true
|
||||
if (authStore.canAccessAllTenants) return true
|
||||
@@ -621,8 +632,18 @@ const handleSettingsNav = (e: CustomEvent) => {
|
||||
|
||||
onMounted(() => {
|
||||
window.addEventListener('settings-nav', handleSettingsNav as EventListener)
|
||||
// 分区可见性依赖职称角色(isSuperAdmin),深链直开设置页时也要先拉档案;
|
||||
// 切换空间后重取(store 内按空间键去重)。
|
||||
trainingRolesStore.ensureLoaded()
|
||||
})
|
||||
|
||||
watch(
|
||||
() => authStore.selectedTenantId,
|
||||
() => {
|
||||
trainingRolesStore.ensureLoaded()
|
||||
},
|
||||
)
|
||||
|
||||
watch(currentSection, () => {
|
||||
if (document.activeElement instanceof HTMLElement) {
|
||||
document.activeElement.blur()
|
||||
|
||||
Reference in new issue
Block a user