fix(测试跟踪): 编辑用例控制台报错

This commit is contained in:
chenjianxing 2023-03-17 10:23:52 +08:00 committed by jianxing
parent 976c975ccf
commit 6545ce43a9
2 changed files with 21 additions and 20 deletions

View File

@ -135,6 +135,7 @@
<script> <script>
import { getProjectMemberOption } from "metersphere-frontend/src/api/user"; import { getProjectMemberOption } from "metersphere-frontend/src/api/user";
import MsMarkDownText from "@/business/case/components/richtext/MsMarkDownText"; import MsMarkDownText from "@/business/case/components/richtext/MsMarkDownText";
import {getProjectMemberById} from "@/api/user";
export default { export default {
name: "BaseEditItemComponent", name: "BaseEditItemComponent",
components: {MsMarkDownText}, components: {MsMarkDownText},
@ -220,14 +221,14 @@ export default {
methods: { methods: {
getMemberOptions() { getMemberOptions() {
if (this.projectId) { if (this.projectId) {
getProjectMemberById(this.projectId).then((r) => { getProjectMemberById(this.projectId)
this.handelMemberOptions(r.data); .then(r => this.handleMemberOptions(r.data));
});
} else { } else {
this.handelMemberOptions(r.data); getProjectMemberOption()
.then(r => this.handleMemberOptions(r.data));
} }
}, },
handelMemberOptions(data) { handleMemberOptions(data) {
let tempMemberOptions = data || []; let tempMemberOptions = data || [];
let tempArr = []; let tempArr = [];
tempMemberOptions.forEach((e) => { tempMemberOptions.forEach((e) => {

View File

@ -76,22 +76,22 @@
</div> </div>
</template> </template>
</ms-table-column> </ms-table-column>
</ms-table>
<ms-table-column <ms-table-column
width="150px" width="150px"
v-if="relationshipType === 'POST'" v-if="relationshipType === 'POST'"
:label="$t('commons.relationship.type')" :label="$t('commons.relationship.type')"
> >
<template> <template>
<div class="pos-label"> <div class="pos-label">
{{ $t("commons.relationship.current_case") }} {{ $t("commons.relationship.current_case") }}
</div> </div>
<div class="pos-type pos-left-margin"> <div class="pos-type pos-left-margin">
{{ $t("commons.relationship.after_finish") }} {{ $t("commons.relationship.after_finish") }}
</div> </div>
</template> </template>
</ms-table-column> </ms-table-column>
</ms-table>
<relationship-functional-relevance <relationship-functional-relevance
:case-id="caseId" :case-id="caseId"