fix: 性能测试报告链接id修改
This commit is contained in:
parent
f5036e85c9
commit
bd13c3ccb1
|
@ -42,12 +42,12 @@ public class MailService {
|
|||
@Resource
|
||||
private SystemParameterService systemParameterService;
|
||||
|
||||
public void sendPerformanceNotification(List<NoticeDetail> noticeList, String status, LoadTestWithBLOBs loadTest) {
|
||||
public void sendPerformanceNotification(List<NoticeDetail> noticeList, String status, LoadTestWithBLOBs loadTest, String id) {
|
||||
BaseSystemConfigDTO baseSystemConfigDTO = systemParameterService.getBaseInfo();
|
||||
Map<String, String> context = new HashMap<>();
|
||||
context.put("title", "Performance" + Translator.get("timing_task_result_notification"));
|
||||
context.put("testName", loadTest.getName());
|
||||
context.put("id", loadTest.getId());
|
||||
context.put("id", id);
|
||||
context.put("type", "performance");
|
||||
context.put("url", baseSystemConfigDTO.getUrl());
|
||||
String performanceTemplate = "";
|
||||
|
|
|
@ -242,7 +242,7 @@ public class PerformanceTestService {
|
|||
if (request.getTriggerMode().equals("SCHEDULE")) {
|
||||
try {
|
||||
noticeList = noticeService.queryNotice(loadTest.getId());
|
||||
mailService.sendPerformanceNotification(noticeList, PerformanceTestStatus.Completed.name(), loadTest);
|
||||
mailService.sendPerformanceNotification(noticeList, PerformanceTestStatus.Completed.name(), loadTest, engine.getReportId());
|
||||
} catch (Exception e) {
|
||||
LogUtil.error(e.getMessage(), e);
|
||||
}
|
||||
|
@ -321,7 +321,7 @@ public class PerformanceTestService {
|
|||
loadTestMapper.updateByPrimaryKeySelective(loadTest);
|
||||
if (triggerMode.equals("SCHEDULE")) {
|
||||
noticeList = noticeService.queryNotice(loadTest.getId());
|
||||
mailService.sendPerformanceNotification(noticeList, loadTest.getStatus(), loadTest);
|
||||
mailService.sendPerformanceNotification(noticeList, loadTest.getStatus(), loadTest, loadTest.getId());
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
|
@ -449,7 +449,7 @@ public class PerformanceTestService {
|
|||
if (loadTestReport.getTriggerMode().equals("SCHEDULE")) {
|
||||
try {
|
||||
noticeList = noticeService.queryNotice(loadTest.getId());
|
||||
mailService.sendPerformanceNotification(noticeList, loadTestReport.getStatus(), loadTest);
|
||||
mailService.sendPerformanceNotification(noticeList, loadTestReport.getStatus(), loadTest, loadTestReport.getId());
|
||||
} catch (Exception e) {
|
||||
LogUtil.error(e.getMessage(), e);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue