Browse Source

上下行相机根据相距距离排序

develop
lau572 4 days ago
parent
commit
dadf0f40a3
  1. 2
      zc-business/src/main/java/com/zc/business/controller/VideoController.java

2
zc-business/src/main/java/com/zc/business/controller/VideoController.java

@ -528,7 +528,7 @@ public class VideoController extends BaseController {
// 排序 // 排序
List<DcDevice> sortedList = upCameraList.stream() List<DcDevice> sortedList = upCameraList.stream()
.sorted(Comparator.comparingInt(this::cameraTypeSorted) .sorted(Comparator.comparingInt(this::cameraTypeSorted)
.thenComparing(DcDevice::getStakeMark, Comparator.reverseOrder())) .thenComparing(dcDevice -> Math.abs(pileNumTransformMetre(dcDevice.getStakeMark()) - pileNumDistance)))
.collect(Collectors.toList()); .collect(Collectors.toList());
result.put("upCamera",sortedList); result.put("upCamera",sortedList);

Loading…
Cancel
Save