97 lines
3.2 KiB
Plaintext
97 lines
3.2 KiB
Plaintext
package com.sercurityControl.proteam.controller;
|
||
|
||
import com.securityControl.common.core.web.controller.BaseController;
|
||
import com.securityControl.common.core.web.domain.AjaxResult;
|
||
import com.securityControl.common.core.web.page.TableDataInfo;
|
||
import com.securityControl.common.log.annotation.Log;
|
||
import com.securityControl.common.log.enums.BusinessType;
|
||
import com.securityControl.common.log.enums.OperationType;
|
||
import com.sercurityControl.proteam.domain.ClassData;
|
||
import com.sercurityControl.proteam.domain.UAVBandProEntity;
|
||
import com.sercurityControl.proteam.service.UavPatrolService;
|
||
import io.swagger.annotations.Api;
|
||
import io.swagger.annotations.ApiOperation;
|
||
import lombok.extern.slf4j.Slf4j;
|
||
import org.springframework.beans.factory.annotation.Autowired;
|
||
import org.springframework.web.bind.annotation.PostMapping;
|
||
import org.springframework.web.bind.annotation.RequestMapping;
|
||
import org.springframework.web.bind.annotation.RestController;
|
||
|
||
/**
|
||
* @author Administrator
|
||
*/
|
||
@Api(tags = "无人机")
|
||
@Slf4j
|
||
@RestController
|
||
@RequestMapping(value = "/pot/uav")
|
||
public class UavPatrolController extends BaseController {
|
||
@Autowired
|
||
private UavPatrolService service;
|
||
|
||
/**
|
||
* 通过userId判断权限,来获取无人机数据
|
||
*
|
||
* @param userId 用户id
|
||
* @return 集合
|
||
**/
|
||
@ApiOperation(value = "无人机树")
|
||
@PostMapping("/getUavData")
|
||
@Log(title = "无人机巡视", menu = "无人机巡视", businessType = BusinessType.QUERY, details = "无人机树")
|
||
public AjaxResult getUavData(String userId) {
|
||
return service.getUavData(userId);
|
||
}
|
||
|
||
/**
|
||
* 获取无人机数据 绑定信息
|
||
*
|
||
* @return 集合
|
||
**/
|
||
@ApiOperation(value = "绑定信息")
|
||
@PostMapping("/getUavBandProList")
|
||
@Log(title = "无人机巡视", menu = "无人机巡视", businessType = BusinessType.QUERY, details = "获取无人机绑定信息")
|
||
public TableDataInfo getUavBandProList() {
|
||
startPage();
|
||
return getDataTable(service.getUavBandProList());
|
||
}
|
||
|
||
|
||
/**
|
||
* 获取工程集合
|
||
*
|
||
* @return 集合
|
||
**/
|
||
@ApiOperation(value = "获取工程集合")
|
||
@PostMapping("/getProList")
|
||
@Log(title = "无人机巡视", menu = "无人机巡视", businessType = BusinessType.QUERY, details = "获取工程集合")
|
||
public AjaxResult getProList() {
|
||
return service.getProList();
|
||
}
|
||
|
||
/**
|
||
* 获取工程集合
|
||
*
|
||
* @return 集合
|
||
**/
|
||
@ApiOperation(value = "获取工程集合")
|
||
@PostMapping("/getClass")
|
||
@Log(title = "无人机巡视", menu = "无人机巡视", businessType = BusinessType.QUERY, details = "获取工程集合")
|
||
public TableDataInfo getClass(ClassData entity) {
|
||
startPage();
|
||
return getDataTable(service.getClass(entity));
|
||
}
|
||
|
||
/**
|
||
* 修改设备绑定工程
|
||
*
|
||
* @param entity 条件
|
||
* @return 集合
|
||
**/
|
||
@ApiOperation(value = "修改设备绑定工程")
|
||
@PostMapping("/updateBand")
|
||
@Log(title = "无人机巡视", menu = "无人机巡视", businessType = BusinessType.UPDATE, details = "修改设备绑定工程", grade = OperationType.UPDATE_BUSINESS)
|
||
public AjaxResult updateBand(UAVBandProEntity entity) {
|
||
return service.updateBand(entity);
|
||
}
|
||
|
||
}
|