From 44c16c53129c9cb34f0c2cae08ebf4b76ec8dedf Mon Sep 17 00:00:00 2001 From: wuweida <2918581207@qq.com> Date: Wed, 25 May 2022 14:04:09 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../monitormanage/service/MonitorService.java | 16 ++++++++-------- src/main/resources/mapper/SanitationMapper.xml | 2 +- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/src/main/java/com/hisense/monitormanage/service/MonitorService.java b/src/main/java/com/hisense/monitormanage/service/MonitorService.java index 856b967..9a3a6aa 100644 --- a/src/main/java/com/hisense/monitormanage/service/MonitorService.java +++ b/src/main/java/com/hisense/monitormanage/service/MonitorService.java @@ -543,16 +543,16 @@ public class MonitorService { ChannelPicture picture = new ChannelPicture(); picture.setChannelCode(channelCode); picture.setPicUrl(picUrl); - picture.setInsertTime(new Date()); - channelPictureMapper.insert(picture); - /*if (channelCode == null){ + /*picture.setInsertTime(new Date()); + channelPictureMapper.insert(picture);*/ + if (channelCode == null){ channelPictureMapper.insert(picture); }else { QueryWrapper queryWrapper = new QueryWrapper<>(); queryWrapper.eq("channel_code", channelCode); picture.setInsertTime(new Date()); channelPictureMapper.update(picture, queryWrapper); - }*/ + } }catch (Exception e){ log.info( "[monitor-capture] " +channelCode + " 截图图片失败 " + e.getMessage()); @@ -585,16 +585,16 @@ public class MonitorService { ChannelPicture picture = new ChannelPicture(); picture.setChannelCode(channelCode); picture.setPicUrl(picUrl); - picture.setInsertTime(new Date()); - channelPictureMapper.insert(picture); - /*if (channelCode == null){ + /*picture.setInsertTime(new Date()); + channelPictureMapper.insert(picture);*/ + if (channelCode == null){ channelPictureMapper.insert(picture); }else { QueryWrapper queryWrapper = new QueryWrapper<>(); queryWrapper.eq("channel_code", channelCode); picture.setInsertTime(new Date()); channelPictureMapper.update(picture, queryWrapper); - }*/ + } }catch (Exception e){ log.info( "[monitor-capture] " +channelCode + " 截图图片失败 " + e.getMessage()); diff --git a/src/main/resources/mapper/SanitationMapper.xml b/src/main/resources/mapper/SanitationMapper.xml index f6c6f54..fe694ef 100644 --- a/src/main/resources/mapper/SanitationMapper.xml +++ b/src/main/resources/mapper/SanitationMapper.xml @@ -46,7 +46,7 @@ ( #{item.DLMC},#{item.KSDL},#{item.ZZDL},#{item.SSQS},#{item.CPH},#{item.ZYWCL}, #{item.ZYRQ},#{item.ZYLX},#{item.ZYSJ},#{item.ZYTS},#{item.ZYPC},#{item.ZYZD}, - #{item.ZYKD},#{item.ZYMJ},#{item.WZYDS},#{item.ZYCSDS},#{item.ZYGPSDS},#{item.updatetime} + #{item.ZYKD},#{item.ZYMJ},#{item.WZYDS},#{item.ZYCSDS},#{item.ZYGPSDS},#{item.updatetime} )