Commit 3027caa1d2dbf4290f5a611ab5eff3c699af602d
1 parent
832b36ac
feat:【iot】新增数据目的类型字段及其查询条件
Showing
2 changed files
with
6 additions
and
0 deletions
yudao-module-iot/yudao-module-iot-biz/src/main/java/cn/iocoder/yudao/module/iot/controller/admin/rule/vo/data/sink/IotDataSinkPageReqVO.java
| ... | ... | @@ -3,6 +3,7 @@ package cn.iocoder.yudao.module.iot.controller.admin.rule.vo.data.sink; |
| 3 | 3 | import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum; |
| 4 | 4 | import cn.iocoder.yudao.framework.common.pojo.PageParam; |
| 5 | 5 | import cn.iocoder.yudao.framework.common.validation.InEnum; |
| 6 | +import cn.iocoder.yudao.module.iot.enums.rule.IotDataSinkTypeEnum; | |
| 6 | 7 | import io.swagger.v3.oas.annotations.media.Schema; |
| 7 | 8 | import lombok.Data; |
| 8 | 9 | import org.springframework.format.annotation.DateTimeFormat; |
| ... | ... | @@ -22,6 +23,10 @@ public class IotDataSinkPageReqVO extends PageParam { |
| 22 | 23 | @InEnum(CommonStatusEnum.class) |
| 23 | 24 | private Integer status; |
| 24 | 25 | |
| 26 | + @Schema(description = "数据目的类型", example = "1") | |
| 27 | + @InEnum(IotDataSinkTypeEnum.class) | |
| 28 | + private Integer type; | |
| 29 | + | |
| 25 | 30 | @Schema(description = "创建时间") |
| 26 | 31 | @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND) |
| 27 | 32 | private LocalDateTime[] createTime; | ... | ... |
yudao-module-iot/yudao-module-iot-biz/src/main/java/cn/iocoder/yudao/module/iot/dal/mysql/rule/IotDataSinkMapper.java
| ... | ... | @@ -21,6 +21,7 @@ public interface IotDataSinkMapper extends BaseMapperX<IotDataSinkDO> { |
| 21 | 21 | return selectPage(reqVO, new LambdaQueryWrapperX<IotDataSinkDO>() |
| 22 | 22 | .likeIfPresent(IotDataSinkDO::getName, reqVO.getName()) |
| 23 | 23 | .eqIfPresent(IotDataSinkDO::getStatus, reqVO.getStatus()) |
| 24 | + .eqIfPresent(IotDataSinkDO::getType, reqVO.getType()) | |
| 24 | 25 | .betweenIfPresent(IotDataSinkDO::getCreateTime, reqVO.getCreateTime()) |
| 25 | 26 | .orderByDesc(IotDataSinkDO::getId)); |
| 26 | 27 | } | ... | ... |