指标分类-监测点分类只统计当前部门信息
This commit is contained in:
@@ -22,14 +22,12 @@ import com.njcn.harmonic.pojo.vo.RIconVO;
|
||||
import com.njcn.harmonic.pojo.vo.RStatHarmonicMVO;
|
||||
import com.njcn.harmonic.service.majornetwork.RStatHarmonicMService;
|
||||
import com.njcn.device.pq.utils.PublicDateUtil;
|
||||
import com.njcn.harmonic.utils.DeptUtil;
|
||||
import com.njcn.system.api.DicDataFeignClient;
|
||||
import com.njcn.system.enums.DicDataEnum;
|
||||
import com.njcn.system.enums.DicDataTypeEnum;
|
||||
import com.njcn.system.pojo.po.DictData;
|
||||
import com.njcn.user.api.DeptFeignClient;
|
||||
import com.njcn.user.pojo.dto.DeptDTO;
|
||||
import com.njcn.web.utils.WebUtil;
|
||||
import com.njcn.user.pojo.po.Dept;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import lombok.SneakyThrows;
|
||||
import org.springframework.stereotype.Service;
|
||||
@@ -77,13 +75,10 @@ public class RStatHarmonicMServiceImpl extends ServiceImpl<RStatHarmonicMMapper,
|
||||
DictData mainnetData = dicDataFeignClient.getDicDataByCode(DicDataEnum.MAINNET_POINT.getCode()).getData();
|
||||
|
||||
|
||||
//获取当前部门下所有部门信息
|
||||
List<DeptDTO> deptList = deptFeignClient.getDeptDescendantIndexes(param.getId(), WebUtil.filterDeptType()).getData();
|
||||
List<DeptDTO> deptDTOList = DeptUtil.getDeptSubsetVOList(deptList, param.getId());
|
||||
List<String> deptIds = deptDTOList.stream().map(DeptDTO::getCode).collect(Collectors.toList());
|
||||
|
||||
//获取当前部门信息
|
||||
Dept dept = deptFeignClient.getDeptById(param.getId()).getData();
|
||||
StatSubstationBizBaseParam baseParam = BeanUtil.copyProperties(param, StatSubstationBizBaseParam.class);
|
||||
baseParam.setIds(deptIds);
|
||||
baseParam.setIds(Collections.singletonList(dept.getCode()));
|
||||
//数据库查询
|
||||
List<RStatHarmonicM> list = rStatHarmonicMMapper.selectInfoList(baseParam, mainnetData.getId());
|
||||
|
||||
@@ -199,12 +194,9 @@ public class RStatHarmonicMServiceImpl extends ServiceImpl<RStatHarmonicMMapper,
|
||||
List<RIconVO> arrayVOList = new ArrayList<>();
|
||||
|
||||
//获取当前部门下所有部门信息
|
||||
List<DeptDTO> deptList = deptFeignClient.getDeptDescendantIndexes(param.getId(), WebUtil.filterDeptType()).getData();
|
||||
List<DeptDTO> deptDTOList = DeptUtil.getDeptSubsetVOList(deptList, param.getId());
|
||||
List<String> deptIds = deptDTOList.stream().map(DeptDTO::getCode).collect(Collectors.toList());
|
||||
|
||||
Dept dept = deptFeignClient.getDeptById(param.getId()).getData();
|
||||
StatSubstationBizBaseParam baseParam = BeanUtil.copyProperties(param, StatSubstationBizBaseParam.class);
|
||||
baseParam.setIds(deptIds);
|
||||
baseParam.setIds(Collections.singletonList(dept.getCode()));
|
||||
//数据库查询
|
||||
List<RStatHarmonicVoltageM> rStatHarmonicVoltageMS = rStatHarmonicVoltageMMapper
|
||||
.selectInfoList(baseParam, mainnetData.getId(), measurementDate.getId(), harmonicDate.getId());
|
||||
@@ -291,13 +283,10 @@ public class RStatHarmonicMServiceImpl extends ServiceImpl<RStatHarmonicMMapper,
|
||||
//获取主网id信息
|
||||
DictData mainnetData = dicDataFeignClient.getDicDataByCode(DicDataEnum.MAINNET_POINT.getCode()).getData();
|
||||
|
||||
//获取当前部门下所有部门信息
|
||||
List<DeptDTO> deptList = deptFeignClient.getDeptDescendantIndexes(param.getId(), WebUtil.filterDeptType()).getData();
|
||||
List<DeptDTO> deptDTOList = DeptUtil.getDeptSubsetVOList(deptList, param.getId());
|
||||
List<String> deptIds = deptDTOList.stream().map(DeptDTO::getCode).collect(Collectors.toList());
|
||||
|
||||
//获取当前部门
|
||||
Dept dept = deptFeignClient.getDeptById(param.getId()).getData();
|
||||
StatSubstationBizBaseParam baseParam = BeanUtil.copyProperties(param, StatSubstationBizBaseParam.class);
|
||||
baseParam.setIds(deptIds);
|
||||
baseParam.setIds(Collections.singletonList(dept.getCode()));
|
||||
//数据库查询
|
||||
List<RStatHarmonicD> rStatHarmonicVoltageMS = rStatHarmonicDMapper
|
||||
.selectInfoList(baseParam, mainnetData.getId(), measurementDate.getId(), harmonicDate.getId());
|
||||
@@ -359,12 +348,10 @@ public class RStatHarmonicMServiceImpl extends ServiceImpl<RStatHarmonicMMapper,
|
||||
List<RArrayVO> arrayVOList = new ArrayList<>();
|
||||
|
||||
//获取当前部门下所有部门信息
|
||||
List<DeptDTO> deptList = deptFeignClient.getDeptDescendantIndexes(param.getId(), WebUtil.filterDeptType()).getData();
|
||||
List<DeptDTO> deptDTOList = DeptUtil.getDeptSubsetVOList(deptList, param.getId());
|
||||
List<String> deptIds = deptDTOList.stream().map(DeptDTO::getCode).collect(Collectors.toList());
|
||||
|
||||
//获取当前部门
|
||||
Dept dept = deptFeignClient.getDeptById(param.getId()).getData();
|
||||
StatSubstationBizBaseParam baseParam = BeanUtil.copyProperties(param, StatSubstationBizBaseParam.class);
|
||||
baseParam.setIds(deptIds);
|
||||
baseParam.setIds(Collections.singletonList(dept.getCode()));
|
||||
//数据库查询
|
||||
List<RStatHarmonicM> list = rStatHarmonicMMapper.selectInfoList(baseParam, distributionData.getId());
|
||||
|
||||
@@ -455,13 +442,10 @@ public class RStatHarmonicMServiceImpl extends ServiceImpl<RStatHarmonicMMapper,
|
||||
//获取配网信息
|
||||
DictData distributionData = dicDataFeignClient.getDicDataByCode(DicDataEnum.DISTRIBUTION_POINT.getCode()).getData();
|
||||
|
||||
//获取当前部门下所有部门信息
|
||||
List<DeptDTO> deptList = deptFeignClient.getDeptDescendantIndexes(param.getId(), WebUtil.filterDeptType()).getData();
|
||||
List<DeptDTO> deptDTOList = DeptUtil.getDeptSubsetVOList(deptList, param.getId());
|
||||
List<String> deptIds = deptDTOList.stream().map(DeptDTO::getCode).collect(Collectors.toList());
|
||||
|
||||
//获取当前部门
|
||||
Dept dept = deptFeignClient.getDeptById(param.getId()).getData();
|
||||
StatSubstationBizBaseParam baseParam = BeanUtil.copyProperties(param, StatSubstationBizBaseParam.class);
|
||||
baseParam.setIds(deptIds);
|
||||
baseParam.setIds(Collections.singletonList(dept.getCode()));
|
||||
//数据库查询
|
||||
List<RStatHarmonicD> rStatHarmonicVoltageMS = rStatHarmonicDMapper
|
||||
.selectInfoList(baseParam, distributionData.getId(), measurementDate.getId(), harmonicDate.getId());
|
||||
|
||||
@@ -10,14 +10,12 @@ import com.njcn.harmonic.pojo.po.RStatHarmonicQ;
|
||||
import com.njcn.harmonic.pojo.vo.RArrayVO;
|
||||
import com.njcn.harmonic.pojo.vo.RStatHarmonicMVO;
|
||||
import com.njcn.harmonic.service.majornetwork.RStatHarmonicQService;
|
||||
import com.njcn.harmonic.utils.DeptUtil;
|
||||
import com.njcn.system.api.DicDataFeignClient;
|
||||
import com.njcn.system.enums.DicDataEnum;
|
||||
import com.njcn.system.enums.DicDataTypeEnum;
|
||||
import com.njcn.system.pojo.po.DictData;
|
||||
import com.njcn.user.api.DeptFeignClient;
|
||||
import com.njcn.user.pojo.dto.DeptDTO;
|
||||
import com.njcn.web.utils.WebUtil;
|
||||
import com.njcn.user.pojo.po.Dept;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
@@ -58,12 +56,9 @@ public class RStatHarmonicQServiceImpl extends ServiceImpl<RStatHarmonicQMapper,
|
||||
DictData mainnetData = dicDataFeignClient.getDicDataByCode(DicDataEnum.MAINNET_POINT.getCode()).getData();
|
||||
|
||||
//获取当前部门下所有部门信息
|
||||
List<DeptDTO> deptList = deptFeignClient.getDeptDescendantIndexes(param.getId(), WebUtil.filterDeptType()).getData();
|
||||
List<DeptDTO> deptDTOList = DeptUtil.getDeptSubsetVOList(deptList, param.getId());
|
||||
List<String> deptIds = deptDTOList.stream().map(DeptDTO::getCode).collect(Collectors.toList());
|
||||
|
||||
Dept dept = deptFeignClient.getDeptById(param.getId()).getData();
|
||||
StatSubstationBizBaseParam baseParam = BeanUtil.copyProperties(param, StatSubstationBizBaseParam.class);
|
||||
baseParam.setIds(deptIds);
|
||||
baseParam.setIds(Collections.singletonList(dept.getCode()));
|
||||
//数据库查询
|
||||
List<RStatHarmonicQ> list = rStatHarmonicQMapper.selectInfoList(baseParam, mainnetData.getId());
|
||||
|
||||
@@ -150,13 +145,10 @@ public class RStatHarmonicQServiceImpl extends ServiceImpl<RStatHarmonicQMapper,
|
||||
DictData distributionData = dicDataFeignClient.getDicDataByCode(DicDataEnum.DISTRIBUTION_POINT.getCode()).getData();
|
||||
//初始化指标类型(横向)
|
||||
List<RArrayVO> arrayVOList = new ArrayList<>();
|
||||
//获取当前部门下所有部门信息
|
||||
List<DeptDTO> deptList = deptFeignClient.getDeptDescendantIndexes(param.getId(), WebUtil.filterDeptType()).getData();
|
||||
List<DeptDTO> deptDTOList = DeptUtil.getDeptSubsetVOList(deptList, param.getId());
|
||||
List<String> deptIds = deptDTOList.stream().map(DeptDTO::getCode).collect(Collectors.toList());
|
||||
|
||||
//获取当前部门
|
||||
Dept dept = deptFeignClient.getDeptById(param.getId()).getData();
|
||||
StatSubstationBizBaseParam baseParam = BeanUtil.copyProperties(param, StatSubstationBizBaseParam.class);
|
||||
baseParam.setIds(deptIds);
|
||||
baseParam.setIds(Collections.singletonList(dept.getCode()));
|
||||
//数据库查询
|
||||
List<RStatHarmonicQ> list = rStatHarmonicQMapper.selectInfoList(baseParam, distributionData.getId());
|
||||
|
||||
|
||||
@@ -10,14 +10,12 @@ import com.njcn.harmonic.pojo.po.RStatHarmonicY;
|
||||
import com.njcn.harmonic.pojo.vo.RArrayVO;
|
||||
import com.njcn.harmonic.pojo.vo.RStatHarmonicMVO;
|
||||
import com.njcn.harmonic.service.majornetwork.RStatHarmonicYService;
|
||||
import com.njcn.harmonic.utils.DeptUtil;
|
||||
import com.njcn.system.api.DicDataFeignClient;
|
||||
import com.njcn.system.enums.DicDataEnum;
|
||||
import com.njcn.system.enums.DicDataTypeEnum;
|
||||
import com.njcn.system.pojo.po.DictData;
|
||||
import com.njcn.user.api.DeptFeignClient;
|
||||
import com.njcn.user.pojo.dto.DeptDTO;
|
||||
import com.njcn.web.utils.WebUtil;
|
||||
import com.njcn.user.pojo.po.Dept;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
@@ -57,13 +55,9 @@ public class RStatHarmonicYServiceImpl extends ServiceImpl<RStatHarmonicYMapper,
|
||||
DictData mainnetData = dicDataFeignClient.getDicDataByCode(DicDataEnum.MAINNET_POINT.getCode()).getData();
|
||||
|
||||
//获取当前部门下所有部门信息
|
||||
List<DeptDTO> deptList = deptFeignClient.getDeptDescendantIndexes(param.getId(), WebUtil.filterDeptType()).getData();
|
||||
List<DeptDTO> deptDTOList = DeptUtil.getDeptSubsetVOList(deptList, param.getId());
|
||||
|
||||
List<String> deptIds = deptDTOList.stream().map(DeptDTO::getCode).collect(Collectors.toList());
|
||||
|
||||
Dept dept = deptFeignClient.getDeptById(param.getId()).getData();
|
||||
StatSubstationBizBaseParam baseParam = BeanUtil.copyProperties(param, StatSubstationBizBaseParam.class);
|
||||
baseParam.setIds(deptIds);
|
||||
baseParam.setIds(Collections.singletonList(dept.getCode()));
|
||||
//数据库查询
|
||||
List<RStatHarmonicY> list = rStatHarmonicYMapper.selectInfoList(baseParam, mainnetData.getId());
|
||||
|
||||
@@ -152,13 +146,10 @@ public class RStatHarmonicYServiceImpl extends ServiceImpl<RStatHarmonicYMapper,
|
||||
//初始化指标类型(横向)
|
||||
List<RArrayVO> arrayVOList = new ArrayList<>();
|
||||
|
||||
//获取当前部门下所有部门信息
|
||||
List<DeptDTO> deptList = deptFeignClient.getDeptDescendantIndexes(param.getId(), WebUtil.filterDeptType()).getData();
|
||||
List<DeptDTO> deptDTOList = DeptUtil.getDeptSubsetVOList(deptList, param.getId());
|
||||
List<String> deptIds = deptDTOList.stream().map(DeptDTO::getCode).collect(Collectors.toList());
|
||||
|
||||
//获取当前部门
|
||||
Dept dept = deptFeignClient.getDeptById(param.getId()).getData();
|
||||
StatSubstationBizBaseParam baseParam = BeanUtil.copyProperties(param, StatSubstationBizBaseParam.class);
|
||||
baseParam.setIds(deptIds);
|
||||
baseParam.setIds(Collections.singletonList(dept.getCode()));
|
||||
//数据库查询
|
||||
List<RStatHarmonicY> list = rStatHarmonicYMapper.selectInfoList(baseParam, distributionData.getId());
|
||||
|
||||
|
||||
Reference in New Issue
Block a user