Commit 68b02faf authored by wangjinjing's avatar wangjinjing

推送近五分钟车流量改bug

parent 1d60ae39
package com.hzjt.controller;
import com.alibaba.fastjson.JSONObject;
import com.hzjt.mapper.TraffFlowMapper;
import com.hzjt.service.TraffFlowService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.redis.core.StringRedisTemplate;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.*;
import java.util.Map;
import java.util.Set;
/**
......@@ -21,7 +24,8 @@ public class RouterController {
@Autowired
private StringRedisTemplate redisTemplate;
@Autowired
TraffFlowService traffFlowService;
/**
* 登陆页面
......@@ -32,5 +36,11 @@ public class RouterController {
public String index() {
return "login";
}
@GetMapping("/indexxx")
public void indexxx() {
Map map = traffFlowService.getfiveFlowByVideoid("1");
System.out.println(map);
}
}
......@@ -15,13 +15,13 @@ mybatis.configuration.default-statement-timeout=3000
#mybatis.mapperLocations = classpath:xxx.xml
logging.level.com.hzjt=debug
#spring.datasource.username=test
#spring.datasource.password=test
#spring.datasource.url=jdbc:oracle:thin:@192.168.168.212:1523:helowin
spring.datasource.username=test
spring.datasource.password=test
spring.datasource.url=jdbc:oracle:thin:@192.168.168.212:1523:helowin
spring.datasource.username=hzjt
spring.datasource.password=hzjt
spring.datasource.url=jdbc:oracle:thin:@33.50.1.22:1521:orcl
#spring.datasource.username=hzjt
#spring.datasource.password=hzjt
#spring.datasource.url=jdbc:oracle:thin:@33.50.1.22:1521:orcl
spring.datasource.driverClassName=oracle.jdbc.OracleDriver
# druid
......
......@@ -185,14 +185,14 @@
else
0
end),
0) downfiveflow,
0)as "downfiveflow",
NVL(sum(case
when ruletag = '1' then
1
else
0
end),
0) upfiveflow
0) as "upfiveflow"
from vehicle
where CREATE_TIME >= SYSDATE - 5 / 1440 and video_id=#{videoid}
......
......@@ -2,11 +2,14 @@ package com.hzjt;
import com.hzjt.domain.Traffalarmrecord;
import com.hzjt.domain.VideoDeviceTraffic;
import com.hzjt.mapper.TraffFlowMapper;
import com.hzjt.service.TraffFlowService;
import org.junit.Test;
import org.springframework.beans.factory.annotation.Autowired;
public class ExcelToDbApplicationTests {
import java.util.Map;
public class ExcelToDbApplicationTests {
@Test
public void t(){
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment