From 3316efc00346889dfb547a62c404443ad9b901e4 Mon Sep 17 00:00:00 2001 From: baiqi Date: Tue, 25 Jun 2024 10:20:33 +0800 Subject: [PATCH] =?UTF-8?q?fix(=E5=85=A8=E5=B1=80):=20bugFix?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/business/ms-associate-case/apiTable.vue | 1 - .../src/components/business/ms-comment/comment-item.vue | 8 +++----- frontend/src/components/business/ms-comment/comment.tsx | 6 +++++- .../business/ms-link-file/associatedFileDrawer.vue | 8 +------- .../business/ms-minders/featureCaseMinder/commentList.vue | 1 + .../src/views/api-test/management/components/import.vue | 2 +- .../management/components/management/api/apiTable.vue | 5 ++--- .../management/components/management/case/caseTable.vue | 5 ++--- .../components/management/mock/mockMatchRuleForm.vue | 2 +- .../src/views/bug-management/components/commentTab.vue | 1 + .../components/tabContent/tabComment/tabCommentIndex.vue | 1 + .../taskCenter/component/scheduledTask.vue | 3 --- 12 files changed, 18 insertions(+), 25 deletions(-) diff --git a/frontend/src/components/business/ms-associate-case/apiTable.vue b/frontend/src/components/business/ms-associate-case/apiTable.vue index a672befb0f..9efd501f2e 100644 --- a/frontend/src/components/business/ms-associate-case/apiTable.vue +++ b/frontend/src/components/business/ms-associate-case/apiTable.vue @@ -139,7 +139,6 @@ dataIndex: 'tags', isTag: true, isStringTag: true, - width: 400, showDrag: true, }, { diff --git a/frontend/src/components/business/ms-comment/comment-item.vue b/frontend/src/components/business/ms-comment/comment-item.vue index f67d921c5c..64652e76f4 100644 --- a/frontend/src/components/business/ms-comment/comment-item.vue +++ b/frontend/src/components/business/ms-comment/comment-item.vue @@ -19,7 +19,7 @@ ({{ element.childComments?.length }})
void; // 回复 onEdit?: () => void; // 编辑 onDelete?: () => void; // 删除 @@ -62,10 +63,7 @@ // 是否拥有编辑|删除权限 const hasAuth = computed(() => { - return ( - props.element.createUser === userStore.id && - hasAnyPermission(['PROJECT_BUG:READ+COMMENT', 'FUNCTIONAL_CASE:READ+COMMENT']) - ); + return props.element.createUser === userStore.id && hasAnyPermission(props.permissions); }); const status = defineModel<'normal' | 'edit' | 'reply' | 'delete'>('status', { default: 'normal' }); diff --git a/frontend/src/components/business/ms-comment/comment.tsx b/frontend/src/components/business/ms-comment/comment.tsx index ce1ce2d4e0..715a784296 100644 --- a/frontend/src/components/business/ms-comment/comment.tsx +++ b/frontend/src/components/business/ms-comment/comment.tsx @@ -22,13 +22,16 @@ export default defineComponent({ }, uploadImage: { type: Function, - // eslint-disable-next-line @typescript-eslint/no-empty-function default: (file: File) => Promise, }, previewUrl: { type: String as PropType, default: '', }, + permissions: { + type: Array as PropType, + default: () => [], + }, }, emits: { /* eslint-disable @typescript-eslint/no-unused-vars */ @@ -179,6 +182,7 @@ export default defineComponent({ {/* {expendedIds.value}--expendedIds */} handleReply(item)} onEdit={() => handelEdit(item)} onDelete={() => handleDelete(item)} diff --git a/frontend/src/components/business/ms-link-file/associatedFileDrawer.vue b/frontend/src/components/business/ms-link-file/associatedFileDrawer.vue index 65f9d17f4b..d7866420aa 100644 --- a/frontend/src/components/business/ms-link-file/associatedFileDrawer.vue +++ b/frontend/src/components/business/ms-link-file/associatedFileDrawer.vue @@ -26,7 +26,7 @@ {{ t('project.fileManagement.module') }} {{ t('project.fileManagement.storage') }} -
+
import { ref } from 'vue'; - import { useVModel } from '@vueuse/core'; - import MsButton from '@/components/pure/ms-button/index.vue'; import MsDrawer from '@/components/pure/ms-drawer/index.vue'; import MsSplitBox from '@/components/pure/ms-split-box/index.vue'; import FileTree from './fileTree.vue'; @@ -155,10 +153,6 @@ const isExpandAll = ref(false); - function changeExpand() { - isExpandAll.value = !isExpandAll.value; - } - type FileShowType = 'Module' | 'Storage'; const showType = ref('Module'); diff --git a/frontend/src/components/business/ms-minders/featureCaseMinder/commentList.vue b/frontend/src/components/business/ms-minders/featureCaseMinder/commentList.vue index 7458a38d10..8e3d557de0 100644 --- a/frontend/src/components/business/ms-minders/featureCaseMinder/commentList.vue +++ b/frontend/src/components/business/ms-minders/featureCaseMinder/commentList.vue @@ -20,6 +20,7 @@ v-if="activeComment === 'reviewComment' || activeComment === 'executiveComment'" :review-comment-list="reviewCommentList" :active-comment="activeComment" + :permissions="['FUNCTIONAL_CASE:READ+COMMENT']" />