|
|
@ -1,5 +1,6 @@ |
|
|
|
package com.zc.business.service.impl; |
|
|
|
|
|
|
|
import com.alibaba.fastjson.JSON; |
|
|
|
import com.alibaba.fastjson.JSONArray; |
|
|
|
import com.alibaba.fastjson.JSONObject; |
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
|
|
@ -13,11 +14,14 @@ import com.zc.business.service.IDcBatchFunctionsJobGroupService; |
|
|
|
import com.zc.business.service.IDcBatchFunctionsJobService; |
|
|
|
import org.quartz.SchedulerException; |
|
|
|
import org.springframework.stereotype.Service; |
|
|
|
import org.springframework.transaction.annotation.Propagation; |
|
|
|
import org.springframework.transaction.annotation.Transactional; |
|
|
|
|
|
|
|
import javax.annotation.Resource; |
|
|
|
import java.util.ArrayList; |
|
|
|
import java.util.Date; |
|
|
|
import java.util.List; |
|
|
|
import java.util.Objects; |
|
|
|
|
|
|
|
/** |
|
|
|
* 定时任务组Service业务层处理 |
|
|
@ -134,5 +138,25 @@ public class DcBatchFunctionsJobGroupServiceImpl extends ServiceImpl<DcBatchFunc |
|
|
|
DcBatchFunctionsJobGroup dcBatchFunctionsJobGroup1 = editDcBatchFunctionsJobGroup(dcBatchFunctionsJobGroup); |
|
|
|
return dcBatchFunctionsJobGroup1 != null; |
|
|
|
} |
|
|
|
|
|
|
|
@Override |
|
|
|
@Transactional(propagation = Propagation.REQUIRED, rollbackFor = Exception.class) |
|
|
|
public DcBatchFunctionsJobGroup adddcBatchFunctionsJobGroupAnddcBatchFunctionsJob(DcBatchFunctionsJobGroup dcBatchFunctionsJobGroup) throws SchedulerException, TaskException { |
|
|
|
List<DcBatchFunctionsJob> dcBatchFunctionsJobList = dcBatchFunctionsJobGroup.getDcBatchFunctionsJobList(); |
|
|
|
DcBatchFunctionsJobGroup dcBatchFunctionsJobGroup1 = addDcBatchFunctionsJobGroup(dcBatchFunctionsJobGroup); |
|
|
|
if (dcBatchFunctionsJobGroup1 == null) { |
|
|
|
throw new NullPointerException(); |
|
|
|
} |
|
|
|
for (DcBatchFunctionsJob job : dcBatchFunctionsJobList) { |
|
|
|
|
|
|
|
job.setJobGroup(String.valueOf(dcBatchFunctionsJobGroup1.getId())); |
|
|
|
|
|
|
|
DcBatchFunctionsJob dcBatchFunctionsJob = dcBatchFunctionsJobService.addDcBatchFunctionsJob(job); |
|
|
|
if (dcBatchFunctionsJob == null) { |
|
|
|
throw new NullPointerException(); |
|
|
|
} |
|
|
|
} |
|
|
|
return dcBatchFunctionsJobGroup1; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|