Browse Source

Merge branch 'master' of http://81.69.34.200:3000/467010279/water-monitor-api

 Conflicts:
	ruoyi-api/src/main/java/com/ruoyi/api/service/impl/DapingServiceImpl.java
master
4670101279 2 years ago
parent
commit
1a704d3bd9
  1. 18
      ruoyi-api/src/main/java/com/ruoyi/api/service/impl/DapingServiceImpl.java

18
ruoyi-api/src/main/java/com/ruoyi/api/service/impl/DapingServiceImpl.java

@ -5,10 +5,13 @@ import com.ruoyi.api.mapper.DapingMapper;
import com.ruoyi.api.service.DapingService; import com.ruoyi.api.service.DapingService;
import com.ruoyi.code.camera.domain.WaterPhotoInfo; import com.ruoyi.code.camera.domain.WaterPhotoInfo;
import com.ruoyi.common.core.page.R; import com.ruoyi.common.core.page.R;
import com.ruoyi.common.utils.StringUtils;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import java.util.*; import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.stream.Collectors;
@Service @Service
public class DapingServiceImpl extends ServiceImpl<DapingMapper, WaterPhotoInfo> implements DapingService{ public class DapingServiceImpl extends ServiceImpl<DapingMapper, WaterPhotoInfo> implements DapingService{
@ -18,11 +21,12 @@ public class DapingServiceImpl extends ServiceImpl<DapingMapper, WaterPhotoInfo>
*/ */
@Override @Override
public List<WaterPhotoInfo> getStationInfo() { public List<WaterPhotoInfo> getStationInfo() {
List<WaterPhotoInfo> list = baseMapper.selectStationInfo(); return baseMapper.selectStationInfo().stream().filter(waterPhotoInfo -> {
for (WaterPhotoInfo waterPhotoInfo : list) { String imgName = waterPhotoInfo.getImgName();
waterPhotoInfo.setImgName(waterPhotoInfo.getImgName().replace("\\","/")); String img = imgName.replace("\\", "/");
} waterPhotoInfo.setImgName(img);
return list; return true;
}).collect(Collectors.toList());
} }
/** /**

Loading…
Cancel
Save