fix: 【桌面版】api数据源全量更新-简单重复-更新记录为空

This commit is contained in:
taojinlong 2025-01-09 14:47:43 +08:00 committed by taojinlong
parent af4cc96737
commit cacf1e9eb1
2 changed files with 3 additions and 5 deletions

View File

@ -17,10 +17,8 @@ public interface ExtDatasourceTaskMapper {
@Select(
"""
SELECT core_datasource.name as datasource_name,core_datasource_task.* , QRTZ_TRIGGERS.NEXT_FIRE_TIME as NEXT_FIRE_TIME
FROM core_datasource_task
left join core_datasource on core_datasource.id=core_datasource_task.ds_id
left join QRTZ_TRIGGERS on core_datasource_task.id=QRTZ_TRIGGERS.TRIGGER_NAME
SELECT QRTZ_TRIGGERS.*
FROM QRTZ_TRIGGERS
${ew.customSqlSegment}
"""
)

View File

@ -126,7 +126,7 @@ public class DatasourceTaskServer {
public List<CoreDatasourceTaskDTO> taskWithTriggers(Long taskId) {
QueryWrapper<CoreDatasourceTaskDTO> wrapper = new QueryWrapper<>();
wrapper.eq("core_datasource_task.id", String.valueOf(taskId));
wrapper.eq("QRTZ_TRIGGERS.TRIGGER_NAME", String.valueOf(taskId));
return extDatasourceTaskMapper.taskWithTriggers(wrapper);
}