From 849c3bfad21a3821f303413f82cda2d8d4d27733 Mon Sep 17 00:00:00 2001
From: dongyukun <1208714201@qq.com>
Date: 星期二, 05 十一月 2024 18:41:31 +0800
Subject: [PATCH] tag查当前值

---
 iailab-module-data/iailab-module-data-biz/src/main/java/com/iailab/module/data/channel/modbus/dao/ChannelModBusTagDao.java |   24 +++++++++++++++++-------
 1 files changed, 17 insertions(+), 7 deletions(-)

diff --git a/iailab-module-data/iailab-module-data-biz/src/main/java/com/iailab/module/data/channel/modbus/dao/ChannelModBusTagDao.java b/iailab-module-data/iailab-module-data-biz/src/main/java/com/iailab/module/data/channel/modbus/dao/ChannelModBusTagDao.java
index 72297e7..250e613 100644
--- a/iailab-module-data/iailab-module-data-biz/src/main/java/com/iailab/module/data/channel/modbus/dao/ChannelModBusTagDao.java
+++ b/iailab-module-data/iailab-module-data-biz/src/main/java/com/iailab/module/data/channel/modbus/dao/ChannelModBusTagDao.java
@@ -1,21 +1,31 @@
 package com.iailab.module.data.channel.modbus.dao;
 
-import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.iailab.framework.common.pojo.PageResult;
+import com.iailab.framework.mybatis.core.mapper.BaseMapperX;
+import com.iailab.framework.mybatis.core.query.LambdaQueryWrapperX;
+import com.iailab.framework.tenant.core.db.dynamic.TenantDS;
 import com.iailab.module.data.channel.modbus.entity.ChannelModBusTagEntity;
+import com.iailab.module.data.channel.modbus.vo.ModBusTagPageReqVO;
 import org.apache.ibatis.annotations.Mapper;
 import org.apache.ibatis.annotations.Param;
 
 import java.util.List;
 
 /**
- * @author DongYukun
+ * @author lirm
  * @Description
- * @createTime 2023年04月25日 15:12:00
+ * @createTime 2024年08月27日
  */
+@TenantDS
 @Mapper
-public interface ChannelModBusTagDao extends BaseMapper<ChannelModBusTagEntity> {
+public interface ChannelModBusTagDao extends BaseMapperX<ChannelModBusTagEntity> {
 
-    void insertList(List<ChannelModBusTagEntity> list);
-
-    String selectIdByName(@Param("name") String name);
+    default PageResult<ChannelModBusTagEntity> selectPage(ModBusTagPageReqVO reqVO) {
+        return selectPage(reqVO, new LambdaQueryWrapperX<ChannelModBusTagEntity>()
+                .likeIfPresent(ChannelModBusTagEntity::getTagName, reqVO.getTagName())
+                .likeIfPresent(ChannelModBusTagEntity::getAddress, reqVO.getAddress())
+                .likeIfPresent(ChannelModBusTagEntity::getTagDesc, reqVO.getTagDesc())
+                .likeIfPresent(ChannelModBusTagEntity::getDevice, reqVO.getDevice())
+                .orderByDesc(ChannelModBusTagEntity::getCreateTime));
+    }
 }

--
Gitblit v1.9.3