From c5a96f35ff17e71a330fd391bc3866cead3d13b4 Mon Sep 17 00:00:00 2001 From: xuhy <3313886187@qq.com> Date: 星期三, 14 八月 2024 15:59:42 +0800 Subject: [PATCH] 充电桩权限管理 --- ruoyi-service/ruoyi-chargingPile/src/main/java/com/ruoyi/chargingPile/service/impl/TChargingPileServiceImpl.java | 8 ++++---- 1 files changed, 4 insertions(+), 4 deletions(-) diff --git a/ruoyi-service/ruoyi-chargingPile/src/main/java/com/ruoyi/chargingPile/service/impl/TChargingPileServiceImpl.java b/ruoyi-service/ruoyi-chargingPile/src/main/java/com/ruoyi/chargingPile/service/impl/TChargingPileServiceImpl.java index babc84f..6d771f5 100644 --- a/ruoyi-service/ruoyi-chargingPile/src/main/java/com/ruoyi/chargingPile/service/impl/TChargingPileServiceImpl.java +++ b/ruoyi-service/ruoyi-chargingPile/src/main/java/com/ruoyi/chargingPile/service/impl/TChargingPileServiceImpl.java @@ -218,14 +218,14 @@ } @Override - public List<TChargingPileVO> getChargingGunList(Integer siteId) { + public List<TChargingPileVO> getChargingGunList(Integer siteId,Integer type) { List<TChargingPileVO> chargingPileVOS = this.baseMapper.getChargingGunList(siteId); List<TChargingGun> chargingGuns = chargingGunService.list(Wrappers.lambdaQuery(TChargingGun.class) - .eq(TChargingGun::getSiteId, siteId)); + .eq(TChargingGun::getSiteId, siteId) + .eq(TChargingGun::getChargeMode, type)); // 查询充电枪信息 chargingPileVOS.forEach(item -> { - List<TChargingGun> gunList = chargingGuns.stream().filter(gun -> gun.getChargingPileId().equals(item.getId())).collect(Collectors.toList()); - item.setChargingGunList(gunList); + item.setChargingGunList(chargingGuns.stream().filter(gun -> gun.getChargingPileId().equals(item.getId())).collect(Collectors.toList())); }); return chargingPileVOS; } -- Gitblit v1.7.1