|  | @@ -109,7 +109,9 @@ public class BscEnterpriseScreenServiceImpl extends AbstractCrudService<BscEnter
 | 
											
												
													
														|  |              default:
 |  |              default:
 | 
											
												
													
														|  |                  throw new BusinessException("参数错误");
 |  |                  throw new BusinessException("参数错误");
 | 
											
												
													
														|  |          }
 |  |          }
 | 
											
												
													
														|  | -        queryWrapper.eq(BscEnterpriseScreen::getCompanyId, companyId);
 |  | 
 | 
											
												
													
														|  | 
 |  | +        queryWrapper.eq(BscEnterpriseScreen::getCompanyId, companyId)
 | 
											
												
													
														|  | 
 |  | +                .orderByDesc(BscEnterpriseScreen::getId)
 | 
											
												
													
														|  | 
 |  | +                .last(" limit 1");
 | 
											
												
													
														|  |          List<BscEnterpriseScreen> list = this.list(queryWrapper);
 |  |          List<BscEnterpriseScreen> list = this.list(queryWrapper);
 | 
											
												
													
														|  |          Object data = null;
 |  |          Object data = null;
 | 
											
												
													
														|  |          if (CollectionUtils.isNotEmpty(list)) {
 |  |          if (CollectionUtils.isNotEmpty(list)) {
 | 
											
										
											
												
													
														|  | @@ -150,7 +152,7 @@ public class BscEnterpriseScreenServiceImpl extends AbstractCrudService<BscEnter
 | 
											
												
													
														|  |                  Object hiddenDangerStatistics = this.hiddenDangerStatistics(baseCompanies.get(i).getCompanyId());
 |  |                  Object hiddenDangerStatistics = this.hiddenDangerStatistics(baseCompanies.get(i).getCompanyId());
 | 
											
												
													
														|  |                  Object buildScoreStatistics = this.buildScoreStatistics(baseCompanies.get(i).getCompanyId());
 |  |                  Object buildScoreStatistics = this.buildScoreStatistics(baseCompanies.get(i).getCompanyId());
 | 
											
												
													
														|  |                  Object patrolInspectionStatistics = this.patrolInspectionStatistics(baseCompanies.get(i).getCompanyId());
 |  |                  Object patrolInspectionStatistics = this.patrolInspectionStatistics(baseCompanies.get(i).getCompanyId());
 | 
											
												
													
														|  | -                List<BscEnterpriseScreen> list = this.bscEnterpriseScreenCount(baseCompanies.get(i).getCompanyId());
 |  | 
 | 
											
												
													
														|  | 
 |  | +//                List<BscEnterpriseScreen> list = this.bscEnterpriseScreenCount(baseCompanies.get(i).getCompanyId());
 | 
											
												
													
														|  |                  BscEnterpriseScreen bscEnterpriseScreen = new BscEnterpriseScreen();
 |  |                  BscEnterpriseScreen bscEnterpriseScreen = new BscEnterpriseScreen();
 | 
											
												
													
														|  |                  bscEnterpriseScreen.setCompanyId(baseCompanies.get(i).getCompanyId());
 |  |                  bscEnterpriseScreen.setCompanyId(baseCompanies.get(i).getCompanyId());
 | 
											
												
													
														|  |                  bscEnterpriseScreen.setCreateTime(LocalDateTime.now());
 |  |                  bscEnterpriseScreen.setCreateTime(LocalDateTime.now());
 | 
											
										
											
												
													
														|  | @@ -160,12 +162,7 @@ public class BscEnterpriseScreenServiceImpl extends AbstractCrudService<BscEnter
 | 
											
												
													
														|  |                  bscEnterpriseScreen.setReservePlan(JSON.toJSONString(reservePlanStatistics));
 |  |                  bscEnterpriseScreen.setReservePlan(JSON.toJSONString(reservePlanStatistics));
 | 
											
												
													
														|  |                  bscEnterpriseScreen.setHiddenDanger(JSON.toJSONString(hiddenDangerStatistics));
 |  |                  bscEnterpriseScreen.setHiddenDanger(JSON.toJSONString(hiddenDangerStatistics));
 | 
											
												
													
														|  |                  bscEnterpriseScreen.setBuildScore(JSON.toJSONString(buildScoreStatistics));
 |  |                  bscEnterpriseScreen.setBuildScore(JSON.toJSONString(buildScoreStatistics));
 | 
											
												
													
														|  | -                if (CollectionUtils.isNotEmpty(list)) {
 |  | 
 | 
											
												
													
														|  | -                    bscEnterpriseScreen.setId(list.get(0).getId());
 |  | 
 | 
											
												
													
														|  | -                    this.updateById(bscEnterpriseScreen);
 |  | 
 | 
											
												
													
														|  | -                } else {
 |  | 
 | 
											
												
													
														|  | -                    this.save(bscEnterpriseScreen);
 |  | 
 | 
											
												
													
														|  | -                }
 |  | 
 | 
											
												
													
														|  | 
 |  | +                this.save(bscEnterpriseScreen);
 | 
											
												
													
														|  |              }
 |  |              }
 | 
											
												
													
														|  |              SimpleDateFormat format = new SimpleDateFormat("yyyy-MM");
 |  |              SimpleDateFormat format = new SimpleDateFormat("yyyy-MM");
 | 
											
												
													
														|  |              long timeStamp = OnlineMethod.getLastPeroid(2, new Date());
 |  |              long timeStamp = OnlineMethod.getLastPeroid(2, new Date());
 | 
											
										
											
												
													
														|  | @@ -196,7 +193,7 @@ public class BscEnterpriseScreenServiceImpl extends AbstractCrudService<BscEnter
 | 
											
												
													
														|  |      }
 |  |      }
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  |      @Override
 |  |      @Override
 | 
											
												
													
														|  | -    public List<DataVo> Alarmlist(){
 |  | 
 | 
											
												
													
														|  | 
 |  | +    public List<DataVo> Alarmlist() {
 | 
											
												
													
														|  |          List<DataVo> list = new ArrayList<>();
 |  |          List<DataVo> list = new ArrayList<>();
 | 
											
												
													
														|  |          List<DataVo> alarmlist = alarmElectricalFireService.Alarmlist();
 |  |          List<DataVo> alarmlist = alarmElectricalFireService.Alarmlist();
 | 
											
												
													
														|  |          List<DataVo> alarmlist1 = alarmFireService.Alarmlist();
 |  |          List<DataVo> alarmlist1 = alarmFireService.Alarmlist();
 | 
											
										
											
												
													
														|  | @@ -236,7 +233,9 @@ public class BscEnterpriseScreenServiceImpl extends AbstractCrudService<BscEnter
 | 
											
												
													
														|  |      public List<BscEnterpriseScreen> bscEnterpriseScreenCount(String companyId) {
 |  |      public List<BscEnterpriseScreen> bscEnterpriseScreenCount(String companyId) {
 | 
											
												
													
														|  |          LambdaQueryWrapper<BscEnterpriseScreen> queryWrapper = Wrappers.lambdaQuery();
 |  |          LambdaQueryWrapper<BscEnterpriseScreen> queryWrapper = Wrappers.lambdaQuery();
 | 
											
												
													
														|  |          queryWrapper.select(BscEnterpriseScreen::getId, BscEnterpriseScreen::getBuildScore)
 |  |          queryWrapper.select(BscEnterpriseScreen::getId, BscEnterpriseScreen::getBuildScore)
 | 
											
												
													
														|  | -                .eq(BscEnterpriseScreen::getCompanyId, companyId);
 |  | 
 | 
											
												
													
														|  | 
 |  | +                .eq(BscEnterpriseScreen::getCompanyId, companyId)
 | 
											
												
													
														|  | 
 |  | +                .orderByDesc(BscEnterpriseScreen::getId)
 | 
											
												
													
														|  | 
 |  | +                .last(" limit 1");
 | 
											
												
													
														|  |          List<BscEnterpriseScreen> list = this.list(queryWrapper);
 |  |          List<BscEnterpriseScreen> list = this.list(queryWrapper);
 | 
											
												
													
														|  |          return list;
 |  |          return list;
 | 
											
												
													
														|  |      }
 |  |      }
 |