From f58290cad307c9bb8018ae53cf2bf93bbe9d7bf5 Mon Sep 17 00:00:00 2001
From: 64850858 <648540858@qq.com>
Date: 星期一, 26 七月 2021 17:53:02 +0800
Subject: [PATCH] 更新版本信息

---
 src/main/java/com/genersoft/iot/vmp/storager/dao/DeviceChannelMapper.java |    9 ++++++---
 1 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/src/main/java/com/genersoft/iot/vmp/storager/dao/DeviceChannelMapper.java b/src/main/java/com/genersoft/iot/vmp/storager/dao/DeviceChannelMapper.java
index 2f534cf..f7b89a9 100644
--- a/src/main/java/com/genersoft/iot/vmp/storager/dao/DeviceChannelMapper.java
+++ b/src/main/java/com/genersoft/iot/vmp/storager/dao/DeviceChannelMapper.java
@@ -16,15 +16,15 @@
 
     @Insert("INSERT INTO device_channel (channelId, deviceId, name, manufacture, model, owner, civilCode, block, " +
             "address, parental, parentId, safetyWay, registerWay, certNum, certifiable, errCode, secrecy, " +
-            "ipAddress, port, password, PTZType, status, streamId, longitude, latitude) " +
+            "ipAddress, port, password, PTZType, status, streamId, longitude, latitude, createTime, updateTime) " +
             "VALUES ('${channelId}', '${deviceId}', '${name}', '${manufacture}', '${model}', '${owner}', '${civilCode}', '${block}'," +
             "'${address}', ${parental}, '${parentId}', ${safetyWay}, ${registerWay}, '${certNum}', ${certifiable}, ${errCode}, '${secrecy}', " +
-            "'${ipAddress}', ${port}, '${password}', ${PTZType}, ${status}, '${streamId}', ${longitude}, ${latitude})")
+            "'${ipAddress}', ${port}, '${password}', ${PTZType}, ${status}, '${streamId}', ${longitude}, ${latitude},'${createTime}', '${updateTime}')")
     int add(DeviceChannel channel);
 
     @Update(value = {" <script>" +
             "UPDATE device_channel " +
-            "SET deviceId='${deviceId}'" +
+            "SET updateTime='${updateTime}'" +
             "<if test=\"name != null\">, name='${name}'</if>" +
             "<if test=\"manufacture != null\">, manufacture='${manufacture}'</if>" +
             "<if test=\"model != null\">, model='${model}'</if>" +
@@ -102,4 +102,7 @@
             " </script>"})
 
     List<ChannelReduce> queryChannelListInAll(String query, Boolean online, Boolean hasSubChannel, String platformId, Boolean inPlatform);
+
+    @Select("SELECT * FROM device_channel WHERE channelId=#{channelId}")
+    List<DeviceChannel> queryChannelByChannelId(String channelId);
 }

--
Gitblit v1.8.0