This commit is contained in:
parent
034a99ba94
commit
0f9588aa4c
|
@ -5,7 +5,12 @@ import com.hisense.monitormanage.dto.*;
|
|||
import com.hisense.monitormanage.entity.*;
|
||||
import com.hisense.monitormanage.mapper.*;
|
||||
import com.hisense.monitormanage.service.*;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
@ -15,6 +20,7 @@ import java.util.Map;
|
|||
|
||||
@RestController
|
||||
@RequestMapping("api/project")
|
||||
@Api(tags="通用")
|
||||
public class Controller {
|
||||
|
||||
@Autowired
|
||||
|
@ -259,27 +265,7 @@ public class Controller {
|
|||
|
||||
return success;
|
||||
}
|
||||
|
||||
/**
|
||||
* 订阅任务下发接口
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping("subscribe")
|
||||
public JSONObject subscribe(){
|
||||
return monitorService.subscribe();
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 事件模板分页查询接口
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping("tamplate")
|
||||
public JSONObject tamplate(){
|
||||
return monitorService.template();
|
||||
|
||||
}
|
||||
|
||||
|
||||
//查询视频点播巡检结果,只取异常的
|
||||
// @RequestMapping("listChannelPlayStates")
|
||||
// public Result listChannelPlayStates(
|
||||
|
@ -290,55 +276,64 @@ public class Controller {
|
|||
// }
|
||||
|
||||
//道路统计数据与排名
|
||||
@RequestMapping("roadData")
|
||||
@GetMapping("roadData")
|
||||
@ApiOperation("道路统计数据与排名,根据后台dt调用接口")
|
||||
public List<Map> roadData(){
|
||||
return monitorService.roadData();
|
||||
}
|
||||
|
||||
//启迪中台
|
||||
//登录
|
||||
@RequestMapping("qidiToken")
|
||||
@GetMapping("qidiToken")
|
||||
@ApiOperation("启迪数据中台登录获取token")
|
||||
public String qidiToken(){
|
||||
return monitorService.qidiToken();
|
||||
}
|
||||
|
||||
//渣土车轨迹数据
|
||||
@RequestMapping("resCatalogApplyZTYS")
|
||||
@GetMapping("resCatalogApplyZTYS")
|
||||
@ApiOperation("获取渣土车轨迹数据,根据后台UPLOADTIME调用接口")
|
||||
public List<Map> resCatalogApply(){
|
||||
return monitorService.resCatalogApplyZTYS();
|
||||
}
|
||||
|
||||
//环卫车轨迹数据
|
||||
@RequestMapping("resCatalogApplyHJWS")
|
||||
@GetMapping("resCatalogApplyHJWS")
|
||||
@ApiOperation("环卫车轨迹数据,根据后台updatetime调用接口")
|
||||
public List<Map> resCatalogApplyHJWS(){
|
||||
return monitorService.resCatalogApplyHJWS();
|
||||
}
|
||||
|
||||
//工地信息
|
||||
@RequestMapping("resCatalogApplyGDYS")
|
||||
@GetMapping("resCatalogApplyGDYS")
|
||||
@ApiOperation("获取工地信息-表中获取")
|
||||
public List<Map> resCatalogApplyGDYS(){
|
||||
return monitorService.resCatalogApplyGDYS();
|
||||
}
|
||||
|
||||
//环卫车辆数据1,基础
|
||||
@RequestMapping("resCatalogApplyHJWSBase")
|
||||
@GetMapping("resCatalogApplyHJWSBase")
|
||||
@ApiOperation("环卫车辆数据1,基础--根据后台updatetime调用接口")
|
||||
public List<Map> resCatalogApplyHJWSBase(){
|
||||
return monitorService.resCatalogApplyHJWSBase();
|
||||
}
|
||||
//环卫车辆数据1,作业
|
||||
@RequestMapping("resCatalogApplyHJWSZY")
|
||||
@GetMapping("resCatalogApplyHJWSZY")
|
||||
@ApiOperation("环卫车辆数据1,作业--根据后台ZYRQ调用接口")
|
||||
public List<Map> resCatalogApplyHJWSZY(){
|
||||
return monitorService.resCatalogApplyHJWSZY();
|
||||
}
|
||||
|
||||
//环卫道路明细数据
|
||||
@RequestMapping("resCatalogApplyHJWSRoad")
|
||||
@GetMapping("resCatalogApplyHJWSRoad")
|
||||
@ApiOperation("环卫道路明细数据,根据后台updatetime调用接口")
|
||||
public List<Map> resCatalogApplyHJWSRoad(){
|
||||
return monitorService.resCatalogApplyHJWSRoad();
|
||||
}
|
||||
|
||||
//获取渣土车轨迹并保存到t_trail_sediment
|
||||
@RequestMapping(value = "saveResCatalogApplyZTYS")
|
||||
@GetMapping(value = "saveResCatalogApplyZTYS")
|
||||
@ApiOperation("取渣土车轨迹并保存到t_trail_sediment,根据后台UPLOADTIME调用接口")
|
||||
public Result resCatalogApplyZTYS(){
|
||||
|
||||
boolean result = sedimentTrailService.batchSaveSedimentTrail();
|
||||
|
@ -350,7 +345,15 @@ public class Controller {
|
|||
}
|
||||
|
||||
//根据输入的经纬度和查询的半径(米)时间查询范围内的渣土车轨迹信息
|
||||
@RequestMapping(value = "listSedimentTrailByPoints")
|
||||
@GetMapping(value = "listSedimentTrailByPoints")
|
||||
@ApiOperation("渣土车轨迹信息,根据经纬度和半径从表中查询")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "longitude", value = "经度", paramType = "query",required = true,dataType ="double"),
|
||||
@ApiImplicitParam(name = "latitude", value = "纬度", paramType = "query",required = true,dataType ="double"),
|
||||
@ApiImplicitParam(name = "raidus", value = "半径,米", paramType = "query",required = true,dataType ="Integer"),
|
||||
@ApiImplicitParam(name = "start", value = "开始时间,2021-08-03 10:17:23", paramType = "query",required = true,dataType ="string"),
|
||||
@ApiImplicitParam(name = "end", value = "结束时间,2021-08-03 12:17:23", paramType = "query",required = true,dataType ="string")
|
||||
})
|
||||
public Result listSedimentTrailByPoints(
|
||||
@RequestParam(value="longitude") double longitude,
|
||||
@RequestParam(value="latitude") double latitude,
|
||||
|
@ -358,27 +361,29 @@ public class Controller {
|
|||
@RequestParam(value="start") String start,
|
||||
@RequestParam(value = "end") String end
|
||||
){
|
||||
System.out.println("listSedimentTrailByPoints......");
|
||||
Map<String,List<SedimentTrail>> map = sedimentTrailService.listSedimentTrailByPoints(longitude,latitude,raidus,start,end);
|
||||
return Result.success(map);
|
||||
}
|
||||
|
||||
@RequestMapping("passengerFlow")
|
||||
//测试获取最新的客流列表,从接口获取
|
||||
@GetMapping("passengerFlow")
|
||||
@ApiOperation("获取最新的客流列表,测试接口,调用接口获取")
|
||||
public List<Map> passengerFlow(){
|
||||
List<Map> list = passengerFlowService.passengerFlow();
|
||||
return list;
|
||||
}
|
||||
|
||||
//获取最新的实时客流列表,从表获取
|
||||
@RequestMapping("listPassengerFlow")
|
||||
@GetMapping("listPassengerFlow")
|
||||
@ApiOperation("获取最新的实时客流列表,从表获取,热力图")
|
||||
public List<PassengerFlow> listPassengerFlow(){
|
||||
List<PassengerFlow> list = passengerFlowService.listPassengerFlow();
|
||||
return list;
|
||||
}
|
||||
|
||||
|
||||
//获取实时客流并保存到表t_passenger_flow
|
||||
@RequestMapping("savePassengerFlow")
|
||||
@GetMapping("savePassengerFlow")
|
||||
@ApiOperation("获取实时客流并保存到表t_passenger_flow,调用接口")
|
||||
public Result savePassengerFlow(){
|
||||
List<Map> list = passengerFlowService.passengerFlow();
|
||||
boolean result = passengerFlowService.savePassengerFlow(list);
|
||||
|
@ -389,8 +394,15 @@ public class Controller {
|
|||
}
|
||||
}
|
||||
|
||||
//根据输入的经纬度和查询的半径(米)和hourId查询游客总数
|
||||
@RequestMapping("getPassengerNum")
|
||||
//根据输入的经纬度和查询的半径(米)和timeId查询游客总数
|
||||
@GetMapping("getPassengerNum")
|
||||
@ApiOperation("查询游客总数,根据经纬度和半径米、timeId从表中查询")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "longitude", value = "经度", paramType = "query",required = true,dataType ="double"),
|
||||
@ApiImplicitParam(name = "latitude", value = "纬度", paramType = "query",required = true,dataType ="double"),
|
||||
@ApiImplicitParam(name = "raidus", value = "半径,米", paramType = "query",required = true,dataType ="Integer"),
|
||||
@ApiImplicitParam(name = "timeId", value = "时间点,202205101600", paramType = "query",required = true,dataType ="string"),
|
||||
})
|
||||
public Result getPassengerNum(
|
||||
@RequestParam(value="longitude") double longitude,
|
||||
@RequestParam(value="latitude") double latitude,
|
||||
|
@ -401,7 +413,8 @@ public class Controller {
|
|||
}
|
||||
|
||||
//查询并保存环卫车轨迹到表t_trail_sanitation
|
||||
@RequestMapping("saveTrailSanitation")
|
||||
@GetMapping("saveTrailSanitation")
|
||||
@ApiOperation("保存环卫车轨迹到表t_trail_sanitation,根据后台updatetime调用接口")
|
||||
public Result saveTrailSanitation(){
|
||||
boolean result = trailSanitationService.saveTrailSanitation();
|
||||
if(result){
|
||||
|
@ -412,7 +425,15 @@ public class Controller {
|
|||
}
|
||||
|
||||
//根据输入的经纬度和查询的半径(米)时间查询范围内的环卫车轨迹信息
|
||||
@RequestMapping(value = "listTrailSanitationByPoints")
|
||||
@GetMapping(value = "listTrailSanitationByPoints")
|
||||
@ApiOperation("查询范围内环卫车轨迹信息,根据经纬度、半径米,时间从表中查询")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "longitude", value = "经度", paramType = "query",required = true,dataType ="double"),
|
||||
@ApiImplicitParam(name = "latitude", value = "纬度", paramType = "query",required = true,dataType ="double"),
|
||||
@ApiImplicitParam(name = "raidus", value = "半径,米", paramType = "query",required = true,dataType ="Integer"),
|
||||
@ApiImplicitParam(name = "start", value = "开始时间,2021-03-17 00:00:00", paramType = "query",required = true,dataType ="string"),
|
||||
@ApiImplicitParam(name = "end", value = "结束时间,2021-03-22 00:00:00", paramType = "query",required = true,dataType ="string"),
|
||||
})
|
||||
public Result listTrailSanitationByPoints(
|
||||
@RequestParam(value="longitude") double longitude,
|
||||
@RequestParam(value="latitude") double latitude,
|
||||
|
@ -420,23 +441,29 @@ public class Controller {
|
|||
@RequestParam(value="start") String start,
|
||||
@RequestParam(value = "end") String end
|
||||
){
|
||||
// System.out.println("listTrailSanitationByPoints......");
|
||||
List<TrailSanitation> list = trailSanitationService.listSedimentTrailByPoints(longitude,latitude,raidus,start,end);
|
||||
return Result.success(list);
|
||||
}
|
||||
|
||||
//查询道路污染数据
|
||||
@RequestMapping(value="listRoadData")
|
||||
//输入参考:2022-05-10 00:00:00,只能查询当前日期前一天及以前的
|
||||
@GetMapping(value="listRoadData")
|
||||
@ApiOperation("查询道路污染数据,根据dt从表中查询,参考输入-2022-05-10 00:00:00,只能查询当前日期前一天及以前的")
|
||||
@ApiImplicitParam(name="dt",value = "时间",paramType = "query",required = true,dataType = "string")
|
||||
public Result listRoadData(@RequestParam(value="dt") String dt){
|
||||
List<RoadData> list = roadDataService.listRoadData(dt);
|
||||
return Result.success(list);
|
||||
}
|
||||
|
||||
//查询工地信息,根据经纬度和半径查询
|
||||
@RequestMapping(value = "listBuildingSiteByPoints")
|
||||
@GetMapping(value = "listBuildingSiteByPoints")
|
||||
@ApiOperation("查询工地信息,根据经纬度和半径从表中查询")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name="longitude",value = "经度",paramType = "query",required = true,dataType = "double"),
|
||||
@ApiImplicitParam(name="longitude",value = "经度",paramType = "query",required = true,dataType = "double")
|
||||
})
|
||||
public Result listBuildingSiteByPoints(double longitude,double latitude,Integer raidus){
|
||||
List<BuildingSite> list = new ArrayList<>();
|
||||
|
||||
list = buildingSitrService.listBuildingSiteByPoints(longitude,latitude,raidus);
|
||||
return Result.success(list);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue