|
|
@@ -4,12 +4,11 @@ import com.railway.common.utils.SecurityUtils;
|
|
|
import com.railway.system.domain.SysScheduledTask;
|
|
|
import com.railway.system.mapper.SysScheduledTaskMapper;
|
|
|
import com.railway.system.service.ISysScheduledTaskService;
|
|
|
+import java.time.LocalDateTime;
|
|
|
+import java.util.List;
|
|
|
import org.springframework.stereotype.Service;
|
|
|
import org.springframework.transaction.annotation.Transactional;
|
|
|
|
|
|
-import java.util.Date;
|
|
|
-import java.util.List;
|
|
|
-
|
|
|
/**
|
|
|
* 系统计划任务表
|
|
|
*
|
|
|
@@ -32,7 +31,7 @@ public class SysScheduledTaskServiceImpl implements ISysScheduledTaskService {
|
|
|
@Override
|
|
|
@Transactional(rollbackFor = Exception.class)
|
|
|
public int create(SysScheduledTask sysScheduledTask) {
|
|
|
- sysScheduledTask.setCreateTime(new Date());
|
|
|
+ sysScheduledTask.setCreateTime(LocalDateTime.now());
|
|
|
sysScheduledTask.setCreateBy(SecurityUtils.getUserIdString());
|
|
|
return sysScheduledTaskMapper.insert(sysScheduledTask);
|
|
|
}
|
|
|
@@ -57,7 +56,7 @@ public class SysScheduledTaskServiceImpl implements ISysScheduledTaskService {
|
|
|
@Override
|
|
|
@Transactional(rollbackFor = Exception.class)
|
|
|
public int update(SysScheduledTask sysScheduledTask) {
|
|
|
- sysScheduledTask.setUpdateTime(new Date());
|
|
|
+ sysScheduledTask.setUpdateTime(LocalDateTime.now());
|
|
|
sysScheduledTask.setUpdateBy(SecurityUtils.getUserIdString());
|
|
|
return sysScheduledTaskMapper.update(sysScheduledTask);
|
|
|
}
|