fix(测试跟踪): 关联Jira平台使用默认模板修改平台状态报错问题

--bug=1017192 --user=宋昌昌 【测试跟踪】缺陷管理-关联Jira平台-修改平台状态报500 https://www.tapd.cn/55049933/s/1250456
This commit is contained in:
song-cc-rock 2022-09-22 16:10:10 +08:00 committed by jianxing
parent 555e14dc28
commit d15f7001cb
1 changed files with 9 additions and 7 deletions

View File

@ -934,13 +934,15 @@ public class JiraPlatform extends AbstractIssuePlatform {
// 获取富文本图片附件名称 // 获取富文本图片附件名称
List<CustomFieldItemDTO> richTexts = request.getRequestFields().stream().filter(item -> item.getType().equals("richText")).collect(Collectors.toList()); List<CustomFieldItemDTO> richTexts = request.getRequestFields().stream().filter(item -> item.getType().equals("richText")).collect(Collectors.toList());
richTexts.forEach(richText -> { richTexts.forEach(richText -> {
String url = richText.getValue().toString(); if (richText.getValue() != null) {
if (url.contains("fileName")) { String url = richText.getValue().toString();
// 本地上传的图片URL if (url.contains("fileName")) {
msFileNames.add(url.substring(url.indexOf("=") + 1, url.lastIndexOf(")"))); // 本地上传的图片URL
} else if (url.contains("platform=Jira")) { msFileNames.add(url.substring(url.indexOf("=") + 1, url.lastIndexOf(")")));
// Jira同步的图片URL } else if (url.contains("platform=Jira")) {
msFileNames.add(url.substring(url.indexOf("[") + 1, url.indexOf("]"))); // Jira同步的图片URL
msFileNames.add(url.substring(url.indexOf("[") + 1, url.indexOf("]")));
}
} }
}); });