fix(测试计划): 修复测试计划tablebug&关联用例失败排除已关联用例查询问题

This commit is contained in:
xinxin.wu 2024-06-18 11:17:21 +08:00 committed by Craftsman
parent e9cfdf112c
commit b4619c882b
3 changed files with 23 additions and 1 deletions

View File

@ -580,7 +580,6 @@
selectedAssociateCasesParams.value = { ...param };
const node: PlanMinderNode = window.minder.getSelectedNode();
let associateType: string = '';
// TODO node
if (node.data.type === PlanMinderCollectionType.SCENARIO) {
associateType = PlanMinderAssociateType.SCENARIO_CASE;
} else {
@ -766,6 +765,7 @@
} catch (error) {
// eslint-disable-next-line no-console
console.log(error);
selectedAssociateCasesParams.value.selectIds = [];
} finally {
loading.value = false;
}

View File

@ -287,6 +287,18 @@
<MsTableMoreAction :list="getMoreActions(record)" @select="handleMoreActionSelect($event, record)" />
</div>
</template>
<template v-if="(keyword || '').trim() === ''" #empty>
<div class="flex w-full items-center justify-center p-[8px] text-[var(--color-text-4)]">
{{ t('common.noData') }}
<MsButton v-permission="['PROJECT_TEST_PLAN:READ+ADD']" class="ml-[8px]" @click="emit('new', 'group')">
{{ t('testPlan.testPlanIndex.createTestPlan') }}
</MsButton>
{{ t('caseManagement.featureCase.or') }}
<MsButton v-permission="['PROJECT_TEST_PLAN:READ+ADD']" class="ml-[8px]" @click="emit('new', 'testPlan')">
{{ t('testPlan.testPlanIndex.createTestPlanGroup') }}
</MsButton>
</div>
</template>
</MsBaseTable>
<a-modal
v-model:visible="executeVisible"
@ -442,6 +454,7 @@
const emit = defineEmits<{
(e: 'init', params: any): void;
(e: 'edit', record: TestPlanItem): void;
(e: 'new', type: string): void;
}>();
const isArchived = ref<boolean>(false);

View File

@ -94,6 +94,7 @@
:node-name="nodeName"
@init="initModulesCount"
@edit="handleEdit"
@new="createTestPlan"
/>
</div>
</template>
@ -274,6 +275,14 @@
function dragUpdate() {
planTableRef.value?.emitTableParams();
}
function createTestPlan(type: string) {
if (type === 'group') {
showPlanGroupModel.value = true;
} else {
showPlanDrawer.value = true;
}
}
</script>
<style scoped lang="less">