fix: 修复任务中心&报告数据错误&用例管理bug修复
This commit is contained in:
parent
528f831207
commit
77f5530767
|
@ -52,7 +52,7 @@
|
|||
width="100%"
|
||||
height="376px"
|
||||
theme="MS-text"
|
||||
:read-only="false"
|
||||
:read-only="true"
|
||||
:show-full-screen="false"
|
||||
/>
|
||||
</div>
|
||||
|
|
|
@ -47,7 +47,7 @@
|
|||
<MsIcon type="icon-icon_logs_outlined" class="mr-1 font-[16px] text-[rgb(var(--primary-5))]" />
|
||||
{{ t('ms.message.make.as.read') }}
|
||||
</a-button>
|
||||
<div class="mt-[26px] flex h-[calc(100%-150px)]">
|
||||
<div class="mt-[26px] flex">
|
||||
<MsList
|
||||
v-model:data="messageHistoryList"
|
||||
mode="remote"
|
||||
|
@ -56,6 +56,9 @@
|
|||
class="w-full rounded-[var(--border-radius-small)]"
|
||||
:no-more-data="noMoreData"
|
||||
raggable
|
||||
:virtual-list-props="{
|
||||
height: 'calc(100vh - 160px)',
|
||||
}"
|
||||
@reach-bottom="handleReachBottom"
|
||||
>
|
||||
<template #item="{ item }">
|
||||
|
@ -74,9 +77,11 @@
|
|||
<div class="font-medium text-[var(--color-text-2)]">{{ item.userName }} </div>
|
||||
<div class="font-medium text-[var(--color-text-2)]">{{ item.subject }}:</div>
|
||||
<MsButton @click="handleNameClick(item)">
|
||||
<div class="one-line-text">
|
||||
{{ item.resourceName }}
|
||||
</div>
|
||||
<a-tooltip :content="item.resourceName" :mouse-enter-delay="300">
|
||||
<div class="one-line-text max-w-[400px]">
|
||||
{{ item.resourceName }}
|
||||
</div>
|
||||
</a-tooltip>
|
||||
</MsButton>
|
||||
</div>
|
||||
<div class="ml-[50px] flex items-center">
|
||||
|
@ -91,9 +96,11 @@
|
|||
<div class="font-medium text-[var(--color-text-2)]">{{ item.userName }} </div>
|
||||
<div class="font-medium text-[var(--color-text-2)]">{{ item.subject }}:</div>
|
||||
<MsButton @click="handleNameClick(item)">
|
||||
<div class="one-line-text">
|
||||
{{ item.resourceName }}
|
||||
</div>
|
||||
<a-tooltip :content="item.resourceName" :mouse-enter-delay="300">
|
||||
<div class="one-line-text max-w-[400px]">
|
||||
{{ item.resourceName }}
|
||||
</div>
|
||||
</a-tooltip>
|
||||
</MsButton>
|
||||
</div>
|
||||
<div class="flex items-center">
|
||||
|
|
|
@ -133,11 +133,33 @@ export const pathMap: PathMapItem[] = [
|
|||
],
|
||||
},
|
||||
{
|
||||
key: 'API_TEST_REPORT', // 接口测试-接口测试报告
|
||||
key: 'API_TEST_REPORT', // 接口测试-报告
|
||||
locale: 'menu.apiTest.report',
|
||||
route: RouteEnum.API_TEST_REPORT,
|
||||
permission: [],
|
||||
level: MENU_LEVEL[2],
|
||||
children: [
|
||||
{
|
||||
key: 'API_TEST_REPORT_SCENARIO', // 接口测试-场景报告
|
||||
locale: 'report.api.scenario',
|
||||
route: RouteEnum.API_TEST_REPORT,
|
||||
permission: [],
|
||||
level: MENU_LEVEL[2],
|
||||
routeQuery: {
|
||||
type: 'API_SCENARIO',
|
||||
},
|
||||
},
|
||||
{
|
||||
key: 'API_TEST_REPORT_CASE', // 接口测试-用例报告
|
||||
locale: 'report.api.case',
|
||||
route: RouteEnum.API_TEST_REPORT,
|
||||
permission: [],
|
||||
level: MENU_LEVEL[2],
|
||||
routeQuery: {
|
||||
type: 'API_CASE',
|
||||
},
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
},
|
||||
|
|
|
@ -522,9 +522,6 @@
|
|||
:max-length="1000"
|
||||
></a-textarea>
|
||||
</a-modal>
|
||||
<!-- <a-modal v-model:visible="hostVisible" :title="t('project.environmental.host')" @close="hostModalClose">
|
||||
<a-table :columns="hostColumn" :data="hostData" />
|
||||
</a-modal> -->
|
||||
<DomainModal v-model:visible="hostVisible" :data="hostData" />
|
||||
</template>
|
||||
|
||||
|
|
|
@ -558,7 +558,7 @@
|
|||
}
|
||||
|
||||
function showDetail() {
|
||||
if (route.query.reportId && route.query.type) {
|
||||
if ((route.query.reportId || route.query.id) && route.query.type) {
|
||||
activeDetailId.value = route.query.reportId as string;
|
||||
activeReportIndex.value = 0;
|
||||
if (route.query.type === 'API_SCENARIO') {
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
<div>{{ t('report.detail.successCount') }}</div>
|
||||
</td>
|
||||
<td class="popover-value-td">
|
||||
{{ props.reportDetail.successCount }}
|
||||
{{ props.reportDetail.stepSuccessCount }}
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
|
@ -17,7 +17,7 @@
|
|||
<div>{{ t('report.detail.fakeErrorCount') }}</div>
|
||||
</td>
|
||||
<td class="popover-value-td">
|
||||
{{ props.reportDetail.fakeErrorCount }}
|
||||
{{ props.reportDetail.stepFakeErrorCount }}
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
|
@ -26,7 +26,7 @@
|
|||
<div>{{ t('report.detail.errorCount') }}</div>
|
||||
</td>
|
||||
<td class="popover-value-td">
|
||||
{{ props.reportDetail.errorCount }}
|
||||
{{ props.reportDetail.stepErrorCount }}
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
|
@ -35,7 +35,7 @@
|
|||
<div>{{ t('report.detail.pendingCount') }}</div>
|
||||
</td>
|
||||
<td class="popover-value-td">
|
||||
{{ props.reportDetail.pendingCount }}
|
||||
{{ props.reportDetail.stepPendingCount }}
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
@ -65,16 +65,16 @@
|
|||
const { t } = useI18n();
|
||||
|
||||
const getCountTotal = computed(() => {
|
||||
const { successCount, errorCount, fakeErrorCount, pendingCount } = props.reportDetail;
|
||||
return successCount + errorCount + fakeErrorCount + pendingCount;
|
||||
const { stepSuccessCount, stepFakeErrorCount, stepErrorCount, stepPendingCount } = props.reportDetail;
|
||||
return stepSuccessCount + stepFakeErrorCount + stepErrorCount + stepPendingCount;
|
||||
});
|
||||
|
||||
const colorData = computed(() => {
|
||||
if (
|
||||
props.reportDetail.successCount === 0 &&
|
||||
props.reportDetail.errorCount === 0 &&
|
||||
props.reportDetail.fakeErrorCount === 0 &&
|
||||
props.reportDetail.pendingCount === 0
|
||||
props.reportDetail.stepSuccessCount === 0 &&
|
||||
props.reportDetail.stepErrorCount === 0 &&
|
||||
props.reportDetail.stepFakeErrorCount === 0 &&
|
||||
props.reportDetail.stepPendingCount === 0
|
||||
) {
|
||||
return [
|
||||
{
|
||||
|
@ -85,19 +85,19 @@
|
|||
}
|
||||
return [
|
||||
{
|
||||
percentage: (props.reportDetail.successCount / getCountTotal.value) * 100,
|
||||
percentage: (props.reportDetail.stepSuccessCount / getCountTotal.value) * 100,
|
||||
color: 'rgb(var(--success-6))',
|
||||
},
|
||||
{
|
||||
percentage: (props.reportDetail.errorCount / getCountTotal.value) * 100,
|
||||
percentage: (props.reportDetail.stepFakeErrorCount / getCountTotal.value) * 100,
|
||||
color: 'rgb(var(--danger-6))',
|
||||
},
|
||||
{
|
||||
percentage: (props.reportDetail.fakeErrorCount / getCountTotal.value) * 100,
|
||||
percentage: (props.reportDetail.stepErrorCount / getCountTotal.value) * 100,
|
||||
color: 'rgb(var(--warning-6))',
|
||||
},
|
||||
{
|
||||
percentage: (props.reportDetail.pendingCount / getCountTotal.value) * 100,
|
||||
percentage: (props.reportDetail.stepPendingCount / getCountTotal.value) * 100,
|
||||
color: 'var(--color-text-input-border)',
|
||||
},
|
||||
];
|
||||
|
|
|
@ -331,11 +331,19 @@
|
|||
}
|
||||
|
||||
const virtualListProps = computed(() => {
|
||||
if (props.isModal) {
|
||||
return {
|
||||
height: 'calc(60vh - 190px)',
|
||||
threshold: 200,
|
||||
fixedSize: true,
|
||||
buffer: 15,
|
||||
};
|
||||
}
|
||||
return {
|
||||
height: 'calc(100vh - 366px)',
|
||||
height: 'calc(100vh - 325px)',
|
||||
threshold: 200,
|
||||
fixedSize: true,
|
||||
buffer: 15, // 缓冲区默认 10 的时候,虚拟滚动的底部 padding 计算有问题
|
||||
buffer: 15,
|
||||
};
|
||||
});
|
||||
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
<icon-down :class="innerVisible ? 'text-[rgb(var(--primary-5))]' : ''" />
|
||||
</a-button>
|
||||
<template #content>
|
||||
<div class="arco-table-filters-content">
|
||||
<div class="arco-table-filters-content max-w-[400px]">
|
||||
<div class="ml-[6px] flex items-center justify-start px-[6px] py-[2px]">
|
||||
<a-checkbox-group v-model:model-value="innerStatusFilters" direction="vertical" size="small">
|
||||
<a-checkbox
|
||||
|
@ -15,7 +15,9 @@
|
|||
:key="item[props.valueKey || 'value']"
|
||||
:value="item[props.valueKey || 'value']"
|
||||
>
|
||||
<slot name="item" :item="item" :index="index"></slot>
|
||||
<div class="one-line-text max-w-[300px]">
|
||||
<slot name="item" :item="item" :index="index"></slot>
|
||||
</div>
|
||||
</a-checkbox>
|
||||
</a-checkbox-group>
|
||||
</div>
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
<template>
|
||||
<div class="rounded-2xl bg-white">
|
||||
<div class="p-[24px] pb-[16px]">
|
||||
<MsCard simple no-content-padding>
|
||||
<div class="flex items-center border-b border-[var(--color-text-n8)] p-[24px_24px_16px_24px]">
|
||||
<a-button v-permission="['FUNCTIONAL_CASE:READ+ADD']" type="primary" @click="caseDetail">
|
||||
{{ t('caseManagement.featureCase.creatingCase') }}
|
||||
</a-button>
|
||||
|
@ -11,8 +11,7 @@
|
|||
{{ t('caseManagement.featureCase.importXmind') }}
|
||||
</a-button> -->
|
||||
</div>
|
||||
<a-divider class="!my-0" />
|
||||
<div class="pageWrap">
|
||||
<div class="pageWrap relative h-[calc(100%-73px)]">
|
||||
<MsSplitBox>
|
||||
<template #first>
|
||||
<div class="p-[24px] pb-0">
|
||||
|
@ -75,15 +74,19 @@
|
|||
@init="setRootModules"
|
||||
@drag-update="dragUpdate"
|
||||
></FeatureCaseTree>
|
||||
<div class="b-0 absolute w-[88%]">
|
||||
<a-divider class="!my-0 !mb-2" />
|
||||
<div class="case h-[38px]">
|
||||
<div class="flex items-center" :class="getActiveClass('recycle')" @click="setActiveFolder('recycle')">
|
||||
<MsIcon type="icon-icon_delete-trash_outlined" class="folder-icon" />
|
||||
<div class="folder-name mx-[4px]">{{ t('caseManagement.featureCase.recycle') }}</div>
|
||||
<div class="folder-count">({{ recycleModulesCount.all || 0 }})</div></div
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="flex-1">
|
||||
<a-divider class="!my-0 !mb-0" />
|
||||
<div class="case">
|
||||
<div
|
||||
class="flex items-center px-[20px]"
|
||||
:class="getActiveClass('recycle')"
|
||||
@click="setActiveFolder('recycle')"
|
||||
>
|
||||
<MsIcon type="icon-icon_delete-trash_outlined" class="folder-icon" />
|
||||
<div class="folder-name mx-[4px]">{{ t('caseManagement.featureCase.recycle') }}</div>
|
||||
<div class="folder-count">({{ recycleModulesCount.all || 0 }})</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -103,7 +106,8 @@
|
|||
</template>
|
||||
</MsSplitBox>
|
||||
</div>
|
||||
</div>
|
||||
</MsCard>
|
||||
<!-- </div> -->
|
||||
<ExportExcelModal
|
||||
v-model:visible="showExcelModal"
|
||||
:validate-type="validateType"
|
||||
|
@ -136,6 +140,7 @@
|
|||
import { useRouter } from 'vue-router';
|
||||
|
||||
import MsButton from '@/components/pure/ms-button/index.vue';
|
||||
import MsCard from '@/components/pure/ms-card/index.vue';
|
||||
import MsIcon from '@/components/pure/ms-icon-font/index.vue';
|
||||
import MsPopConfirm from '@/components/pure/ms-popconfirm/index.vue';
|
||||
import MsSplitBox from '@/components/pure/ms-split-box/index.vue';
|
||||
|
@ -404,7 +409,6 @@
|
|||
<style scoped lang="less">
|
||||
.pageWrap {
|
||||
min-width: 1000px;
|
||||
height: calc(100vh - 166px);
|
||||
border-radius: var(--border-radius-large);
|
||||
@apply bg-white;
|
||||
.case {
|
||||
|
|
|
@ -66,6 +66,19 @@
|
|||
</template>
|
||||
</a-trigger>
|
||||
</template>
|
||||
<template #reviewersFilter="{ columnConfig }">
|
||||
<TableFilter
|
||||
v-model:visible="reviewersFilterVisible"
|
||||
v-model:status-filters="reviewersFilters"
|
||||
:title="(columnConfig.title as string)"
|
||||
:list="memberOptions"
|
||||
@search="searchReview()"
|
||||
>
|
||||
<template #item="{ item }">
|
||||
{{ item.label }}
|
||||
</template>
|
||||
</TableFilter>
|
||||
</template>
|
||||
<template #passRateColumn>
|
||||
<div class="flex items-center text-[var(--color-text-3)]">
|
||||
{{ t('caseManagement.caseReview.passRate') }}
|
||||
|
@ -191,6 +204,7 @@
|
|||
import statusTag from '../statusTag.vue';
|
||||
import deleteReviewModal from './deleteReviewModal.vue';
|
||||
import ModuleTree from './moduleTree.vue';
|
||||
import TableFilter from '@/views/case-management/caseManagementFeature/components/tableFilter.vue';
|
||||
|
||||
import { getReviewList, getReviewUsers, moveReview } from '@/api/modules/case-management/caseReview';
|
||||
import { getProjectMemberCommentOptions } from '@/api/modules/project-management/projectMember';
|
||||
|
@ -240,6 +254,9 @@
|
|||
|
||||
const filterRowCount = ref(0);
|
||||
const filterConfigList = ref<FilterFormItem[]>([]);
|
||||
const memberOptions = ref<{ label: string; value: string }[]>([]);
|
||||
const reviewersFilters = ref<string[]>([]);
|
||||
const reviewersFilterVisible = ref(false);
|
||||
|
||||
onBeforeMount(async () => {
|
||||
try {
|
||||
|
@ -248,7 +265,7 @@
|
|||
getProjectMemberCommentOptions(appStore.currentProjectId, keyword.value),
|
||||
]);
|
||||
const userOptions = userRes.map((e) => ({ label: e.name, value: e.id }));
|
||||
const memberOptions = memberRes.map((e) => ({ label: e.name, value: e.id }));
|
||||
memberOptions.value = memberRes.map((e) => ({ label: e.name, value: e.id }));
|
||||
filterConfigList.value = [
|
||||
{
|
||||
title: 'ID',
|
||||
|
@ -329,7 +346,7 @@
|
|||
type: FilterType.SELECT,
|
||||
selectProps: {
|
||||
mode: 'static',
|
||||
options: memberOptions,
|
||||
options: memberOptions.value,
|
||||
},
|
||||
},
|
||||
{
|
||||
|
@ -426,6 +443,7 @@
|
|||
title: 'caseManagement.caseReview.reviewer',
|
||||
slotName: 'reviewers',
|
||||
dataIndex: 'reviewers',
|
||||
titleSlotName: 'reviewersFilter',
|
||||
width: 150,
|
||||
},
|
||||
{
|
||||
|
@ -521,7 +539,7 @@
|
|||
moduleIds,
|
||||
createByMe: props.showType === 'createByMe' ? userStore.id : undefined,
|
||||
reviewByMe: props.showType === 'reviewByMe' ? userStore.id : undefined,
|
||||
filter: { status: statusFilters.value },
|
||||
filter: { status: statusFilters.value, reviewers: reviewersFilters.value },
|
||||
combine: filter
|
||||
? {
|
||||
...filter.combine,
|
||||
|
|
|
@ -30,7 +30,7 @@
|
|||
width="100%"
|
||||
height="376px"
|
||||
theme="MS-text"
|
||||
:read-only="false"
|
||||
:read-only="true"
|
||||
:show-full-screen="false"
|
||||
/>
|
||||
</div>
|
||||
|
|
|
@ -131,6 +131,7 @@
|
|||
const handleCancel = (shouldSearch: boolean) => {
|
||||
emit('cancel', shouldSearch);
|
||||
sessionStorage.removeItem('platformKey');
|
||||
form.PLATFORM_KEY = '';
|
||||
fApi.value.clearValidateState();
|
||||
};
|
||||
const handlePlatformChange = async (value: SelectValue) => {
|
||||
|
@ -216,4 +217,4 @@
|
|||
}
|
||||
}
|
||||
);
|
||||
</script>
|
||||
</script>
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<template>
|
||||
<div class="px-[16px]">
|
||||
<div class="mb-4 flex items-center justify-between">
|
||||
<span>{{ t('project.taskCenter.apiCaseList', { type: props.name }) }}</span>
|
||||
<div class="mb-4 flex items-center justify-end">
|
||||
<!-- <span>{{ t('project.taskCenter.apiCaseList', { type: props.name }) }}</span> -->
|
||||
<a-input-search
|
||||
v-model:model-value="keyword"
|
||||
:placeholder="t('system.organization.searchIndexPlaceholder')"
|
||||
|
@ -27,6 +27,14 @@
|
|||
>{{ record.resourceNum }}</div
|
||||
>
|
||||
</template>
|
||||
<template #resourceName="{ record }">
|
||||
<div
|
||||
type="text"
|
||||
class="one-line-text flex w-full text-[rgb(var(--primary-5))]"
|
||||
@click="showDetail(record.resourceId)"
|
||||
>{{ record.resourceName }}</div
|
||||
>
|
||||
</template>
|
||||
<template #statusFilter="{ columnConfig }">
|
||||
<a-trigger
|
||||
v-model:popup-visible="statusFilterVisible"
|
||||
|
@ -203,6 +211,7 @@
|
|||
sortIndex: 1,
|
||||
fixed: 'left',
|
||||
showTooltip: true,
|
||||
showInTable: true,
|
||||
showDrag: false,
|
||||
columnSelectorDisabled: true,
|
||||
},
|
||||
|
@ -213,6 +222,7 @@
|
|||
width: 300,
|
||||
showDrag: false,
|
||||
showTooltip: true,
|
||||
showInTable: true,
|
||||
columnSelectorDisabled: true,
|
||||
},
|
||||
{
|
||||
|
@ -222,7 +232,7 @@
|
|||
showTooltip: true,
|
||||
showDrag: true,
|
||||
width: 200,
|
||||
showInTable: false,
|
||||
showInTable: true,
|
||||
},
|
||||
{
|
||||
title: 'system.organization.organizationName',
|
||||
|
@ -231,7 +241,7 @@
|
|||
showTooltip: true,
|
||||
showDrag: true,
|
||||
width: 200,
|
||||
showInTable: false,
|
||||
showInTable: true,
|
||||
},
|
||||
{
|
||||
title: 'project.taskCenter.executionResult',
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
<template>
|
||||
<div class="p-4 pt-0">
|
||||
<div class="mb-4 flex items-center justify-between">
|
||||
<div class="mb-4 flex items-center justify-end">
|
||||
<!-- TODO这个版本不上 -->
|
||||
<!-- <a-button type="primary">
|
||||
{{ t('project.taskCenter.createTask') }}
|
||||
|
@ -30,7 +30,12 @@
|
|||
>
|
||||
</template>
|
||||
<template #resourceName="{ record }">
|
||||
<div type="text" class="flex w-full">{{ record.resourceName }}</div>
|
||||
<div
|
||||
type="text"
|
||||
class="one-line-text flex w-full text-[rgb(var(--primary-5))]"
|
||||
@click="showDetail(record.resourceId)"
|
||||
>{{ record.resourceName }}</div
|
||||
>
|
||||
</template>
|
||||
<template #resourceType="{ record }">
|
||||
<div type="text" class="flex w-full">{{ t(resourceTypeMap[record.resourceType].label) }}</div>
|
||||
|
@ -123,6 +128,7 @@
|
|||
width: 140,
|
||||
showInTable: true,
|
||||
showTooltip: true,
|
||||
showDrag: false,
|
||||
columnSelectorDisabled: true,
|
||||
},
|
||||
{
|
||||
|
@ -130,9 +136,10 @@
|
|||
slotName: 'resourceName',
|
||||
dataIndex: 'resourceName',
|
||||
width: 200,
|
||||
showDrag: true,
|
||||
showDrag: false,
|
||||
showTooltip: true,
|
||||
columnSelectorDisabled: true,
|
||||
showInTable: true,
|
||||
},
|
||||
{
|
||||
title: 'project.taskCenter.resourceClassification',
|
||||
|
|
|
@ -62,7 +62,7 @@
|
|||
<div v-else class="splitBox">
|
||||
<div class="startStatus"> {{ t('system.orgTemplate.startState') }} </div>
|
||||
<div class="line"></div>
|
||||
<div class="endStatus"> {{ t('system.orgTemplate.endState') }} </div>
|
||||
<div class="endStatus"> {{ t('system.orgTemplate.flowState') }} </div>
|
||||
</div>
|
||||
</template>
|
||||
<template #cell="{ record }">
|
||||
|
|
|
@ -146,6 +146,7 @@ export default {
|
|||
'system.orgTemplate.example': 'example',
|
||||
'system.orgTemplate.startState': 'Start State',
|
||||
'system.orgTemplate.endState': 'End State',
|
||||
'system.orgTemplate.flowState': 'flow State',
|
||||
'system.orgTemplate.iconTip': 'Icon to adjust state order',
|
||||
'system.orgTemplate.anyStateToAll': 'Any state may switch to change state',
|
||||
'system.orgTemplate.enableAnyStateToAll': 'enabled',
|
||||
|
|
|
@ -138,6 +138,7 @@ export default {
|
|||
'system.orgTemplate.example': '示例',
|
||||
'system.orgTemplate.startState': '开始状态',
|
||||
'system.orgTemplate.endState': '结束状态',
|
||||
'system.orgTemplate.flowState': '流转状态',
|
||||
'system.orgTemplate.iconTip': '图标可调整状态顺序',
|
||||
'system.orgTemplate.anyStateToAll': '任何状态可转换到该状态',
|
||||
'system.orgTemplate.enableAnyStateToAll': '开启',
|
||||
|
|
Loading…
Reference in New Issue