2021与蓝度共同重构项目,服务端
liuhaonan
2022-03-14 4ebdb96c3e1a5fd934c32e4ef79d5421271278f4
ximon-admin/src/main/java/com/sandu/ximon/admin/controller/XiXunController.java
@@ -236,6 +236,8 @@
                                bind -> {
                                    if (bind.getDeviceCode() != null && led.getLightemitControlCode() == bind.getDeviceCode()) {
                                        led.setStreetlightId(bind.getPoleId());
                                        System.out.println("有没有运行到这里?---------------"+bind.getPoleId());
                                        led.setStreetlightName(poleService.getOne(Wrappers.lambdaQuery(Pole.class).eq(Pole::getId, bind.getPoleId())).getPoleName());
                                    }
                                }
                        );
@@ -257,13 +259,22 @@
                                bind -> {
                                    if (bind.getDeviceCode() != null && led.getLightemitControlCode().equals(bind.getDeviceCode())) {
                                        led.setStreetlightId(bind.getPoleId());
                                        led.setPoleName(poleService.getOne(Wrappers.lambdaQuery(Pole.class).eq(Pole::getId, bind.getPoleId())).getPoleName());
                                        System.out.println("有没有运行到这里?---------------"+bind.getPoleId());
                                        led.setStreetlightName(poleService.getOne(Wrappers.lambdaQuery(Pole.class).eq(Pole::getId, bind.getPoleId())).getPoleName());
                                    }
                                }
                        );
                    }
            );
            return ResponseUtil.success(list);
            CommonPage commonPage = CommonPage.restPage(list);
            int size = list.size();
            commonPage.setTotal((long) size);
            commonPage.setTotalPage(size / baseConditionVO.getPageSize() + 1);
            if (size % baseConditionVO.getPageSize() == 0) {
                commonPage.setTotalPage(size / baseConditionVO.getPageSize());
            }
            return ResponseUtil.success(commonPage);
           // return ResponseUtil.success(list);
        }
//        return ResponseUtil.success(poleLightemitService.list(wrapper));
    }