From 976dba718380ce027c78a7a82c297cfbedb8b338 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=8E=8B=E5=85=B4=E7=90=B3?= <1911390090@qq.com> Date: Fri, 26 Jul 2024 13:44:14 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E8=B7=AF=E5=86=B5=E4=BF=A1?= =?UTF-8?q?=E6=81=AF=E5=85=A5=E5=BA=93=E6=97=B6=E9=97=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../DcTimingOfTrafficConditionsController.java | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/zc-business/src/main/java/com/zc/business/controller/DcTimingOfTrafficConditionsController.java b/zc-business/src/main/java/com/zc/business/controller/DcTimingOfTrafficConditionsController.java index f160f6da..41125a87 100644 --- a/zc-business/src/main/java/com/zc/business/controller/DcTimingOfTrafficConditionsController.java +++ b/zc-business/src/main/java/com/zc/business/controller/DcTimingOfTrafficConditionsController.java @@ -35,25 +35,9 @@ public class DcTimingOfTrafficConditionsController { //插入 数据库 DcRoadConditionInformation dcRoadConditionInformation =new DcRoadConditionInformation(); dcRoadConditionInformation.setOtherConfig(jsonArray.toJSONString()); - List dcRoadConditionInformations = dcRoadConditionInformationService.selectlistTime(); - if (dcRoadConditionInformations.size()==UniversalEnum.ZERO.getNumber()){ dcRoadConditionInformationService.insertDcRoadConditionInformation(dcRoadConditionInformation); - }else { - DcRoadConditionInformation dcRoadConditionInformation1 = dcRoadConditionInformations.get(UniversalEnum.ZERO.getNumber()); - Date createTime = dcRoadConditionInformation1.getCreateTime(); - Calendar createTimeCalendar = Calendar.getInstance(); - createTimeCalendar.setTime(createTime); - // 获取 createTime 的分钟 - int createMinute = createTimeCalendar.get(Calendar.MINUTE);// 获取当前时间的小时 - Calendar currentCalendar = Calendar.getInstance(); - int currentMinute = currentCalendar.get(Calendar.MINUTE); - if (createMinute != currentMinute) { - dcRoadConditionInformationService.insertDcRoadConditionInformation(dcRoadConditionInformation); - } - } } - // 将获取到的交通指标数据封装为成功的结果并返回 }