质安管理
This commit is contained in:
@ -183,9 +183,9 @@ public class DpzaglServiceImpl implements DpzaglService {
|
|||||||
// 质量展示数据
|
// 质量展示数据
|
||||||
// TableDataInfo<HseSafetyInspectionVo> anList = safetyInspectionService.queryPageList(req, pageQuery);
|
// TableDataInfo<HseSafetyInspectionVo> anList = safetyInspectionService.queryPageList(req, pageQuery);
|
||||||
// 质量展示数据-整改
|
// 质量展示数据-整改
|
||||||
req.setStatus(DpEnum.ZLGDZT_ZG.getTypeValue());
|
// req.setStatus(DpEnum.ZLGDZT_ZG.getTypeValue());
|
||||||
TableDataInfo<HseSafetyInspectionVo> aqZgList = safetyInspectionService.queryPageList(req, pageQuery);
|
// TableDataInfo<HseSafetyInspectionVo> aqZgList = safetyInspectionService.queryPageList(req, pageQuery);
|
||||||
// 质量总数(用于判断巡检类型)
|
// 安全总数(用于判断巡检类型)
|
||||||
List<HseSafetyInspection> list = safetyInspectionService.list(new LambdaQueryWrapper<HseSafetyInspection>().ge(bo.getStartDate() != null ,HseSafetyInspection::getCreateTime, bo.getStartDate()).le(bo.getEndDate() != null ,HseSafetyInspection::getCreateTime, bo.getEndDate()));
|
List<HseSafetyInspection> list = safetyInspectionService.list(new LambdaQueryWrapper<HseSafetyInspection>().ge(bo.getStartDate() != null ,HseSafetyInspection::getCreateTime, bo.getStartDate()).le(bo.getEndDate() != null ,HseSafetyInspection::getCreateTime, bo.getEndDate()));
|
||||||
|
|
||||||
// List<HseSafetyInspectionVo> rows = anList.getRows();
|
// List<HseSafetyInspectionVo> rows = anList.getRows();
|
||||||
@ -198,11 +198,14 @@ public class DpzaglServiceImpl implements DpzaglService {
|
|||||||
dpznglVo.setDqjcAq(list.stream().filter(zl -> DpEnum.ZLGLLX_DQJC.getTypeValue().equals(zl.getCheckType())).count());
|
dpznglVo.setDqjcAq(list.stream().filter(zl -> DpEnum.ZLGLLX_DQJC.getTypeValue().equals(zl.getCheckType())).count());
|
||||||
dpznglVo.setRcxjAq(list.stream().filter(zl -> DpEnum.ZLGLLX_RCXJ.getTypeValue().equals(zl.getCheckType())).count());
|
dpznglVo.setRcxjAq(list.stream().filter(zl -> DpEnum.ZLGLLX_RCXJ.getTypeValue().equals(zl.getCheckType())).count());
|
||||||
dpznglVo.setAqZgsl(list.stream().filter(zl -> DpEnum.ZLGDZT_ZG.getTypeValue().equals(zl.getStatus())).count());
|
dpznglVo.setAqZgsl(list.stream().filter(zl -> DpEnum.ZLGDZT_ZG.getTypeValue().equals(zl.getStatus())).count());
|
||||||
|
List<HseSafetyInspectionVo> convert = MapstructUtils.convert(list.stream().filter(zl -> DpEnum.ZLGDZT_ZG.getTypeValue().equals(zl.getStatus())).collect(Collectors.toList()), HseSafetyInspectionVo.class);
|
||||||
|
convert.forEach(zl ->{if (zl.getCorrectorId() != null)zl.setCorrectorName(userService.selectNicknameByIds(zl.getCorrectorId().toString()));});
|
||||||
|
dpznglVo.setAqZgList(convert);
|
||||||
}
|
}
|
||||||
if (aqZgList.getRows() != null && aqZgList.getRows().size() > 0){
|
// if (aqZgList.getRows() != null && aqZgList.getRows().size() > 0){
|
||||||
aqZgList.getRows().forEach(zl ->{if (zl.getCorrectorId() != null){zl.setCorrectorName(userService.selectNicknameByIds(zl.getCorrectorId().toString()));}});
|
// aqZgList.getRows().forEach(zl ->{if (zl.getCorrectorId() != null){zl.setCorrectorName(userService.selectNicknameByIds(zl.getCorrectorId().toString()));}});
|
||||||
dpznglVo.setAqZgList(aqZgList.getRows());
|
// dpznglVo.setAqZgList(aqZgList.getRows());
|
||||||
}
|
// }
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -215,8 +218,8 @@ public class DpzaglServiceImpl implements DpzaglService {
|
|||||||
//// 质量展示数据
|
//// 质量展示数据
|
||||||
// TableDataInfo<QltQualityInspectionVo> zlLists = qualityInspectionService.queryPageList(req, pageQuery);
|
// TableDataInfo<QltQualityInspectionVo> zlLists = qualityInspectionService.queryPageList(req, pageQuery);
|
||||||
// 质量展示数据-整改
|
// 质量展示数据-整改
|
||||||
req.setInspectionStatus(DpEnum.ZLGDZT_ZG.getTypeValue());
|
// req.setInspectionStatus(DpEnum.ZLGDZT_ZG.getTypeValue());
|
||||||
TableDataInfo<QltQualityInspectionVo> zlZgLists = qualityInspectionService.queryPageList(req, pageQuery);
|
// TableDataInfo<QltQualityInspectionVo> zlZgLists = qualityInspectionService.queryPageList(req, pageQuery);
|
||||||
// 质量总数
|
// 质量总数
|
||||||
List<QltQualityInspection> zsZl = qualityInspectionService.getBaseMapper()
|
List<QltQualityInspection> zsZl = qualityInspectionService.getBaseMapper()
|
||||||
.selectList(new LambdaQueryWrapper<QltQualityInspection>()
|
.selectList(new LambdaQueryWrapper<QltQualityInspection>()
|
||||||
@ -232,10 +235,10 @@ public class DpzaglServiceImpl implements DpzaglService {
|
|||||||
dpznglVo.setDqjcZl(zsZl.stream().filter(zl -> DpEnum.ZLGLLX_DQJC.getTypeValue().equals(zl.getInspectionType())).count());
|
dpznglVo.setDqjcZl(zsZl.stream().filter(zl -> DpEnum.ZLGLLX_DQJC.getTypeValue().equals(zl.getInspectionType())).count());
|
||||||
dpznglVo.setRcxjZl(zsZl.stream().filter(zl -> DpEnum.ZLGLLX_RCXJ.getTypeValue().equals(zl.getInspectionType())).count());
|
dpznglVo.setRcxjZl(zsZl.stream().filter(zl -> DpEnum.ZLGLLX_RCXJ.getTypeValue().equals(zl.getInspectionType())).count());
|
||||||
dpznglVo.setZlZgsl(zsZl.stream().filter(zl -> DpEnum.ZLGDZT_ZG.getTypeValue().equals(zl.getInspectionStatus())).count());
|
dpznglVo.setZlZgsl(zsZl.stream().filter(zl -> DpEnum.ZLGDZT_ZG.getTypeValue().equals(zl.getInspectionStatus())).count());
|
||||||
}
|
List<QltQualityInspection> collect = zsZl.stream().filter(zl -> DpEnum.ZLGDZT_ZG.getTypeValue().equals(zl.getInspectionStatus())).collect(Collectors.toList());
|
||||||
if (zlZgLists.getRows() != null && zlZgLists.getRows().size() > 0){
|
List<QltQualityInspectionVo> convert = MapstructUtils.convert(collect, QltQualityInspectionVo.class);
|
||||||
zlZgLists.getRows().forEach(zl ->{if (zl.getCorrectorId() != null){zl.setCorrectorName(userService.selectNicknameByIds(zl.getCorrectorId().toString()));}});
|
convert.forEach(zl ->{if (zl.getCorrectorId() != null)zl.setCorrectorName(userService.selectNicknameByIds(zl.getCorrectorId().toString()));});
|
||||||
dpznglVo.setZlZgList(zlZgLists.getRows());
|
dpznglVo.setZlZgList(convert);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -409,16 +409,16 @@ public class BigScreenWebSocketServer {
|
|||||||
|
|
||||||
DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM-dd", Locale.CHINA);
|
DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM-dd", Locale.CHINA);
|
||||||
|
|
||||||
|
|
||||||
if (StringUtils.isEmpty(startDate) || StringUtils.isEmpty(endDate)){
|
|
||||||
throw new RuntimeException("时间获取异常");
|
|
||||||
}
|
|
||||||
|
|
||||||
DpznglBo dpznglBo = new DpznglBo();
|
DpznglBo dpznglBo = new DpznglBo();
|
||||||
|
if (!StringUtils.isEmpty(startDate) && !StringUtils.isEmpty(endDate)){
|
||||||
dpznglBo.setStartDate(LocalDate.parse(startDate, formatter));
|
dpznglBo.setStartDate(LocalDate.parse(startDate, formatter));
|
||||||
dpznglBo.setEndDate(LocalDate.parse(endDate, formatter));
|
dpznglBo.setEndDate(LocalDate.parse(endDate, formatter));
|
||||||
|
|
||||||
|
}
|
||||||
dpznglBo.setProjectId(projectId);
|
dpznglBo.setProjectId(projectId);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// 查询大屏-质安管理-安全员分布情况
|
// 查询大屏-质安管理-安全员分布情况
|
||||||
|
|
||||||
List<DpznglAqyVo> dpznglAqyVos = dpzaglService.listByAqy(dpznglBo);
|
List<DpznglAqyVo> dpznglAqyVos = dpzaglService.listByAqy(dpznglBo);
|
||||||
|
|||||||
Reference in New Issue
Block a user