fix(测试计划): 修复测试计划报告预览初始化不正确紧急bug
This commit is contained in:
parent
0f0fe1ebae
commit
5bd094d3a8
|
@ -41,6 +41,11 @@ export default mergeConfig(
|
||||||
changeOrigin: true,
|
changeOrigin: true,
|
||||||
rewrite: (path: string) => path.replace(/^\/front\/bug\/attachment/, ''),
|
rewrite: (path: string) => path.replace(/^\/front\/bug\/attachment/, ''),
|
||||||
},
|
},
|
||||||
|
'/test-plan/report': {
|
||||||
|
target: process.env.VITE_DEV_DOMAIN,
|
||||||
|
changeOrigin: true,
|
||||||
|
rewrite: (path: string) => path.replace(/^\/front\/test-plan\/report/, ''),
|
||||||
|
},
|
||||||
'/plugin/image': {
|
'/plugin/image': {
|
||||||
target: process.env.VITE_DEV_DOMAIN,
|
target: process.env.VITE_DEV_DOMAIN,
|
||||||
changeOrigin: true,
|
changeOrigin: true,
|
||||||
|
|
|
@ -21,6 +21,7 @@
|
||||||
v-model:raw="innerTextForm.content"
|
v-model:raw="innerTextForm.content"
|
||||||
v-model:filedIds="innerTextForm.richTextTmpFileIds"
|
v-model:filedIds="innerTextForm.richTextTmpFileIds"
|
||||||
:upload-image="handleUploadImage"
|
:upload-image="handleUploadImage"
|
||||||
|
:preview-url="ReportPlanPreviewImageUrl"
|
||||||
class="mt-[8px] w-full"
|
class="mt-[8px] w-full"
|
||||||
:editable="props.canEdit"
|
:editable="props.canEdit"
|
||||||
@click="handleClick"
|
@click="handleClick"
|
||||||
|
@ -41,6 +42,7 @@
|
||||||
import MsRichText from '@/components/pure/ms-rich-text/MsRichText.vue';
|
import MsRichText from '@/components/pure/ms-rich-text/MsRichText.vue';
|
||||||
|
|
||||||
import { editorUploadFile } from '@/api/modules/test-plan/report';
|
import { editorUploadFile } from '@/api/modules/test-plan/report';
|
||||||
|
import { ReportPlanPreviewImageUrl } from '@/api/requrls/test-plan/report';
|
||||||
import useDoubleClick from '@/hooks/useDoubleClick';
|
import useDoubleClick from '@/hooks/useDoubleClick';
|
||||||
import { useI18n } from '@/hooks/useI18n';
|
import { useI18n } from '@/hooks/useI18n';
|
||||||
import { hasAnyPermission } from '@/utils/permission';
|
import { hasAnyPermission } from '@/utils/permission';
|
||||||
|
|
|
@ -186,12 +186,18 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
onMounted(() => {
|
watch(
|
||||||
|
[() => props.reportId, () => props.isPreview],
|
||||||
|
() => {
|
||||||
if (props.reportId && props.isPreview) {
|
if (props.reportId && props.isPreview) {
|
||||||
currentCaseTable.value.resetPagination();
|
currentCaseTable.value.resetPagination();
|
||||||
loadCaseList();
|
loadCaseList();
|
||||||
} else {
|
} else {
|
||||||
currentCaseTable.value.propsRes.value.data = detailTableExample[props.activeType];
|
currentCaseTable.value.propsRes.value.data = detailTableExample[props.activeType];
|
||||||
}
|
}
|
||||||
});
|
},
|
||||||
|
{
|
||||||
|
immediate: true,
|
||||||
|
}
|
||||||
|
);
|
||||||
</script>
|
</script>
|
||||||
|
|
|
@ -84,11 +84,17 @@
|
||||||
loadList();
|
loadList();
|
||||||
}
|
}
|
||||||
|
|
||||||
onMounted(() => {
|
watch(
|
||||||
|
[() => props.reportId, () => props.isPreview],
|
||||||
|
() => {
|
||||||
if (props.reportId && props.isPreview) {
|
if (props.reportId && props.isPreview) {
|
||||||
loadCaseList();
|
loadCaseList();
|
||||||
} else {
|
} else {
|
||||||
propsRes.value.data = detailTableExample[ReportCardTypeEnum.BUG_DETAIL];
|
propsRes.value.data = detailTableExample[ReportCardTypeEnum.BUG_DETAIL];
|
||||||
}
|
}
|
||||||
});
|
},
|
||||||
|
{
|
||||||
|
immediate: true,
|
||||||
|
}
|
||||||
|
);
|
||||||
</script>
|
</script>
|
||||||
|
|
|
@ -163,13 +163,19 @@
|
||||||
loadList();
|
loadList();
|
||||||
}
|
}
|
||||||
|
|
||||||
onMounted(() => {
|
watch(
|
||||||
|
[() => props.reportId, () => props.isPreview],
|
||||||
|
() => {
|
||||||
if (props.reportId && props.isPreview) {
|
if (props.reportId && props.isPreview) {
|
||||||
loadCaseList();
|
loadCaseList();
|
||||||
} else {
|
} else {
|
||||||
propsRes.value.data = detailTableExample[ReportCardTypeEnum.FUNCTIONAL_DETAIL];
|
propsRes.value.data = detailTableExample[ReportCardTypeEnum.FUNCTIONAL_DETAIL];
|
||||||
}
|
}
|
||||||
});
|
},
|
||||||
|
{
|
||||||
|
immediate: true,
|
||||||
|
}
|
||||||
|
);
|
||||||
|
|
||||||
const showDetailVisible = ref<boolean>(false);
|
const showDetailVisible = ref<boolean>(false);
|
||||||
|
|
||||||
|
|
|
@ -143,13 +143,19 @@
|
||||||
loadList();
|
loadList();
|
||||||
}
|
}
|
||||||
|
|
||||||
onMounted(() => {
|
watch(
|
||||||
|
[() => props.reportId, () => props.isPreview],
|
||||||
|
() => {
|
||||||
if (props.reportId && props.isPreview) {
|
if (props.reportId && props.isPreview) {
|
||||||
loadReportDetailList();
|
loadReportDetailList();
|
||||||
} else {
|
} else {
|
||||||
propsRes.value.data = detailTableExample[ReportCardTypeEnum.SUB_PLAN_DETAIL];
|
propsRes.value.data = detailTableExample[ReportCardTypeEnum.SUB_PLAN_DETAIL];
|
||||||
}
|
}
|
||||||
});
|
},
|
||||||
|
{
|
||||||
|
immediate: true,
|
||||||
|
}
|
||||||
|
);
|
||||||
|
|
||||||
const reportVisible = ref(false);
|
const reportVisible = ref(false);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue