diff --git a/frontend/src/api/modules/case-management/caseReview.ts b/frontend/src/api/modules/case-management/caseReview.ts index 5785aad75e..f806bad319 100644 --- a/frontend/src/api/modules/case-management/caseReview.ts +++ b/frontend/src/api/modules/case-management/caseReview.ts @@ -3,31 +3,52 @@ import { AddReviewModuleUrl, AddReviewUrl, AssociateReviewUrl, + BatchChangeReviewerUrl, + BatchDisassociateReviewCaseUrl, + BatchReviewUrl, CopyReviewUrl, DeleteReviewModuleUrl, + DeleteReviewUrl, + DisassociateReviewCaseUrl, EditReviewUrl, FollowReviewUrl, GetAssociatedIdsUrl, + GetCaseReviewHistoryListUrl, + GetReviewDetailCasePageUrl, + GetReviewDetailModuleCountUrl, + GetReviewDetailModuleTreeUrl, GetReviewDetailUrl, GetReviewListUrl, GetReviewModulesUrl, GetReviewUsersUrl, MoveReviewModuleUrl, MoveReviewUrl, + ReviewModuleCountUrl, + SaveCaseReviewResultUrl, + SortReviewDetailCaseUrl, SortReviewUrl, UpdateReviewModuleUrl, } from '@/api/requrls/case-management/caseReview'; import { AssociateReviewCaseParams, + BatchCancelReviewCaseParams, + BatchChangeReviewerParams, BatchMoveReviewParams, + BatchReviewCaseParams, + CommitReviewResultParams, + CopyReviewParams, FollowReviewParams, Review, + ReviewCaseItem, + ReviewDetailCaseListQueryParams, + ReviewHistoryItem, ReviewItem, ReviewListQueryParams, ReviewModule, ReviewModuleItem, ReviewUserItem, + SortReviewCaseParams, SortReviewParams, UpdateReviewModuleParams, UpdateReviewParams, @@ -59,6 +80,11 @@ export const deleteReviewModule = (id: string) => { return MSR.get({ url: DeleteReviewModuleUrl, params: id }); }; +// 评审模块树-统计用例数量 +export const reviewModuleCount = (data: ReviewListQueryParams) => { + return MSR.post({ url: ReviewModuleCountUrl, data }); +}; + // 新增评审 export const addReview = (data: Review) => { return MSR.post({ url: AddReviewUrl, data }); @@ -70,7 +96,7 @@ export const associateReviewCase = (data: AssociateReviewCaseParams) => { }; // 复制评审 -export const copyReview = (data: Review) => { +export const copyReview = (data: CopyReviewParams) => { return MSR.post({ url: CopyReviewUrl, data }); }; @@ -109,7 +135,62 @@ export const getReviewUsers = (projectId: string, keyword: string) => { return MSR.get({ url: `${GetReviewUsersUrl}/${projectId}`, params: { keyword } }); }; -// 获取评审人员列表 +// 取消关联用例 +export const disassociateReviewCase = (reviewId: string, caseId: string) => { + return MSR.get({ url: `${DisassociateReviewCaseUrl}/${reviewId}/${caseId}` }); +}; + +// 删除评审 +export const deleteReview = (reviewId: string, projectId: string) => { + return MSR.get({ url: `${DeleteReviewUrl}/${projectId}/${reviewId}` }); +}; + +// 评审详情-获取用例列表 +export const getReviewDetailCasePage = (data: ReviewDetailCaseListQueryParams) => { + return MSR.post>({ url: GetReviewDetailCasePageUrl, data }); +}; + +// 评审详情-用例拖拽排序 +export const sortReviewDetailCase = (data: SortReviewCaseParams) => { + return MSR.post({ url: SortReviewDetailCaseUrl, data }); +}; + +// 评审详情-批量评审 +export const batchReview = (data: BatchReviewCaseParams) => { + return MSR.post({ url: BatchReviewUrl, data }); +}; + +// 评审详情-批量修改评审人 +export const batchChangeReviewer = (data: BatchChangeReviewerParams) => { + return MSR.post({ url: BatchChangeReviewerUrl, data }); +}; + +// 评审详情-批量取消关联用例 +export const batchDisassociateReviewCase = (data: BatchCancelReviewCaseParams) => { + return MSR.post({ url: BatchDisassociateReviewCaseUrl, data }); +}; + +// 获取关联用例 id集合 export const getAssociatedIds = (reviewId: string) => { return MSR.get({ url: `${GetAssociatedIdsUrl}/${reviewId}` }); }; + +// 评审详情-模块下用例数量统计 +export const getReviewDetailModuleCount = (data: ReviewDetailCaseListQueryParams) => { + return MSR.post({ url: GetReviewDetailModuleCountUrl, data }); +}; + +// 评审详情-已关联用例模块树 +export const getReviewDetailModuleTree = (projectId: string, reviewId: string) => { + return MSR.get({ url: `${GetReviewDetailModuleTreeUrl}/${projectId}/${reviewId}` }); +}; + +// 评审详情-获取用例评审历史 +export const getCaseReviewHistoryList = (reviewId: string, caseId: string) => { + return MSR.get({ url: `${GetCaseReviewHistoryListUrl}/${reviewId}/${caseId}` }); +}; + +// 评审详情-提交用例评审结果 +export const saveCaseReviewResult = (data: CommitReviewResultParams) => { + return MSR.post({ url: SaveCaseReviewResultUrl, data }); +}; diff --git a/frontend/src/api/modules/case-management/featureCase.ts b/frontend/src/api/modules/case-management/featureCase.ts index 09310585cc..6426c72c9d 100644 --- a/frontend/src/api/modules/case-management/featureCase.ts +++ b/frontend/src/api/modules/case-management/featureCase.ts @@ -76,6 +76,7 @@ import type { CreateOrUpdateModule, DeleteCaseType, DemandItem, + DetailCase, ModulesTreeType, OperationFile, UpdateModule, diff --git a/frontend/src/api/modules/user/index.ts b/frontend/src/api/modules/user/index.ts index 25e443493f..698dbf034e 100644 --- a/frontend/src/api/modules/user/index.ts +++ b/frontend/src/api/modules/user/index.ts @@ -11,15 +11,19 @@ import { GetInfoUrl, GetLocalConfigUrl, GetMenuListUrl, + GetPlatformAccountUrl, + GetPlatformUrl, GetPublicKeyUrl, isLoginUrl, LoginUrl, LogoutUrl, + SavePlatformUrl, UpdateAPIKEYUrl, UpdateInfoUrl, UpdateLocalConfigUrl, UpdatePswUrl, ValidAPIKEYUrl, + ValidatePlatformUrl, ValidLocalConfigUrl, } from '@/api/requrls/user'; @@ -137,3 +141,23 @@ export function updateBaseInfo(data: UpdateBaseInfo) { export function updatePsw(data: UpdatePswParams) { return MSR.post({ url: UpdatePswUrl, data }); } + +// 个人信息-校验第三方平台账号信息 +export function validatePlatform(id: string, data: Record) { + return MSR.post({ url: `${ValidatePlatformUrl}/${id}`, data }); +} + +// 个人信息-保存第三方平台账号信息 +export function savePlatform(data: UpdatePswParams) { + return MSR.post({ url: SavePlatformUrl, data }); +} + +// 个人信息-获取第三方平台账号信息 +export function getPlatform() { + return MSR.get({ url: GetPlatformUrl }); +} + +// 个人信息-获取第三方平台账号信息-插件信息 +export function getPlatformAccount() { + return MSR.get({ url: GetPlatformAccountUrl }); +} diff --git a/frontend/src/api/requrls/case-management/caseReview.ts b/frontend/src/api/requrls/case-management/caseReview.ts index 5f2e5971d1..2adbd1680d 100644 --- a/frontend/src/api/requrls/case-management/caseReview.ts +++ b/frontend/src/api/requrls/case-management/caseReview.ts @@ -8,9 +8,21 @@ export const AssociateReviewUrl = '/case/review/associate'; // 关联用例 export const AddReviewUrl = '/case/review/add'; // 新增评审 export const GetReviewUsersUrl = '/case/review/user-option'; // 获取评审人员列表 export const GetReviewDetailUrl = '/case/review/detail'; // 获取评审详情 +export const DisassociateReviewCaseUrl = '/case/review/disassociate'; // 取消关联用例 +export const DeleteReviewUrl = '/case/review/delete'; // 删除用例评审 export const UpdateReviewModuleUrl = '/case/review/module/update'; // 更新评审模块 export const MoveReviewModuleUrl = '/case/review/module/move'; // 移动评审模块 export const AddReviewModuleUrl = '/case/review/module/add'; // 新增评审模块 export const GetReviewModulesUrl = '/case/review/module/tree'; // 获取评审模块树 export const DeleteReviewModuleUrl = '/case/review/module/delete'; // 删除评审模块 +export const ReviewModuleCountUrl = '/case/review/module/count'; // 模块下用例数量统计 +export const GetReviewDetailCasePageUrl = '/case/review/detail/page'; // 评审详情-获取已关联用例列表 +export const SortReviewDetailCaseUrl = '/case/review/detail/edit/pos'; // 评审详情-已关联用例拖拽排序 +export const BatchReviewUrl = '/case/review/detail/batch/review'; // 评审详情-批量评审 +export const BatchChangeReviewerUrl = '/case/review/detail/batch/edit/reviewers'; // 评审详情-批量修改评审人 +export const BatchDisassociateReviewCaseUrl = '/case/review/detail/batch/disassociate'; // 评审详情-批量取消关联用例 export const GetAssociatedIdsUrl = '/case/review/detail/get-ids'; // 获取已关联用例id集合 +export const GetReviewDetailModuleCountUrl = '/case/review/detail/module/count'; // 评审详情-模块下用例数量统计 +export const GetReviewDetailModuleTreeUrl = '/case/review/detail/tree'; // 评审详情-已关联用例模块树 +export const GetCaseReviewHistoryListUrl = '/review/functional/case/get/list'; // 评审详情-获取用例评审历史 +export const SaveCaseReviewResultUrl = '/review/functional/case/save'; // 评审详情-提交评审 diff --git a/frontend/src/api/requrls/user.ts b/frontend/src/api/requrls/user.ts index 11a562ab44..5a01c1b8ee 100644 --- a/frontend/src/api/requrls/user.ts +++ b/frontend/src/api/requrls/user.ts @@ -19,3 +19,7 @@ export const AddAPIKEYUrl = '/user/api/key/add'; // 个人设置-生成 APIKEY export const UpdatePswUrl = '/personal/update-password'; // 个人信息-修改密码 export const UpdateInfoUrl = '/personal/update-info'; // 个人信息-修改信息 export const GetInfoUrl = '/personal/get'; // 个人信息-获取信息 +export const ValidatePlatformUrl = '/user/platform/validate'; // 个人信息-校验服务集成信息 +export const SavePlatformUrl = '/user/platform/save'; // 个人信息-保存三方平台账号信息 +export const GetPlatformUrl = '/user/platform/get'; // 个人信息-获取三方平台账号信息 +export const GetPlatformAccountUrl = '/user/platform/account/info'; // 个人信息-获取三方平台账号信息-插件信息 diff --git a/frontend/src/assets/style/arco-reset.less b/frontend/src/assets/style/arco-reset.less index e98dc8c612..0ac40f67e3 100644 --- a/frontend/src/assets/style/arco-reset.less +++ b/frontend/src/assets/style/arco-reset.less @@ -407,7 +407,7 @@ } } } -.arco-radio-checked { +.arco-radio-checked:not(.arco-radio-disabled) { .arco-radio-icon { @apply !bg-white; @@ -425,6 +425,15 @@ } } } +.arco-radio-checked.arco-radio-disabled { + .arco-radio-icon { + border: 1px solid var(--color-text-input-border); + background-color: var(--color-text-n8) !important; + &::after { + background-color: var(--color-text-4) !important; + } + } +} /** Message **/ .arco-message { diff --git a/frontend/src/components/business/ms-case-associate/index.vue b/frontend/src/components/business/ms-case-associate/index.vue index 38d00a2022..5c8a7cabad 100644 --- a/frontend/src/components/business/ms-case-associate/index.vue +++ b/frontend/src/components/business/ms-case-associate/index.vue @@ -15,9 +15,9 @@ class="ml-2 max-w-[100px]" :placeholder="t('caseManagement.featureCase.PleaseSelect')" > - {{ - t(item.label) - }} + + {{ t(item.label) }} + @@ -142,7 +142,7 @@ import type { MsTreeNodeData } from '@/components/business/ms-tree/types'; import caseLevel from './caseLevel.vue'; - import { getCustomFieldsTable } from '@/api/modules/case-management/featureCase'; + import { getCaseModulesCounts, getCustomFieldsTable } from '@/api/modules/case-management/featureCase'; import { useI18n } from '@/hooks/useI18n'; import useAppStore from '@/store/modules/app'; import { mapTree } from '@/utils'; @@ -164,7 +164,6 @@ modulesParams?: Record; // 获取模块树请求 getTableFunc: (params: TableQueryParams) => Promise>; // 获取表请求函数 tableParams?: TableQueryParams; // 查询表格的额外的参数 - modulesCount: Record; // 模块数量统计对象 okButtonDisabled?: boolean; // 确认按钮是否禁用 currentSelectCase: string | number | Record | undefined; // 当前选中的用例类型 moduleOptions?: { label: string; value: string }[]; // 功能模块对应用例下拉 @@ -178,7 +177,7 @@ (e: 'update:currentSelectCase', val: string | number | Record | undefined): void; (e: 'init', val: TableQueryParams): void; // 初始化模块数量 (e: 'close'): void; - (e: 'save', params: TableQueryParams): void; // 保存对外传递关联table 相关参数 + (e: 'save', params: any): void; // 保存对外传递关联table 相关参数 }>(); const virtualListProps = computed(() => { @@ -212,6 +211,7 @@ const protocolType = ref('HTTP'); // 协议类型 const protocolOptions = ref(['HTTP']); + const modulesCount = ref>({}); // 选中用例类型 const caseType = computed({ @@ -248,7 +248,7 @@ hideMoreAction: e.id === 'root', draggable: false, disabled: false, - count: props.modulesCount?.[e.id] || 0, + count: modulesCount.value[e.id] || 0, }; }); if (isSetDefaultKey) { @@ -498,16 +498,22 @@ } // 初始化模块数量 - function initModuleCount() { - emit('init', { - keyword: keyword.value, - moduleIds: [], - projectId: innerProject.value, - current: propsRes.value.msPagination?.current, - pageSize: propsRes.value.msPagination?.pageSize, - sourceId: props.caseId, - combine: combine.value, - }); + async function initModuleCount() { + try { + const params = { + keyword: keyword.value, + moduleIds: selectedModuleKeys.value, + projectId: innerProject.value, + current: propsRes.value.msPagination?.current, + pageSize: propsRes.value.msPagination?.pageSize, + combine: combine.value, + }; + modulesCount.value = await getCaseModulesCounts(params); + emit('init', params); + } catch (error) { + // eslint-disable-next-line no-console + console.log(error); + } } function searchCase() { @@ -556,6 +562,7 @@ innerVisible.value = val; if (val) { resetSelector(); + initModules(); searchCase(); initFilter(); } @@ -567,7 +574,7 @@ (val) => { emit('update:visible', val); if (val) { - initModules(true); + initModules(); } } ); @@ -578,7 +585,7 @@ (val) => { if (val) { emit('update:currentSelectCase', val); - initModules(true); + initModules(); searchCase(); } } @@ -597,8 +604,12 @@ () => innerProject.value, (val) => { emit('update:project', val); - initModules(true); - searchCase(); + if (innerVisible.value) { + searchCase(); + resetSelector(); + initModules(); + searchCase(); + } } ); @@ -613,7 +624,7 @@ * 初始化模块数量 */ watch( - () => props.modulesCount, + () => modulesCount.value, (obj) => { folderTree.value = mapTree(folderTree.value, (node) => { return { diff --git a/frontend/src/components/business/ms-comment/input.vue b/frontend/src/components/business/ms-comment/input.vue index 1a960a530f..572307316d 100644 --- a/frontend/src/components/business/ms-comment/input.vue +++ b/frontend/src/components/business/ms-comment/input.vue @@ -22,6 +22,7 @@ + + diff --git a/frontend/src/components/pure/ms-split-box/index.vue b/frontend/src/components/pure/ms-split-box/index.vue index 9222a5833e..1c3215f8cb 100644 --- a/frontend/src/components/pure/ms-split-box/index.vue +++ b/frontend/src/components/pure/ms-split-box/index.vue @@ -150,6 +150,9 @@ :deep(.arco-split-pane) { @apply relative overflow-hidden; } + // :deep(.arco-split-pane-second) { + // @apply z-10; + // } .animating { :deep(.arco-split-pane) { @apply relative overflow-hidden; @@ -207,12 +210,12 @@ .vertical-expand-line { @apply relative z-10 flex items-center justify-center bg-transparent; &::before { - @apply absolute w-full; + @apply absolute w-full bg-transparent; margin-bottom: -4px; height: 4px; - box-shadow: 0 -1px 4px 0 rgb(31 35 41 / 10%), 0 -1px 4px 0 rgb(255 255 255), 0 -1px 4px 0 rgb(255 255 255), - 0 -1px 4px 0 rgb(255 255 255); + box-shadow: 0 -2px 2px 0 rgb(31 35 41 / 10%), 0 -4px 4px 0 rgb(255 255 255), 0 -4px 4px 0 rgb(255 255 255), + 0 -4px 4px 0 rgb(255 255 255); content: ''; } // .expand-icon--vertical { diff --git a/frontend/src/components/pure/ms-table/useTable.ts b/frontend/src/components/pure/ms-table/useTable.ts index 1e8c832118..092f8a9f87 100644 --- a/frontend/src/components/pure/ms-table/useTable.ts +++ b/frontend/src/components/pure/ms-table/useTable.ts @@ -94,6 +94,8 @@ export default function useTableProps( const keyword = ref(''); // 高级筛选 const advanceFilter = reactive({ accordBelow: 'AND', combine: {} }); + // 表格请求参数集合 + const tableQueryParams = ref({}); // 是否分页 if (propsRes.value.showPagination) { @@ -193,7 +195,7 @@ export default function useTableProps( try { if (loadListFunc) { setLoading(true); - const data = await loadListFunc({ + tableQueryParams.value = { current, pageSize: currentPageSize, sort: sortItem.value, @@ -202,7 +204,8 @@ export default function useTableProps( combine: advanceFilter.combine, searchMode: advanceFilter.accordBelow, ...loadListParams.value, - }); + }; + const data = await loadListFunc(tableQueryParams.value); const tmpArr = data.list; propsRes.value.data = tmpArr.map((item: MsTableDataItem) => { if (item.updateTime) { @@ -312,6 +315,11 @@ export default function useTableProps( } }; + // 获取表格请求参数 + const getTableQueryParams = () => { + return tableQueryParams.value; + }; + // 事件触发组 const propsEvent = ref({ // 排序触发 @@ -442,5 +450,6 @@ export default function useTableProps( resetPagination, getSelectedCount, resetSelector, + getTableQueryParams, }; } diff --git a/frontend/src/components/pure/ms-upload/index.vue b/frontend/src/components/pure/ms-upload/index.vue index 4ed4b81114..ab6a1f141d 100644 --- a/frontend/src/components/pure/ms-upload/index.vue +++ b/frontend/src/components/pure/ms-upload/index.vue @@ -222,7 +222,7 @@ }); onBeforeUnmount(() => { - if (props.isAllScreen) resizeObserver.value.disconnect(); + if (props.isAllScreen) resizeObserver.value?.disconnect(); }); diff --git a/frontend/src/components/pure/navbar/index.vue b/frontend/src/components/pure/navbar/index.vue index 8e4288f8e2..930533be1a 100644 --- a/frontend/src/components/pure/navbar/index.vue +++ b/frontend/src/components/pure/navbar/index.vue @@ -12,7 +12,7 @@