|
|
|
@ -64,7 +64,7 @@ public class ApiController extends BaseController {
|
|
|
|
|
return AjaxResult.success(iApiService.queryPram(name));
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@ApiOperation(tags = {"60脱水机"}, value = "获取设备状态")
|
|
|
|
|
@ApiOperation(tags = {"60脱水机"}, value = "获取设备状态 msg字段")
|
|
|
|
|
@GetMapping("/home/queryDeviceState")
|
|
|
|
|
public AjaxResult queryDeviceState(String name) {
|
|
|
|
|
if (name.equals("60型一体机A") ){
|
|
|
|
@ -89,47 +89,19 @@ public class ApiController extends BaseController {
|
|
|
|
|
// }
|
|
|
|
|
@ApiOperation(tags = {"60脱水机"}, value = "获取数据记录")
|
|
|
|
|
@GetMapping("/home/queryParamData")
|
|
|
|
|
public TableDataInfo queryParamData(QueryParam param) {
|
|
|
|
|
|
|
|
|
|
startPage();
|
|
|
|
|
List<RecordRaramData> recordRaramData = iApiService.queryParamData(param.getTimeInterval(),
|
|
|
|
|
param.getBeginTime(),param.getEndTime());
|
|
|
|
|
return getDataTable(recordRaramData);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
//查询数据B
|
|
|
|
|
@ApiOperation(tags = {"60脱水机"}, value = "获取一体机B数据记录")
|
|
|
|
|
@GetMapping("/home/queryParamDataB")
|
|
|
|
|
public TableDataInfo queryParamDataB(@RequestParam(defaultValue = "1") int timeInterval, Date beginTime, Date endTime) {
|
|
|
|
|
public TableDataInfo queryParamData(@RequestParam(defaultValue = "1") int timeInterval, Date beginTime, Date endTime) {
|
|
|
|
|
System.out.println("时间间隔" + timeInterval);
|
|
|
|
|
startPage();
|
|
|
|
|
List<RecordRaramDataB> data = iApiService.queryParamData_B(timeInterval, beginTime, endTime);
|
|
|
|
|
return getDataTable(data);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//查询数据B
|
|
|
|
|
@ApiOperation(tags = {"60脱水机"}, value = "获取一体机B趋势")
|
|
|
|
|
@GetMapping("/home/queryBTrend")
|
|
|
|
|
public AjaxResult queryBTrend(@RequestParam(defaultValue = "1") int timeInterval, Date beginTime, Date endTime) {
|
|
|
|
|
|
|
|
|
|
return AjaxResult.success(iApiService.queryParamData_B(timeInterval, beginTime, endTime));
|
|
|
|
|
return getDataTable( iApiService.queryParamData(timeInterval, beginTime, endTime));
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ApiOperation(tags = {"60脱水机"}, value = "导出数据记录")
|
|
|
|
|
@PostMapping("/home/exportParamList")
|
|
|
|
|
@ResponseBody
|
|
|
|
|
public AjaxResult export(String name, String type, String colms, @RequestParam(defaultValue = "1") int timeInterval, Date beginTime, Date endTime) {
|
|
|
|
|
System.out.println("显示列:" + colms);
|
|
|
|
|
List<RecordRaramData> list = iApiService.queryParamData(timeInterval, beginTime, endTime);
|
|
|
|
|
ExcelUtil_2<RecordRaramData> util = new ExcelUtil_2(RecordRaramData.class);
|
|
|
|
|
List<RecordPiontData> list = iApiService.queryParamData(timeInterval, beginTime, endTime);
|
|
|
|
|
ExcelUtil_2<RecordPiontData> util = new ExcelUtil_2(RecordRaramData.class);
|
|
|
|
|
if (colms != null) {
|
|
|
|
|
List<String> tags = Arrays.asList(colms.split(","));
|
|
|
|
|
List<String> tagsF = new ArrayList<>(Arrays.asList("采集时间", "一体机A转速", "一体机A电流", "一体机A切刀转速", "一体机A切刀电流", "一体机A机头温度", "一体机A机头压力"));
|
|
|
|
@ -147,6 +119,13 @@ public class ApiController extends BaseController {
|
|
|
|
|
return util.exportExcel(list, "数据记录", name + "," + type);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//查询数据B
|
|
|
|
|
@ApiOperation(tags = {"60脱水机"}, value = "获取数据记录")
|
|
|
|
|
@GetMapping("/home/queryParamDataB")
|
|
|
|
|
public AjaxResult queryParamDataB(@RequestParam(defaultValue = "1") int timeInterval, Date beginTime, Date endTime) {
|
|
|
|
|
System.out.println("时间间隔" + timeInterval);
|
|
|
|
|
return AjaxResult.success(iApiService.queryParamData_B(timeInterval, beginTime, endTime));
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@ApiOperation(tags = {"60脱水机"}, value = "导出数据记录")
|
|
|
|
|
@PostMapping("/home/exportParamListB")
|
|
|
|
|