fix(用例管理): 用例模块数搜索调整

--bug=1036713 --user=王旭 【用例管理】功能用例树与用例评审树风格不一致 https://www.tapd.cn/55049933/s/1493806
This commit is contained in:
WangXu10 2024-04-10 20:03:04 +08:00 committed by Craftsman
parent c6b443d96c
commit e1eff5a611
2 changed files with 10 additions and 10 deletions

View File

@ -1,16 +1,10 @@
<template>
<a-input-search
v-model:model-value="groupKeyword"
:placeholder="t('caseManagement.featureCase.searchTip')"
allow-clear
class="mb-[16px]"
></a-input-search>
<a-spin class="w-full" :style="{ height: `calc(100vh - 346px)` }" :loading="loading">
<MsTree
v-model:focus-node-key="focusNodeKey"
:selected-keys="props.selectedKeys"
:data="caseTree"
:keyword="groupKeyword"
:keyword="props.groupKeyword"
:node-more-actions="caseMoreActions"
:expand-all="props.isExpandAll"
:empty-text="t('common.noData')"
@ -111,14 +105,13 @@
isExpandAll: boolean; //
allNames?: string[]; // name
modulesCount?: Record<string, number>; //
groupKeyword?: string; //
}>();
const emits = defineEmits(['update:selectedKeys', 'caseNodeSelect', 'init', 'dragUpdate']);
const currentProjectId = computed(() => appStore.currentProjectId);
const groupKeyword = ref<string>('');
const caseTree = ref<ModuleTreeNode[]>([]);
const setFocusKey = (node: MsTreeNodeData) => {

View File

@ -17,6 +17,12 @@
<template #first>
<div class="p-[24px] pb-0">
<div class="feature-case h-[100%]">
<a-input-search
v-model:model-value="groupKeyword"
:placeholder="t('caseManagement.featureCase.searchTip')"
allow-clear
class="mb-[16px]"
></a-input-search>
<div class="case h-[38px]">
<div class="flex items-center" :class="getActiveClass('all')" @click="setActiveFolder('all')">
<MsIcon type="icon-icon_folder_filled1" class="folder-icon" />
@ -64,6 +70,7 @@
:active-folder="activeFolder"
:is-expand-all="isExpandAll"
:modules-count="modulesCount"
:group-keyword="groupKeyword"
@case-node-select="caseNodeSelect"
@init="setRootModules"
@drag-update="dragUpdate"
@ -163,7 +170,7 @@
const isExpandAll = ref(false);
const activeCaseType = ref<'folder' | 'module'>('folder'); //
const rootModulesName = ref<string[]>([]); //
const groupKeyword = ref<string>('');
//
const expandHandler = () => {
isExpandAll.value = !isExpandAll.value;