记得上下班打卡 | git大法好,push需谨慎

Commit 7b785c0a authored by wanglele's avatar wanglele

定时任务

parent 237302b9
......@@ -8,5 +8,5 @@ public interface IGoblinNftExCodeTaskService {
/**
* 定时生成兑换码
*/
ResponseDto<Boolean> generateCode();
ResponseDto<String> generateCode();
}
......@@ -24,7 +24,7 @@ public class GoblinNftExCodeTaskController {
@PostMapping("generateCode")
@ApiOperation(value = "定时自动生成兑换码")
public ResponseDto<Boolean> generateCode(){
public ResponseDto<String> generateCode(){
return iGoblinNftExCodeTaskService.generateCode();
}
}
......@@ -42,7 +42,7 @@ public class GoblinNftExCodeTaskServiceImpl implements IGoblinNftExCodeTaskServi
@Override
@Transactional(rollbackFor = Exception.class)
public ResponseDto<Boolean> generateCode() {
public ResponseDto<String> generateCode() {
/**
* 获取所有定时任务列表
......@@ -50,7 +50,7 @@ public class GoblinNftExCodeTaskServiceImpl implements IGoblinNftExCodeTaskServi
List<GoblinNftExCodeTask> goblinNftExCodeTasks = goblinNftExCodeTaskMapper.selectByActivity();
if (goblinNftExCodeTasks == null || goblinNftExCodeTasks.size() <= 0) {
return ResponseDto.success(true);
return ResponseDto.success("0");
}
......@@ -228,7 +228,7 @@ public class GoblinNftExCodeTaskServiceImpl implements IGoblinNftExCodeTaskServi
goblinNftExCodeTaskMapper.updateByTaskIds(updTaskIds.toString());
log.debug("MSQ耗时:ms", System.currentTimeMillis() - startm);
return ResponseDto.success(true);
return ResponseDto.success("操作成功!");
}
public static void main(String[] args) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment