|
@@ -4,6 +4,7 @@ import cn.hutool.core.util.ObjectUtil;
|
|
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
|
|
import com.jiayue.biz.domain.*;
|
|
|
import com.jiayue.biz.dto.EquipmentDto;
|
|
|
+import com.jiayue.biz.dto.ProjectEvolveDto;
|
|
|
import com.jiayue.biz.dto.ProjectInfoDto;
|
|
|
import com.jiayue.biz.dto.SelectLabForVal;
|
|
|
import com.jiayue.biz.eunms.WindDirectionEnum;
|
|
@@ -763,7 +764,6 @@ public class HomePageServiceImpl extends ServiceImpl<WindTowerDataParentTableMap
|
|
|
//测风塔坐标
|
|
|
dataMap.put("towerInfo", arrayList);
|
|
|
}
|
|
|
- //项目中所有的塔、拐点坐标、 TODO 地图四个角信息
|
|
|
return dataMap;
|
|
|
}
|
|
|
|
|
@@ -870,15 +870,15 @@ public class HomePageServiceImpl extends ServiceImpl<WindTowerDataParentTableMap
|
|
|
}
|
|
|
//过滤塔信息
|
|
|
List<Equipment> equipmentList = stationInfoList.get(0).getEquipment();
|
|
|
- ArrayList<HashMap<String,String>> towerList = new ArrayList<>();
|
|
|
- if(equipmentList.size() > 0 ){
|
|
|
+ ArrayList<HashMap<String, String>> towerList = new ArrayList<>();
|
|
|
+ if (equipmentList.size() > 0) {
|
|
|
for (Equipment equipment : equipmentList) {
|
|
|
HashMap<String, String> towerMap = new HashMap<>();
|
|
|
- towerMap.put("name",equipment.getName());
|
|
|
- towerMap.put("towerId",equipment.getId());
|
|
|
- towerMap.put("equipmentNo",equipment.getEquipmentNo());
|
|
|
- towerMap.put("longitude",equipment.getLongitude());
|
|
|
- towerMap.put("latitude",equipment.getLatitude());
|
|
|
+ towerMap.put("name", equipment.getName());
|
|
|
+ towerMap.put("towerId", equipment.getId());
|
|
|
+ towerMap.put("equipmentNo", equipment.getEquipmentNo());
|
|
|
+ towerMap.put("longitude", equipment.getLongitude());
|
|
|
+ towerMap.put("latitude", equipment.getLatitude());
|
|
|
towerList.add(towerMap);
|
|
|
}
|
|
|
|
|
@@ -891,4 +891,92 @@ public class HomePageServiceImpl extends ServiceImpl<WindTowerDataParentTableMap
|
|
|
return dataMap;
|
|
|
}
|
|
|
|
|
|
+ /**
|
|
|
+ * 场站测风塔下拉框
|
|
|
+ *
|
|
|
+ * @return List<SelectLabForVal>
|
|
|
+ */
|
|
|
+ public List<SelectLabForVal> stationSelect() {
|
|
|
+ List<StationInfo> stationInfoList = stationInfoService.selectStationInfo();
|
|
|
+ ArrayList<SelectLabForVal> selectList = new ArrayList<>();
|
|
|
+ if (stationInfoList.size() > 0) {
|
|
|
+ //循环数据 放入项目id和项目名称
|
|
|
+ for (StationInfo stationInfo : stationInfoList) {
|
|
|
+ SelectLabForVal selectLabForVal = new SelectLabForVal();
|
|
|
+ selectLabForVal.setLabel(stationInfo.getStationBasicInfo().getStationName());
|
|
|
+ selectLabForVal.setValue(stationInfo.getId());
|
|
|
+ if (stationInfo.getEquipment().size() > 0) {
|
|
|
+ ArrayList<EquipmentDto> equipmentDtoList = new ArrayList<>();
|
|
|
+ //循环数据 放入测风塔id和测风塔名称
|
|
|
+ for (Equipment equipment : stationInfo.getEquipment()) {
|
|
|
+ EquipmentDto equipmentDto = new EquipmentDto();
|
|
|
+ equipmentDto.setLabel(equipment.getName());
|
|
|
+ equipmentDto.setValue(equipment.getId());
|
|
|
+ equipmentDtoList.add(equipmentDto);
|
|
|
+ }
|
|
|
+ selectLabForVal.setEquipmentDto(equipmentDtoList);
|
|
|
+ }
|
|
|
+ selectList.add(selectLabForVal);
|
|
|
+ }
|
|
|
+
|
|
|
+ }
|
|
|
+
|
|
|
+ return selectList;
|
|
|
+ }
|
|
|
+
|
|
|
+ //项目进展
|
|
|
+ public List<ProjectEvolveDto> getProjectEvolve(String projectId) {
|
|
|
+ //查询项目进展信息
|
|
|
+ List<ProjectProgress> projectProgresses = proProjectInfoService.selectProProjectInfo();
|
|
|
+ //根据项目id筛选数据
|
|
|
+ List<ProjectProgress> progressList = projectProgresses.stream().filter(p -> p.getProjectId().equals(projectId)).collect(Collectors.toList());
|
|
|
+ ArrayList<ProjectEvolveDto> projectEvolveList = new ArrayList<>();
|
|
|
+ if (progressList.size() > 0) {
|
|
|
+ //循环项目进展信息 一般只有一条
|
|
|
+ for (ProjectProgress progress : progressList) {
|
|
|
+ if (progress.getProjectMenusOneList().size() > 0) {
|
|
|
+ //循环一级菜单
|
|
|
+ for (ProjectMenusOne menusOne : progress.getProjectMenusOneList()) {
|
|
|
+ ProjectEvolveDto projectEvolveDtoOne = new ProjectEvolveDto();
|
|
|
+ //一级菜单
|
|
|
+ projectEvolveDtoOne.setIndex(menusOne.getIndex());
|
|
|
+ projectEvolveDtoOne.setTaskContent(menusOne.getWorkContent());
|
|
|
+ projectEvolveDtoOne.setPlanTime(menusOne.getPlanTime());
|
|
|
+ projectEvolveDtoOne.setStatus(menusOne.getStatus());
|
|
|
+ projectEvolveList.add(projectEvolveDtoOne);
|
|
|
+
|
|
|
+ if (menusOne.getProjectMenusTows() != null && menusOne.getProjectMenusTows().size() > 0) {
|
|
|
+ //循环二级菜单
|
|
|
+ for (ProjectMenusTow menusTow : menusOne.getProjectMenusTows()) {
|
|
|
+ if (menusTow.getProjectMenusThreeList() != null && menusTow.getProjectMenusThreeList().size() > 0) {
|
|
|
+ //循环三级菜单
|
|
|
+ for (ProjectMenusThree menusThree : menusTow.getProjectMenusThreeList()) {
|
|
|
+ ProjectEvolveDto projectEvolveDto = new ProjectEvolveDto();
|
|
|
+ //放入二级序号
|
|
|
+ projectEvolveDto.setIndex(menusTow.getIndex());
|
|
|
+ //放入二级计划时间
|
|
|
+ projectEvolveDto.setPlanTime(menusOne.getPlanTime());
|
|
|
+ //放入二级工作内容
|
|
|
+ projectEvolveDto.setTaskContent(menusTow.getWorkContent());
|
|
|
+ //详细工作信息 三级工作内容
|
|
|
+ projectEvolveDto.setDetailedTaskContent(menusThree.getWorkContent());
|
|
|
+ //实际完成时间 三级时间
|
|
|
+ projectEvolveDto.setRealTime(menusThree.getRealTime());
|
|
|
+ //放入状态 三级备注
|
|
|
+ projectEvolveDto.setStatus(menusThree.getRemark());
|
|
|
+ projectEvolveList.add(projectEvolveDto);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ }
|
|
|
+ }
|
|
|
+ return projectEvolveList;
|
|
|
+
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
}
|