添加swagger注释
This commit is contained in:
parent
0f9588aa4c
commit
0cacf6c8fa
|
@ -122,11 +122,10 @@ public class Controller {
|
||||||
* @param
|
* @param
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@RequestMapping("selectAll")
|
@GetMapping("selectAll")
|
||||||
|
@ApiOperation("查询所有摄像头")
|
||||||
public String selectAll(){
|
public String selectAll(){
|
||||||
|
|
||||||
return cameraChannelService.selectAll();
|
return cameraChannelService.selectAll();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -134,7 +133,9 @@ public class Controller {
|
||||||
* @param channelCode
|
* @param channelCode
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@RequestMapping("selectByChannelCode")
|
@GetMapping("selectByChannelCode")
|
||||||
|
@ApiOperation("根据channelCode查询摄像头详细信息")
|
||||||
|
@ApiImplicitParam(name = "channelCode",value = "摄像头标识",required = true,dataType = "String")
|
||||||
public Result selectByChannelCode(String channelCode){
|
public Result selectByChannelCode(String channelCode){
|
||||||
|
|
||||||
List<CameraChannelDto1> list = cameraChannelMapper.selectByChannelCode(channelCode);
|
List<CameraChannelDto1> list = cameraChannelMapper.selectByChannelCode(channelCode);
|
||||||
|
@ -151,7 +152,9 @@ public class Controller {
|
||||||
* @param channelName
|
* @param channelName
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@RequestMapping("selectByChannelName")
|
@GetMapping("selectByChannelName")
|
||||||
|
@ApiOperation("根据摄像头名字模糊查询摄像头")
|
||||||
|
@ApiImplicitParam(name = "channelName",value = "摄像头名称",required = true,dataType = "String")
|
||||||
public Result selectByChannelName(String channelName){
|
public Result selectByChannelName(String channelName){
|
||||||
|
|
||||||
List<CameraChannel> labels = cameraChannelMapper.selectByChannelName(channelName);
|
List<CameraChannel> labels = cameraChannelMapper.selectByChannelName(channelName);
|
||||||
|
@ -162,11 +165,16 @@ public class Controller {
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 根据parentId查询摄像头
|
* 根据parentId和checkStatus查询摄像头
|
||||||
* @param parentId
|
* @param parentId
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@RequestMapping("selectByParentId")
|
@GetMapping("selectByParentId")
|
||||||
|
@ApiOperation("根据parentId和checkStatus查询摄像头")
|
||||||
|
@ApiImplicitParams({
|
||||||
|
@ApiImplicitParam(name = "parentId",value = "摄像头的组织Id",required = true,dataType = "String"),
|
||||||
|
@ApiImplicitParam(name = "checkStatus",value = "异常状态 1正常,0异常",required = true,dataType = "String")
|
||||||
|
})
|
||||||
public Result selectByParentId(String parentId,String checkStatus){
|
public Result selectByParentId(String parentId,String checkStatus){
|
||||||
|
|
||||||
List<CameraChannel> list = cameraChannelMapper.selectByParentId(parentId,checkStatus);
|
List<CameraChannel> list = cameraChannelMapper.selectByParentId(parentId,checkStatus);
|
||||||
|
@ -181,7 +189,9 @@ public class Controller {
|
||||||
* 根据标签查询对应摄像头
|
* 根据标签查询对应摄像头
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@RequestMapping("selectLabel")
|
@GetMapping("selectLabel")
|
||||||
|
@ApiOperation("根据标签查询对应摄像头")
|
||||||
|
@ApiImplicitParam(name = "labelCode",value = "标签号",required = true,dataType = "String")
|
||||||
public Result selectLabel(String labelCode){
|
public Result selectLabel(String labelCode){
|
||||||
|
|
||||||
List<ChannelLabelDto> channelLabelDtos = cameraChannelMapper.selectLabel(labelCode);
|
List<ChannelLabelDto> channelLabelDtos = cameraChannelMapper.selectLabel(labelCode);
|
||||||
|
@ -205,7 +215,7 @@ public class Controller {
|
||||||
* @param gpsY1
|
* @param gpsY1
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@RequestMapping("selectAllByGps")
|
@GetMapping ("selectAllByGps")
|
||||||
public Result selectAllByGps(String gpsX,String gpsX1,String gpsY,String gpsY1){
|
public Result selectAllByGps(String gpsX,String gpsX1,String gpsY,String gpsY1){
|
||||||
|
|
||||||
List<CameraChannelDto> gps = cameraChannelMapper.selectAllByGps(gpsX, gpsX1, gpsY, gpsY1);
|
List<CameraChannelDto> gps = cameraChannelMapper.selectAllByGps(gpsX, gpsX1, gpsY, gpsY1);
|
||||||
|
@ -224,7 +234,8 @@ public class Controller {
|
||||||
* @param label
|
* @param label
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@RequestMapping("selectAllLabel")
|
@GetMapping("selectAllLabel")
|
||||||
|
@ApiOperation("查询所有标签")
|
||||||
public Result selectAllLabel(Label label ){
|
public Result selectAllLabel(Label label ){
|
||||||
|
|
||||||
List<Label> labels = cameraChannelMapper.selectAllLabel(label);
|
List<Label> labels = cameraChannelMapper.selectAllLabel(label);
|
||||||
|
@ -238,7 +249,7 @@ public class Controller {
|
||||||
* @param labelName
|
* @param labelName
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@RequestMapping("selectByLabelName")
|
@GetMapping("selectByLabelName")
|
||||||
public Result selectByLabelName(String labelName){
|
public Result selectByLabelName(String labelName){
|
||||||
|
|
||||||
List<Label> labels = cameraChannelMapper.selectByLabelName(labelName);
|
List<Label> labels = cameraChannelMapper.selectByLabelName(labelName);
|
||||||
|
@ -253,7 +264,9 @@ public class Controller {
|
||||||
* @param parentId
|
* @param parentId
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@RequestMapping("selectSubOrgan")
|
@GetMapping("selectSubOrgan")
|
||||||
|
@ApiOperation("根据parentId查询组织")
|
||||||
|
@ApiImplicitParam(name = "parentId",value = "上级组织id",required = true,dataType = "String")
|
||||||
public Result selectSubOrganization(String parentId){
|
public Result selectSubOrganization(String parentId){
|
||||||
if (parentId == null){
|
if (parentId == null){
|
||||||
parentId = "";
|
parentId = "";
|
||||||
|
@ -265,7 +278,7 @@ public class Controller {
|
||||||
|
|
||||||
return success;
|
return success;
|
||||||
}
|
}
|
||||||
|
|
||||||
//查询视频点播巡检结果,只取异常的
|
//查询视频点播巡检结果,只取异常的
|
||||||
// @RequestMapping("listChannelPlayStates")
|
// @RequestMapping("listChannelPlayStates")
|
||||||
// public Result listChannelPlayStates(
|
// public Result listChannelPlayStates(
|
||||||
|
|
|
@ -4,6 +4,7 @@ import cn.hutool.http.HttpRequest;
|
||||||
import com.alibaba.fastjson.JSONObject;
|
import com.alibaba.fastjson.JSONObject;
|
||||||
import com.hisense.monitormanage.entity.Result;
|
import com.hisense.monitormanage.entity.Result;
|
||||||
import com.hisense.monitormanage.service.ShangTangService;
|
import com.hisense.monitormanage.service.ShangTangService;
|
||||||
|
import io.swagger.annotations.ApiOperation;
|
||||||
import org.omg.CORBA.Request;
|
import org.omg.CORBA.Request;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.web.bind.annotation.PostMapping;
|
import org.springframework.web.bind.annotation.PostMapping;
|
||||||
|
@ -40,6 +41,7 @@ public class ShangTangController {
|
||||||
* @throws IOException
|
* @throws IOException
|
||||||
*/
|
*/
|
||||||
@RequestMapping("receive")
|
@RequestMapping("receive")
|
||||||
|
@ApiOperation("订阅任务下发接口")
|
||||||
public Result receive(HttpServletRequest request) throws IOException {
|
public Result receive(HttpServletRequest request) throws IOException {
|
||||||
ServletInputStream ris = request.getInputStream();
|
ServletInputStream ris = request.getInputStream();
|
||||||
StringBuilder content = new StringBuilder();
|
StringBuilder content = new StringBuilder();
|
||||||
|
@ -60,6 +62,7 @@ public class ShangTangController {
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@RequestMapping("tamplate")
|
@RequestMapping("tamplate")
|
||||||
|
@ApiOperation("事件模板分页查询接口")
|
||||||
public JSONObject tamplate(){
|
public JSONObject tamplate(){
|
||||||
return shangTangService.template();
|
return shangTangService.template();
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue