初次提交

This commit is contained in:
李玉东 2025-09-14 22:48:02 +08:00
parent 01007c1279
commit 0601bc932a

View File

@ -71,13 +71,15 @@ public class ScenarioTaskServiceImpl extends
//查询天气数据
WeatherResource weatherList = weatherResourceService.getOne(new QueryWrapper<WeatherResource>()
.eq("scenario_id",id));
// currentScenario.getGuid());
//放入天气数据
redisUtil.hset(roomId + "_" + id, "weather", weatherList.getWeatherType());
if(weatherList!=null){
//放入天气数据
redisUtil.hset(roomId + "_" + id, "weather", weatherList);
}
//查询任务
ScenarioTask queryTask = new ScenarioTask();
queryTask.setScenarioId(id);
redisUtil.hset(roomId + "_" + id, "taskList", queryTaskList(queryTask).get(0).getTaskType());
redisUtil.hset(roomId + "_" + id, "taskList", queryTaskList(queryTask));
new Thread(() -> {
springGlobalTaskManager.startPerSecondTask(roomId + "_" + id + "_task", () -> {