fix(缺陷管理): 修复缺陷管理转存不更新&菜单管理缺陷状态错误问题

This commit is contained in:
xinxin.wu 2024-04-12 14:24:27 +08:00 committed by 刘瑞斌
parent 269ab99ac5
commit a36044ee16
4 changed files with 19 additions and 4 deletions

View File

@ -127,7 +127,7 @@
:is-platform-default-template="isPlatformDefaultTemplate"
:platform-system-fields="platformSystemFields"
:current-platform="props.currentPlatform"
@update-success="updateSuccess"
@update-success="detailDrawerRef?.initDetail()"
/>
<BugCaseTab

View File

@ -104,11 +104,19 @@
}
}
async function initFileTree() {
try {
transCategory.value = await getTransferFileTree(currentProjectId.value);
} catch (error) {
console.log(error);
}
}
watch(
() => props.visible,
async (val) => {
if (val) {
transCategory.value = await getTransferFileTree(currentProjectId.value);
initFileTree();
}
}
);

View File

@ -187,6 +187,7 @@
const emit = defineEmits<{
(e: 'cancel', shouldSearch: boolean): void;
(e: 'ok');
}>();
const resetForm = () => {
@ -232,6 +233,7 @@
await postSaveDefectSync({ ...form, BUG_PLATFORM_CONFIG: JSON.stringify(formData) }, currentProjectId.value);
Message.success(t('common.createSuccess'));
handleCancel(true);
emit('ok');
} catch (error) {
// eslint-disable-next-line no-console
console.error(error);

View File

@ -389,7 +389,7 @@
/>
</template>
</MsBaseTable>
<DefectSync v-model:visible="defectDrawerVisible" @cancel="defectDrawerVisible = false" />
<DefectSync v-model:visible="defectDrawerVisible" @cancel="defectDrawerVisible = false" @ok="initMenuData()" />
<RelatedCase v-model:visible="relatedCaseDrawerVisible" @cancel="relatedCaseDrawerVisible = false" />
</template>
@ -835,14 +835,19 @@
}
};
onMounted(() => {
function initMenuData() {
setLoadListParams({ projectId: currentProjectId.value });
fetchData();
initExpendKeys();
}
onMounted(() => {
initMenuData();
});
watch(currentProjectId, () => {
fetchData();
});
watch(
() => expandedKeys.value.length,
(val) => {