fix(测试跟踪): 用例编辑页-自定义字段多选类型显示不正确

--bug=1025911 --user=陈建星 【测试跟踪】功能用例-自定义字段-复制的用例和原用例显示不一致 https://www.tapd.cn/55049933/s/1367705
This commit is contained in:
chenjianxing 2023-04-27 18:40:44 +08:00 committed by jianxing
parent eef3c9122a
commit c798e22036
3 changed files with 10 additions and 2 deletions

View File

@ -314,6 +314,10 @@ export default {
this.isCustomNone = false;
return this.contentObject.content.defaultValue;
}
} else if (['multipleInput'].indexOf(this.contentObject.content.type) > -1) {
if (this.contentObject.content.defaultValue && this.contentObject.content.defaultValue instanceof Array) {
return this.contentObject.content.defaultValue.join(' ');
}
}
if (!this.contentObject.content.defaultValue) {

View File

@ -390,7 +390,7 @@ import {
import {
getProjectListAll,
getProjectMemberOption,
getProjectMemberOption, parseCustomFilesForItem,
} from "@/business/utils/sdk-utils";
import { testCaseCommentList } from "@/api/test-case-comment";
import {
@ -1137,6 +1137,10 @@ export default {
this.form.maintainer = user.id;
}
testCase.fields.forEach(i => {
parseCustomFilesForItem(i);
});
//
this.customFieldForm = parseCustomField(
this.form,

View File

@ -1,6 +1,6 @@
export {operationConfirm, removeGoBackListener, handleCtrlSEvent, byteToSize, sizeToByte, resizeTextarea,
getTypeByFileName, strMapToObj, getUUID, windowPrint, parseTag} from "metersphere-frontend/src/utils";
export {parseCustomFilesForList, getCustomFieldFilter, buildBatchParam} from "metersphere-frontend/src/utils/tableUtils";
export {parseCustomFilesForList, getCustomFieldFilter, buildBatchParam, parseCustomFilesForItem} from "metersphere-frontend/src/utils/tableUtils";
export {sortCustomFields, parseCustomField, buildCustomFields} from "metersphere-frontend/src/utils/custom_field";
export {getCurrentProjectID, getCurrentWorkspaceId, getCurrentUser, setCurrentProjectID} from "metersphere-frontend/src/utils/token";
export {hasLicense, hasPermissions, hasPermission} from "metersphere-frontend/src/utils/permission";