diff --git a/jsowell-admin/src/test/java/SpringBootTestController.java b/jsowell-admin/src/test/java/SpringBootTestController.java index e1f1015fb..eea75b1d7 100644 --- a/jsowell-admin/src/test/java/SpringBootTestController.java +++ b/jsowell-admin/src/test/java/SpringBootTestController.java @@ -76,6 +76,7 @@ import com.jsowell.thirdparty.common.NotificationService; import com.jsowell.thirdparty.huawei.HuaWeiService; import com.jsowell.thirdparty.lianlian.service.LianLianService; import com.jsowell.thirdparty.lutongyunting.service.LTYTService; +import com.jsowell.thirdparty.platform.service.ThirdPartyPlatformService; import com.jsowell.thirdparty.platform.util.Cryptos; import com.jsowell.thirdparty.platform.util.Encodes; import com.jsowell.thirdparty.platform.util.GBSignUtils; @@ -91,6 +92,7 @@ import org.junit.runner.RunWith; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.beans.factory.annotation.Qualifier; import org.springframework.boot.test.context.SpringBootTest; import org.springframework.test.context.ActiveProfiles; import org.springframework.test.context.junit4.SpringRunner; @@ -268,6 +270,18 @@ public class SpringBootTestController { @Autowired private CarCouponRecordService carCouponRecordService; + @Autowired + @Qualifier("zhongDianLianPlatformServiceImpl") + private ThirdPartyPlatformService platformLogic; + + @Test + public void queryStationStatus() { + QueryStationInfoDTO dto = new QueryStationInfoDTO(); + dto.setStationIds(Lists.newArrayList("19")); + Map map = platformLogic.queryStationStatus(dto); + System.out.println(map); + } + @Test public void batchSelectConnectorList() { ArrayList stationIds = Lists.newArrayList("19", "2", "14"); diff --git a/jsowell-thirdparty/src/main/java/com/jsowell/thirdparty/platform/service/impl/ZhongDianLianPlatformServiceImpl.java b/jsowell-thirdparty/src/main/java/com/jsowell/thirdparty/platform/service/impl/ZhongDianLianPlatformServiceImpl.java index 888f7b47b..9aa2cc150 100644 --- a/jsowell-thirdparty/src/main/java/com/jsowell/thirdparty/platform/service/impl/ZhongDianLianPlatformServiceImpl.java +++ b/jsowell-thirdparty/src/main/java/com/jsowell/thirdparty/platform/service/impl/ZhongDianLianPlatformServiceImpl.java @@ -449,19 +449,19 @@ public class ZhongDianLianPlatformServiceImpl implements ThirdPartyPlatformServi StationStatusInfos.add(stationStatusInfo); } // 将 StationStatusInfos 分页 - int pageNum = 1; - int pageSize = 10; - List collect = StationStatusInfos.stream() - .skip((pageNum - 1) * pageSize) - .limit(pageSize) - .collect(Collectors.toList()); + // int pageNum = 1; + // int pageSize = 10; + // List collect = StationStatusInfos.stream() + // .skip((pageNum - 1) * pageSize) + // .limit(pageSize) + // .collect(Collectors.toList()); int total = StationStatusInfos.size(); - int pages = PageUtil.totalPage(total, pageSize); + // int pages = PageUtil.totalPage(total, pageSize); Map map = new LinkedHashMap<>(); map.put("Total", total); - map.put("StationStatusInfos", collect); + map.put("StationStatusInfos", StationStatusInfos); return ThirdPartyPlatformUtils.generateResultMap(map, ningBoSecretInfoVO); }