|
|
@@ -2,13 +2,13 @@ package cn.iocoder.yudao.module.iscs.job;
|
|
|
|
|
|
import cn.hutool.core.date.DateUtil;
|
|
|
import cn.iocoder.yudao.framework.quartz.core.handler.JobHandler;
|
|
|
-import cn.iocoder.yudao.framework.tenant.core.aop.TenantIgnore;
|
|
|
-import cn.iocoder.yudao.framework.tenant.core.util.TenantUtils;
|
|
|
+import cn.iocoder.yudao.framework.tenant.core.job.TenantJob;
|
|
|
import cn.iocoder.yudao.module.iscs.controller.admin.jobticket.vo.JobTicketSaveReqVO;
|
|
|
import cn.iocoder.yudao.module.iscs.controller.admin.sop.vo.SopExecutionPlanRespVO;
|
|
|
import cn.iocoder.yudao.module.iscs.dal.dataobject.jobticket.JobTicketDO;
|
|
|
import cn.iocoder.yudao.module.iscs.service.jobticket.JobTicketService;
|
|
|
import cn.iocoder.yudao.module.iscs.service.sop.SopExecutionPlanService;
|
|
|
+import cn.iocoder.yudao.module.system.service.user.AdminUserService;
|
|
|
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
|
|
import jakarta.annotation.Resource;
|
|
|
import lombok.extern.slf4j.Slf4j;
|
|
|
@@ -32,6 +32,8 @@ public class SopExecutionPlanJob implements JobHandler {
|
|
|
private SopExecutionPlanService sopExecutionPlanService;
|
|
|
@Resource
|
|
|
private JobTicketService jobTicketService;
|
|
|
+ @Resource
|
|
|
+ private AdminUserService adminUserService;
|
|
|
|
|
|
/**
|
|
|
* 查找需要执行的数据,生成作业
|
|
|
@@ -39,11 +41,15 @@ public class SopExecutionPlanJob implements JobHandler {
|
|
|
* @param param 参数
|
|
|
* @return
|
|
|
*/
|
|
|
-
|
|
|
+ // @TenantIgnore
|
|
|
@Override
|
|
|
- @TenantIgnore
|
|
|
+ @TenantJob
|
|
|
public String execute(String param) {
|
|
|
- TenantUtils.execute(1L, () -> {});
|
|
|
+ /*TenantUtils.execute(1L, () -> {
|
|
|
+ AdminUserRespDTO user = new AdminUserRespDTO();
|
|
|
+ user.setId(0L);
|
|
|
+ return BeanUtils.toBean(user, Response.class);
|
|
|
+ });*/
|
|
|
String yyyymmdd = DateUtil.format(new Date(), "yyyy-MM-dd");
|
|
|
SopExecutionPlanRespVO sopExecutionPlanRespVO = new SopExecutionPlanRespVO();
|
|
|
sopExecutionPlanRespVO.setNextExecutDate(yyyymmdd);
|