查询站点已绑定/未绑定设备列表,气象设备实时数据接口返回格式调整等
This commit is contained in:
@ -38,12 +38,12 @@ public class AgricultureCropYieldController extends BaseController
|
||||
@Autowired
|
||||
private IAgricultureCropYieldService agricultureCropYieldService;
|
||||
|
||||
/**
|
||||
* 查询作物产量记录列表
|
||||
*/
|
||||
//@PreAuthorize("@ss.hasPermi('crop:yield:list')")
|
||||
@GetMapping("/list")
|
||||
@ApiOperation("查询作物产量记录列表")
|
||||
/**
|
||||
* 查询作物产量记录列表
|
||||
*/
|
||||
//@PreAuthorize("@ss.hasPermi('crop:yield:list')")
|
||||
@GetMapping("/list")
|
||||
@ApiOperation("查询作物产量记录列表")
|
||||
public TableDataInfo list(AgricultureCropYield agricultureCropYield)
|
||||
{
|
||||
startPage();
|
||||
|
@ -52,17 +52,21 @@ public class DeviceHistoryDataController extends BaseController {
|
||||
public TableDataInfo getMeteorologyHistoryData(DeviceRealtimedataMeteorology deviceRealtimedataMeteorology){
|
||||
startPage();
|
||||
List<DeviceRealtimedataMeteorology> list = new LambdaQueryChainWrapper<>(deviceRealtimedataMeteorologyMapper)
|
||||
.eq(DeviceRealtimedataMeteorology::getDeviceId,deviceRealtimedataMeteorology.getDeviceId()).list();
|
||||
.eq(DeviceRealtimedataMeteorology::getDeviceId,deviceRealtimedataMeteorology.getDeviceId())
|
||||
.orderByDesc(DeviceRealtimedataMeteorology::getRealTime)
|
||||
.list();
|
||||
return getDataTable(list);
|
||||
}
|
||||
/**
|
||||
* 获取墒情实时数据
|
||||
* 获取墒情设备历史数据
|
||||
*/
|
||||
@GetMapping("/moisture")
|
||||
public TableDataInfo getMoistureHistoryData(DeviceRealtimedataMoisture deviceRealtimedataMoisture){
|
||||
startPage();
|
||||
List<DeviceRealtimedataMoisture> list = new LambdaQueryChainWrapper<>(deviceRealtimedataMoistureMapper)
|
||||
.eq(DeviceRealtimedataMoisture::getDeviceId,deviceRealtimedataMoisture.getDeviceId()).list();
|
||||
.eq(DeviceRealtimedataMoisture::getDeviceId,deviceRealtimedataMoisture.getDeviceId())
|
||||
.orderByDesc(DeviceRealtimedataMoisture::getRealTime)
|
||||
.list();
|
||||
return getDataTable(list);
|
||||
}
|
||||
/**
|
||||
|
@ -9,11 +9,16 @@ import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
/**
|
||||
* 监控设备实时数据
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/device/real/data")
|
||||
public class DeviceMonitorController extends BaseController {
|
||||
@Autowired
|
||||
private YingshiyunService yingshiyunService;
|
||||
|
||||
|
||||
@GetMapping("/monitor")
|
||||
public AjaxResult getVideoUrl(@Param("deviceId") String deviceId){
|
||||
return success(yingshiyunService.getVideoPlayUrl(deviceId));
|
||||
|
@ -19,7 +19,6 @@ public class DeviceRealtimedataMeteorologyController {
|
||||
|
||||
/**
|
||||
* 获取最新的一条气象数据
|
||||
* @return
|
||||
*/
|
||||
@GetMapping(value = "/weather/realtimedata")
|
||||
public AjaxResult getLatestWeatherRealtimedata() {
|
||||
|
@ -0,0 +1,44 @@
|
||||
package com.fastbee.data.controller.gis.water;
|
||||
|
||||
import com.fastbee.common.core.controller.BaseController;
|
||||
import com.fastbee.common.core.domain.AjaxResult;
|
||||
import com.fastbee.ggroup.domain.GSiteDevice;
|
||||
import com.fastbee.ggroup.domain.vo.GSiteDeviceVo;
|
||||
import com.fastbee.ggroup.service.IGSiteDeviceService;
|
||||
import io.swagger.annotations.Api;
|
||||
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.RestController;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@RestController
|
||||
@RequestMapping("/gis/site/device")
|
||||
@Api(tags = "站点设备")
|
||||
public class GSiteDeviceController extends BaseController {
|
||||
|
||||
@Autowired
|
||||
private IGSiteDeviceService gSiteDeviceService;
|
||||
|
||||
/**
|
||||
* 查询站点未关联的设备列表
|
||||
* @param siteId 站点id
|
||||
* @param groupId 设备组id
|
||||
*/
|
||||
@GetMapping("/unbind")
|
||||
public AjaxResult getUnbindDeviceList(Long siteId,Long groupId) {
|
||||
List<GSiteDeviceVo> gSiteDeviceList = gSiteDeviceService.selectUnbindDeviceList(siteId,groupId);
|
||||
return AjaxResult.success(gSiteDeviceList);
|
||||
}
|
||||
/**
|
||||
* 查询站点已关联的设备列表
|
||||
* @param siteId 站点id
|
||||
* @param groupId 设备组id
|
||||
*/
|
||||
@GetMapping("/bind")
|
||||
public AjaxResult getBindDeviceList(Long siteId,Long groupId) {
|
||||
List<GSiteDeviceVo> gSiteDeviceList = gSiteDeviceService.selectBindDeviceList(siteId,groupId);
|
||||
return AjaxResult.success(gSiteDeviceList);
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user