|
|
@@ -175,14 +175,24 @@ public class SysDeviceServiceImpl extends ServiceImpl<SysDeviceMapper, SysDevice
|
|
|
videoVO.setVideoName(s.getDeviceName());
|
|
|
List<AccessType> accessByVideo = sysDeviceMapper.getAccessByVideo(s.getId(), taskId);
|
|
|
if (accessByVideo.size()>0) {
|
|
|
- accessByVideo.forEach(a -> {
|
|
|
+ for (AccessType a:accessByVideo){
|
|
|
String situation = a.getSituation();
|
|
|
int num = a.getNum();
|
|
|
videoVO.setType(1);
|
|
|
if (situation.equals("1") && num > 0) {
|
|
|
videoVO.setType(2);
|
|
|
+ break;
|
|
|
}
|
|
|
- });
|
|
|
+ }
|
|
|
+ /* accessByVideo.forEach(a -> {
|
|
|
+ String situation = a.getSituation();
|
|
|
+ int num = a.getNum();
|
|
|
+ videoVO.setType(1);
|
|
|
+ if (situation.equals("1") && num > 0) {
|
|
|
+ videoVO.setType(2);
|
|
|
+ }
|
|
|
+ });*/
|
|
|
+
|
|
|
} else {
|
|
|
videoVO.setType(0);
|
|
|
}
|