parent
8251e38ec0
commit
642d5108ac
|
@ -2,6 +2,7 @@ package com.hisense.monitormanage.controller;
|
|||
|
||||
import com.hisense.monitormanage.dto.EventDto;
|
||||
import com.hisense.monitormanage.dto.KeyAreaDto;
|
||||
import com.hisense.monitormanage.entity.KeyArea;
|
||||
import com.hisense.monitormanage.entity.KeyAreaLocation;
|
||||
import com.hisense.monitormanage.entity.PassengerFlow;
|
||||
import com.hisense.monitormanage.entity.Result;
|
||||
|
@ -66,6 +67,19 @@ public class KeyAreaController {
|
|||
return success;
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据名称查询重点区域名称
|
||||
* @param areaName
|
||||
* @return
|
||||
*/
|
||||
@GetMapping("selectByLikeName")
|
||||
@ApiOperation("根据名称查询重点区域名称")
|
||||
public Result selectByLikeName(String areaName){
|
||||
List<KeyArea> keyAreaLocations = keyAreaMapper.selectByLikeName(areaName);
|
||||
Result success = Result.success(keyAreaLocations);
|
||||
return success;
|
||||
}
|
||||
|
||||
/**
|
||||
* 重点区域场景查询所有事件
|
||||
* @return
|
||||
|
|
|
@ -13,7 +13,7 @@ public class KeyArea {
|
|||
|
||||
private String type;//类型
|
||||
|
||||
private String name;//名称
|
||||
private String areaName;//名称
|
||||
|
||||
private String location;//位置
|
||||
|
||||
|
|
|
@ -19,4 +19,9 @@ public interface KeyAreaMapper extends BaseMapper<KeyArea> {
|
|||
@Select("SELECT * FROM t_key_area_location kal JOIN t_key_area ka ON kal.area_id = ka.area_id WHERE ka.area_name = #{areaName}")
|
||||
List<KeyAreaLocation> selectByAreaName(String areaName);
|
||||
|
||||
@Select("select * from t_key_area where area_name like concat('%',#{areaName},'%')")
|
||||
List<KeyArea> selectByLikeName(String areaName);
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue