Commit fdba34c3 authored by tangwei's avatar tangwei

增加app接口

parent 74f0f25c
......@@ -11,9 +11,15 @@ import lombok.Data;
public class PageDto {
private int current;
private int size;
private String name;
private String code;
private String typeCode;
public PageDto(int current, int size) {
this.current = current;
this.size = size;
}
public PageDto() {
}
}
......@@ -193,6 +193,17 @@ public interface EquipFeignClient {
*/
@RequestMapping(value = "/video/pageVideo", method = RequestMethod.GET)
ResponseModel<Page<Map<String, Object>>> pageVideo( @RequestParam Integer pageNum, @RequestParam Integer pageSize, @RequestParam Double longitude,@RequestParam Double latitude,@RequestParam Double distance);
@RequestMapping(value = "/video/pageList", method = RequestMethod.GET)
ResponseModel<Page<Map<String, Object>>> pageList( @RequestParam Integer current,
@RequestParam Integer size,
@RequestParam String code,
@RequestParam String name,
@RequestParam String typeCode);
/**
*
*获取视频列表
......
package com.yeejoin.amos.boot.module.common.api.feign;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.typroject.tyboot.core.restful.utils.ResponseModel;
/**
* @description:
* @author: tw
* @createDate: 2021/10/20
*/
@FeignClient(name = "${video.fegin.name}", path = "video", configuration = {MultipartSupportConfig.class})
public interface VideoFeignClient {
@RequestMapping(value = "/video-original/url/video/{indexCode}", method = RequestMethod.GET)
ResponseModel<String> videoUrlByIndexCode(@PathVariable String indexCode);
}
......@@ -23,6 +23,7 @@ import com.yeejoin.amos.boot.module.common.api.entity.Firefighters;
import com.yeejoin.amos.boot.module.common.api.entity.OrgUsr;
import com.yeejoin.amos.boot.module.common.api.feign.EquipFeignClient;
import com.yeejoin.amos.boot.module.common.api.feign.IotFeignClient;
import com.yeejoin.amos.boot.module.common.api.feign.VideoFeignClient;
import com.yeejoin.amos.boot.module.common.api.service.IDutyCarService;
import com.yeejoin.amos.boot.module.common.api.service.IDutyPersonService;
import com.yeejoin.amos.boot.module.common.api.service.IFireChemicalService;
......@@ -123,6 +124,9 @@ public class CommandController extends BaseController {
private String readUrl;
@Autowired
EquipFeignClient equipFeignClient;
@Autowired
VideoFeignClient videoFeignClient;
@Autowired
IKeySiteService keySiteService;
@Autowired
......@@ -287,6 +291,26 @@ public class CommandController extends BaseController {
}
/**
* 水源列表分页查询
*
* @return
*/
@TycloudOperation( needAuth = true, ApiLevel = UserType.AGENCY)
@PostMapping (value = "video/pageList")
@ApiOperation(httpMethod = "POST", value = " app视频分页查询88", notes = "app视频分页查询88")
public ResponseModel<Object> pageList(@RequestBody PageDto pageDto) {
ResponseModel<Page<Map<String, Object>>> data= equipFeignClient.pageList(pageDto.getCurrent(),pageDto.getSize(),pageDto.getCode(),pageDto.getName(),pageDto.getTypeCode());
return ResponseHelper.buildResponse(data!=null?data.getResult():null);
}
/**
* 水源列表分页查询
*
......
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