fix: 企业微信登录提示和隐藏立账凭证页面
This commit is contained in:
1 parent
4587b56900
commit
4fa947c8d7
15 files changed
+20
-748
No files matched your search
@@ -35,6 +35,10 @@ const secondaryLinkItems = [
|
||||
{ path: WORKSPACE_PATHS.updates, labelKey: 'workspace.nav.updates', icon: Megaphone, match: ['workspace-updates'] },
|
||||
] as const;
|
||||
|
||||
const visibleLinkItems = computed(() => linkItems.filter((item) => (
|
||||
item.match[0] !== 'workspace-accounting-voucher-check' || String(ws.currentUser?.role || '').toLowerCase() === 'admin'
|
||||
)));
|
||||
|
||||
function isActive(match: readonly string[]) {
|
||||
return match.includes(String(route.name || ''));
|
||||
}
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
/**
|
||||
* features/workspace/composables/useWorkspaceNavigation.ts
|
||||
* 子路由导航、移动端 Tab、聊天跳转、企微 deeplink 与旧 view 参数兼容。
|
||||
* 用途:子路由导航、移动端 Tab、聊天跳转、企微 deeplink 与旧 view 参数兼容。
|
||||
* 依赖:vue-router、config、auth、requestJson、workspace routes/types。
|
||||
* 逻辑:由 useWorkspace 注入;知识库与立账凭证检核均按管理员权限控制入口和路由访问。
|
||||
*/
|
||||
import { computed, nextTick, ref, watch, type ComputedRef, type Ref } from 'vue';
|
||||
import { config } from '@/config';
|
||||
@@ -180,6 +182,9 @@ export function useWorkspaceNavigation(deps: WorkspaceDeps, options: NavigationO
|
||||
showKnowledgeBaseAccessDenied();
|
||||
await router.replace(WORKSPACE_PATHS.applications);
|
||||
}
|
||||
if (name === 'workspace-accounting-voucher-check' && !hasKnowledgeBaseAccess.value) {
|
||||
await router.replace(WORKSPACE_PATHS.applications);
|
||||
}
|
||||
if (name === 'workspace-feedback') {
|
||||
showGeneralFeedbackDialog.value = true;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user