Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions ui/src/permission/modules/application/workspace.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,10 @@ const workspace = {
* 工作空间「智能体」创建权限
*/
create: () => can(P.APPLICATION_CREATE),
/**
* 工作空间「智能体」导入权限
*/
import: () => can(P.APPLICATION_IMPORT),
/**
* 工作空间「智能体」批量删除权限
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import { useStore } from '@/stores'
import { MsgSuccess } from '@/utils/message'
import AdvancedCreateDialog from '@/views/application/create-application/AdvancedCreateDialog.vue'
import SimpleCreateDialog from '@/views/application/create-application/SimpleCreateDialog.vue'
import perm from '@/permission'

defineOptions({ name: 'CreateApplicationDropdown' })

Expand Down Expand Up @@ -132,7 +133,7 @@ function handleRefresh() {
:on-change="handleImportCreate"
:show-file-list="false"
>
<MkDropdownItem class="w-full py-2!">
<MkDropdownItem v-if="perm.application.workspace.import()" class="w-full py-2!">
<template #icon>
<img class="size-7" src="@/assets/mk_icon_import.svg" alt="" />
</template>
Expand Down
Loading