fix(测试用例): 导出excel增加编辑类型
This commit is contained in:
parent
8547743f36
commit
f26372a899
|
@ -284,6 +284,7 @@ case.export.system.other.columns.create_user=Create user
|
|||
case.export.system.other.columns.create_time=Create time
|
||||
case.export.system.other.columns.update_user=Update user
|
||||
case.export.system.other.columns.update_time=Update time
|
||||
case.export.columns.case_edit_type=Edit type
|
||||
|
||||
export_case_task_stop=Stop export
|
||||
export_case_task_existed=Export task already exists
|
|
@ -281,6 +281,7 @@ case.export.system.other.columns.create_user=创建人
|
|||
case.export.system.other.columns.create_time=创建时间
|
||||
case.export.system.other.columns.update_user=更新人
|
||||
case.export.system.other.columns.update_time=更新时间
|
||||
case.export.columns.case_edit_type=编辑模式
|
||||
|
||||
export_case_task_stop=停止导出
|
||||
export_case_task_existed=已有导出任务
|
|
@ -285,6 +285,7 @@ case.export.system.other.columns.create_user=創建人
|
|||
case.export.system.other.columns.create_time=創建時間
|
||||
case.export.system.other.columns.update_user=更新人
|
||||
case.export.system.other.columns.update_time=更新時間
|
||||
case.export.columns.case_edit_type=編輯模式
|
||||
|
||||
export_case_task_stop=停止導出
|
||||
export_case_task_existed=已有導出任務
|
|
@ -625,13 +625,13 @@ public class FunctionalCaseFileService {
|
|||
private void buildBaseField(FunctionalCaseExcelData data, FunctionalCase functionalCase, FunctionalCaseBlob functionalCaseBlob, Map<String, String> moduleMap, List<String> textDescriptionList, List<String> expectedResultList, String url) {
|
||||
data.setNum(functionalCase.getNum().toString());
|
||||
data.setModule(moduleMap.get(functionalCase.getModuleId()));
|
||||
data.setTags(functionalCase.getTags().toString());
|
||||
//构建步骤
|
||||
buildExportStep(data, functionalCaseBlob, functionalCase.getCaseEditType(), textDescriptionList, expectedResultList);
|
||||
data.setPrerequisite(new String(functionalCaseBlob.getPrerequisite() == null ? new byte[0] : functionalCaseBlob.getPrerequisite(), StandardCharsets.UTF_8));
|
||||
|
||||
//标签
|
||||
data.setTags(JSON.toJSONString(functionalCase.getTags()));
|
||||
data.setCaseEditType(functionalCase.getCaseEditType());
|
||||
// 设置超链接
|
||||
WriteCellData<String> hyperlink = new WriteCellData<>(functionalCase.getName());
|
||||
data.setHyperLinkName(hyperlink);
|
||||
|
@ -874,6 +874,10 @@ public class FunctionalCaseFileService {
|
|||
.collect(Collectors.toList()));
|
||||
}
|
||||
};
|
||||
List<FunctionalCaseHeader> textDescription = request.getSystemFields().stream().filter(item -> StringUtils.equals(item.getId(), "text_description")).toList();
|
||||
if (CollectionUtils.isNotEmpty(textDescription)) {
|
||||
headList.add(Arrays.asList(Translator.get("case.export.columns.case_edit_type")));
|
||||
}
|
||||
return headList;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue