fix(测试跟踪): 英文语境下,用例导入用例等级失败
This commit is contained in:
parent
d8d04062d1
commit
2e5b78016b
|
@ -402,6 +402,12 @@ public class TestCaseNoModelDataListener extends AnalysisEventListener<Map<Integ
|
||||||
if (TestCaseImportFiled.MAINTAINER.getFiledLangMap().containsValue(fieldName.replace("(ID)", StringUtils.EMPTY))) {
|
if (TestCaseImportFiled.MAINTAINER.getFiledLangMap().containsValue(fieldName.replace("(ID)", StringUtils.EMPTY))) {
|
||||||
fieldName = TestCaseImportFiled.MAINTAINER.getFiledLangMap().get(Locale.SIMPLIFIED_CHINESE); // 兼容旧模板的 责任人(ID)
|
fieldName = TestCaseImportFiled.MAINTAINER.getFiledLangMap().get(Locale.SIMPLIFIED_CHINESE); // 兼容旧模板的 责任人(ID)
|
||||||
}
|
}
|
||||||
|
if (TestCaseImportFiled.PRIORITY.getFiledLangMap().containsValue(fieldName)) {
|
||||||
|
fieldName = TestCaseImportFiled.PRIORITY.getFiledLangMap().get(Locale.SIMPLIFIED_CHINESE);
|
||||||
|
}
|
||||||
|
if (TestCaseImportFiled.STATUS.getFiledLangMap().containsValue(fieldName)) {
|
||||||
|
fieldName = TestCaseImportFiled.STATUS.getFiledLangMap().get(Locale.SIMPLIFIED_CHINESE);
|
||||||
|
}
|
||||||
CustomFieldDao customField = customFieldsMap.get(fieldName);
|
CustomFieldDao customField = customFieldsMap.get(fieldName);
|
||||||
if (customField == null) {
|
if (customField == null) {
|
||||||
continue;
|
continue;
|
||||||
|
@ -420,9 +426,9 @@ public class TestCaseNoModelDataListener extends AnalysisEventListener<Map<Integ
|
||||||
stringBuilder.append(e.getMessage().concat(ERROR_MSG_SEPARATOR));
|
stringBuilder.append(e.getMessage().concat(ERROR_MSG_SEPARATOR));
|
||||||
}
|
}
|
||||||
if (StringUtils.equals(fieldName, TestCaseImportFiled.STATUS.getFiledLangMap().get(Locale.SIMPLIFIED_CHINESE))) {
|
if (StringUtils.equals(fieldName, TestCaseImportFiled.STATUS.getFiledLangMap().get(Locale.SIMPLIFIED_CHINESE))) {
|
||||||
data.setStatus(customData.get(fieldName).toString());
|
data.setStatus(customData.get(originFieldName).toString());
|
||||||
} else if (StringUtils.equals(fieldName, TestCaseImportFiled.PRIORITY.getFiledLangMap().get(Locale.SIMPLIFIED_CHINESE))) {
|
} else if (StringUtils.equals(fieldName, TestCaseImportFiled.PRIORITY.getFiledLangMap().get(Locale.SIMPLIFIED_CHINESE))) {
|
||||||
data.setPriority(customData.get(fieldName).toString());
|
data.setPriority(customData.get(originFieldName).toString());
|
||||||
} else if (StringUtils.equals(fieldName, TestCaseImportFiled.MAINTAINER.getFiledLangMap().get(Locale.SIMPLIFIED_CHINESE))) {
|
} else if (StringUtils.equals(fieldName, TestCaseImportFiled.MAINTAINER.getFiledLangMap().get(Locale.SIMPLIFIED_CHINESE))) {
|
||||||
data.setMaintainer(customData.get(originFieldName).toString());
|
data.setMaintainer(customData.get(originFieldName).toString());
|
||||||
}
|
}
|
||||||
|
|
|
@ -314,7 +314,7 @@ import TestPlanCaseIssueItem from "@/business/plan/view/comonents/functional/Tes
|
||||||
import {
|
import {
|
||||||
getProjectMemberOption,
|
getProjectMemberOption,
|
||||||
getProjectVersions,
|
getProjectVersions,
|
||||||
getAdvSearchCustomField
|
getAdvSearchCustomField, parseTag
|
||||||
} from "@/business/utils/sdk-utils";
|
} from "@/business/utils/sdk-utils";
|
||||||
import {
|
import {
|
||||||
testPlanTestCaseBatchDelete,
|
testPlanTestCaseBatchDelete,
|
||||||
|
@ -628,13 +628,14 @@ export default {
|
||||||
this.total = r.data.itemCount;
|
this.total = r.data.itemCount;
|
||||||
this.pageCount = Math.ceil(this.total / this.pageSize);
|
this.pageCount = Math.ceil(this.total / this.pageSize);
|
||||||
this.tableData = r.data.listObject;
|
this.tableData = r.data.listObject;
|
||||||
|
parseTag(this.tableData);
|
||||||
parseCustomFilesForList(this.tableData);
|
parseCustomFilesForList(this.tableData);
|
||||||
for (let i = 0; i < this.tableData.length; i++) {
|
for (let i = 0; i < this.tableData.length; i++) {
|
||||||
if (this.tableData[i]) {
|
if (this.tableData[i]) {
|
||||||
if (this.tableData[i].customFields) {
|
if (this.tableData[i].customFields) {
|
||||||
this.tableData[i].customFields = JSON.parse(this.tableData[i].customFields);
|
this.tableData[i].customFields = JSON.parse(this.tableData[i].customFields);
|
||||||
}
|
}
|
||||||
this.$set(this.tableData[i], "showTags", JSON.parse(this.tableData[i].tags));
|
this.$set(this.tableData[i], "showTags", this.tableData[i].tags);
|
||||||
this.$set(this.tableData[i], "issuesSize", this.tableData[i].issuesCount);
|
this.$set(this.tableData[i], "issuesSize", this.tableData[i].issuesCount);
|
||||||
this.$set(this.tableData[i], "hasLoadIssue", false);
|
this.$set(this.tableData[i], "hasLoadIssue", false);
|
||||||
this.$set(this.tableData[i], "issuesContent", []);
|
this.$set(this.tableData[i], "issuesContent", []);
|
||||||
|
|
Loading…
Reference in New Issue