mirror of
https://gitee.com/beecue/fastbee.git
synced 2025-12-17 16:36:03 +08:00
feat(支持springboot3): 支持springboot3框架
This commit is contained in:
@@ -1,13 +1,9 @@
|
||||
package com.fastbee.data.controller;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
|
||||
import com.fastbee.common.core.domain.entity.SysRole;
|
||||
import com.fastbee.common.core.domain.entity.SysUser;
|
||||
import com.fastbee.common.core.page.TableDataInfo;
|
||||
import com.fastbee.iot.model.IdAndName;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
@@ -30,7 +26,7 @@ import com.fastbee.common.utils.poi.ExcelUtil;
|
||||
|
||||
/**
|
||||
* 产品分类Controller
|
||||
*
|
||||
*
|
||||
* @author kerwincui
|
||||
* @date 2021-12-16
|
||||
*/
|
||||
|
||||
@@ -17,7 +17,7 @@ import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
|
||||
@@ -17,12 +17,12 @@ import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 调度任务信息操作处理
|
||||
*
|
||||
*
|
||||
* @author kerwincui
|
||||
*/
|
||||
@Api(tags = "调度任务信息操作处理模块")
|
||||
|
||||
@@ -1,13 +1,8 @@
|
||||
package com.fastbee.data.controller;
|
||||
|
||||
import com.fastbee.common.annotation.Log;
|
||||
import com.fastbee.common.core.controller.BaseController;
|
||||
import com.fastbee.common.core.domain.AjaxResult;
|
||||
import com.fastbee.common.core.page.TableDataInfo;
|
||||
import com.fastbee.common.enums.BusinessType;
|
||||
import com.fastbee.common.utils.poi.ExcelUtil;
|
||||
import com.fastbee.iot.domain.DeviceLog;
|
||||
import com.fastbee.iot.model.HistoryModel;
|
||||
import com.fastbee.iot.model.MonitorModel;
|
||||
import com.fastbee.iot.service.IDeviceLogService;
|
||||
import io.swagger.annotations.Api;
|
||||
@@ -16,9 +11,7 @@ import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 设备日志Controller
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
package com.fastbee.data.controller;
|
||||
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
|
||||
import com.fastbee.iot.domain.EventLog;
|
||||
import io.swagger.annotations.Api;
|
||||
@@ -26,7 +26,7 @@ import com.fastbee.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 事件日志Controller
|
||||
*
|
||||
*
|
||||
* @author kerwincui
|
||||
* @date 2023-03-28
|
||||
*/
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
package com.fastbee.data.controller;
|
||||
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
@@ -26,7 +26,7 @@ import com.fastbee.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 设备服务下发日志Controller
|
||||
*
|
||||
*
|
||||
* @author kerwincui
|
||||
* @date 2022-10-22
|
||||
*/
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
package com.fastbee.data.controller;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
|
||||
import com.fastbee.iot.domain.DeviceGroup;
|
||||
import com.fastbee.iot.model.DeviceGroupInput;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
@@ -29,7 +27,7 @@ import com.fastbee.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 设备分组Controller
|
||||
*
|
||||
*
|
||||
* @author kerwincui
|
||||
* @date 2021-12-16
|
||||
*/
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
package com.fastbee.data.controller;
|
||||
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
|
||||
import com.fastbee.iot.model.IdAndName;
|
||||
import io.swagger.annotations.Api;
|
||||
@@ -27,7 +27,7 @@ import com.fastbee.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 新闻分类Controller
|
||||
*
|
||||
*
|
||||
* @author kerwincui
|
||||
* @date 2022-04-09
|
||||
*/
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
package com.fastbee.data.controller;
|
||||
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
|
||||
import com.fastbee.iot.model.CategoryNews;
|
||||
import io.swagger.annotations.Api;
|
||||
@@ -27,7 +27,7 @@ import com.fastbee.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 新闻资讯Controller
|
||||
*
|
||||
*
|
||||
* @author kerwincui
|
||||
* @date 2022-04-09
|
||||
*/
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
package com.fastbee.data.controller;
|
||||
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
@@ -26,7 +26,7 @@ import com.fastbee.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 云云对接Controller
|
||||
*
|
||||
*
|
||||
* @author kerwincui
|
||||
* @date 2022-02-07
|
||||
*/
|
||||
|
||||
@@ -1,12 +1,11 @@
|
||||
package com.fastbee.data.controller;
|
||||
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
|
||||
import com.fastbee.iot.model.ProductAuthorizeVO;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.apache.poi.ss.formula.functions.T;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
@@ -21,7 +20,7 @@ import com.fastbee.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 产品授权码Controller
|
||||
*
|
||||
*
|
||||
* @author kami
|
||||
* @date 2022-04-11
|
||||
*/
|
||||
|
||||
@@ -16,7 +16,7 @@ import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
|
||||
@@ -15,7 +15,7 @@ import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
|
||||
@@ -12,7 +12,7 @@ import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
|
||||
@@ -11,8 +11,8 @@ import me.zhyd.oauth.model.AuthCallback;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import jakarta.servlet.http.HttpServletRequest;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import java.io.IOException;
|
||||
|
||||
/**
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
package com.fastbee.data.controller;
|
||||
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
|
||||
@@ -5,7 +5,6 @@ import com.fastbee.common.core.controller.BaseController;
|
||||
import com.fastbee.common.core.domain.AjaxResult;
|
||||
import com.fastbee.common.core.page.TableDataInfo;
|
||||
import com.fastbee.common.enums.BusinessType;
|
||||
import com.fastbee.common.utils.StringUtils;
|
||||
import com.fastbee.common.utils.poi.ExcelUtil;
|
||||
import com.fastbee.iot.domain.ThingsModel;
|
||||
import com.fastbee.iot.model.ImportThingsModelInput;
|
||||
@@ -19,13 +18,12 @@ import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.util.Arrays;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 物模型Controller
|
||||
*
|
||||
*
|
||||
* @author kerwincui
|
||||
* @date 2021-12-16
|
||||
*/
|
||||
|
||||
@@ -1,12 +1,8 @@
|
||||
package com.fastbee.data.controller;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
|
||||
import com.fastbee.common.core.domain.entity.SysRole;
|
||||
import com.fastbee.common.core.domain.entity.SysUser;
|
||||
import com.fastbee.iot.domain.ThingsModel;
|
||||
import com.fastbee.iot.domain.VarTemp;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
|
||||
@@ -44,9 +44,9 @@ import org.springframework.http.ResponseEntity;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import jakarta.annotation.Resource;
|
||||
import jakarta.servlet.http.HttpServletRequest;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import java.io.ByteArrayOutputStream;
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
|
||||
@@ -14,7 +14,7 @@ import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import jakarta.annotation.Resource;
|
||||
|
||||
/**
|
||||
* 首页面板和大屏数据
|
||||
|
||||
@@ -14,7 +14,7 @@ import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@@ -14,7 +14,7 @@ import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
|
||||
@@ -17,7 +17,7 @@ import org.springframework.http.MediaType;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
|
||||
@@ -15,7 +15,7 @@ import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import jakarta.annotation.Resource;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
package com.fastbee.data.controller.protocol;
|
||||
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
@@ -26,7 +26,7 @@ import com.fastbee.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 协议Controller
|
||||
*
|
||||
*
|
||||
* @author kerwincui
|
||||
* @date 2022-12-07
|
||||
*/
|
||||
|
||||
@@ -5,7 +5,6 @@ import com.fastbee.common.core.controller.BaseController;
|
||||
import com.fastbee.common.core.domain.AjaxResult;
|
||||
import com.fastbee.common.core.mq.InvokeReqDto;
|
||||
import com.fastbee.common.core.page.TableDataInfo;
|
||||
import com.fastbee.common.core.redis.RedisCache;
|
||||
import com.fastbee.common.enums.ThingsModelType;
|
||||
import com.fastbee.common.exception.ServiceException;
|
||||
import com.fastbee.common.utils.StringUtils;
|
||||
@@ -19,10 +18,9 @@ import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import javax.validation.Valid;
|
||||
import jakarta.annotation.Resource;
|
||||
import jakarta.validation.Valid;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 设备运行时数据controller
|
||||
|
||||
@@ -16,9 +16,9 @@ import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import jakarta.annotation.Resource;
|
||||
import jakarta.servlet.http.HttpServletRequest;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import java.io.IOException;
|
||||
|
||||
/**
|
||||
|
||||
@@ -19,7 +19,7 @@ import org.springframework.beans.factory.annotation.Value;
|
||||
import org.springframework.stereotype.Component;
|
||||
import org.springframework.util.CollectionUtils;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import jakarta.annotation.Resource;
|
||||
import java.util.List;
|
||||
import java.util.Objects;
|
||||
|
||||
|
||||
@@ -5,8 +5,6 @@ import com.fastbee.common.exception.job.TaskException;
|
||||
import com.fastbee.iot.domain.DeviceJob;
|
||||
import com.fastbee.iot.mapper.DeviceJobMapper;
|
||||
import com.fastbee.iot.service.IDeviceJobService;
|
||||
import com.fastbee.iot.service.IDeviceService;
|
||||
import com.fastbee.iot.service.cache.IDeviceCache;
|
||||
import com.fastbee.data.quartz.CronUtils;
|
||||
import com.fastbee.data.quartz.ScheduleUtils;
|
||||
import com.fastbee.quartz.domain.SysJob;
|
||||
@@ -17,17 +15,16 @@ import org.quartz.JobKey;
|
||||
import org.quartz.Scheduler;
|
||||
import org.quartz.SchedulerException;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.context.annotation.Lazy;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import javax.annotation.PostConstruct;
|
||||
import javax.annotation.Resource;
|
||||
import jakarta.annotation.PostConstruct;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 定时任务调度信息 服务层
|
||||
*
|
||||
*
|
||||
* @author kerwincui
|
||||
*/
|
||||
@Service
|
||||
@@ -68,7 +65,7 @@ public class DeviceJobServiceImpl implements IDeviceJobService
|
||||
|
||||
/**
|
||||
* 获取quartz调度器的计划任务列表
|
||||
*
|
||||
*
|
||||
* @param job 调度信息
|
||||
* @return
|
||||
*/
|
||||
@@ -80,7 +77,7 @@ public class DeviceJobServiceImpl implements IDeviceJobService
|
||||
|
||||
/**
|
||||
* 通过调度任务ID查询调度信息
|
||||
*
|
||||
*
|
||||
* @param jobId 调度任务ID
|
||||
* @return 调度任务对象信息
|
||||
*/
|
||||
@@ -92,7 +89,7 @@ public class DeviceJobServiceImpl implements IDeviceJobService
|
||||
|
||||
/**
|
||||
* 暂停任务
|
||||
*
|
||||
*
|
||||
* @param job 调度信息
|
||||
*/
|
||||
@Override
|
||||
@@ -112,7 +109,7 @@ public class DeviceJobServiceImpl implements IDeviceJobService
|
||||
|
||||
/**
|
||||
* 恢复任务
|
||||
*
|
||||
*
|
||||
* @param job 调度信息
|
||||
*/
|
||||
@Override
|
||||
@@ -132,7 +129,7 @@ public class DeviceJobServiceImpl implements IDeviceJobService
|
||||
|
||||
/**
|
||||
* 删除任务后,所对应的trigger也将被删除
|
||||
*
|
||||
*
|
||||
* @param job 调度信息
|
||||
*/
|
||||
@Override
|
||||
@@ -151,7 +148,7 @@ public class DeviceJobServiceImpl implements IDeviceJobService
|
||||
|
||||
/**
|
||||
* 批量删除调度信息
|
||||
*
|
||||
*
|
||||
* @param jobIds 需要删除的任务ID
|
||||
* @return 结果
|
||||
*/
|
||||
@@ -228,7 +225,7 @@ public class DeviceJobServiceImpl implements IDeviceJobService
|
||||
|
||||
/**
|
||||
* 任务调度状态修改
|
||||
*
|
||||
*
|
||||
* @param job 调度信息
|
||||
*/
|
||||
@Override
|
||||
@@ -250,7 +247,7 @@ public class DeviceJobServiceImpl implements IDeviceJobService
|
||||
|
||||
/**
|
||||
* 立即运行任务
|
||||
*
|
||||
*
|
||||
* @param job 调度信息
|
||||
*/
|
||||
@Override
|
||||
@@ -268,7 +265,7 @@ public class DeviceJobServiceImpl implements IDeviceJobService
|
||||
|
||||
/**
|
||||
* 新增任务
|
||||
*
|
||||
*
|
||||
* @param deviceJob 调度信息 调度信息
|
||||
*/
|
||||
@Override
|
||||
@@ -285,7 +282,7 @@ public class DeviceJobServiceImpl implements IDeviceJobService
|
||||
|
||||
/**
|
||||
* 更新任务的时间表达式
|
||||
*
|
||||
*
|
||||
* @param deviceJob 调度信息
|
||||
*/
|
||||
@Override
|
||||
@@ -303,7 +300,7 @@ public class DeviceJobServiceImpl implements IDeviceJobService
|
||||
|
||||
/**
|
||||
* 更新任务
|
||||
*
|
||||
*
|
||||
* @param deviceJob 任务对象
|
||||
* @param jobGroup 任务组名
|
||||
*/
|
||||
@@ -322,7 +319,7 @@ public class DeviceJobServiceImpl implements IDeviceJobService
|
||||
|
||||
/**
|
||||
* 校验cron表达式是否有效
|
||||
*
|
||||
*
|
||||
* @param cronExpression 表达式
|
||||
* @return 结果
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user