diff --git a/src/main/java/com/xkrs/controller/DispatchFirePointController.java b/src/main/java/com/xkrs/controller/DispatchFirePointController.java index 9d9d4aa..4139697 100644 --- a/src/main/java/com/xkrs/controller/DispatchFirePointController.java +++ b/src/main/java/com/xkrs/controller/DispatchFirePointController.java @@ -66,13 +66,11 @@ public class DispatchFirePointController { // sysUserDao.save(sysUserEntity); // } - //310 0000 - - for (int i = 0; i < 10000; i++) { - firePointOrdinaryDao.updateProCityCode(i * 310L, (i + 1) * 310L); - firePointOrdinaryDao.updateProCityName(i * 310L, (i + 1) * 310L); - System.out.println(i + "/" + 10000); - } +// for (int i = 0; i < 10000; i++) { +// firePointOrdinaryDao.updateProCityCode(i * 310L, (i + 1) * 310L); +// firePointOrdinaryDao.updateProCityName(i * 310L, (i + 1) * 310L); +// System.out.println(i + "/" + 10000); +// } return outputEncapsulationObject(PromptMessageEnum.SUCCESS, "OKKKK", locale); } diff --git a/src/main/java/com/xkrs/service/impl/DispatchFirePointServiceImpl.java b/src/main/java/com/xkrs/service/impl/DispatchFirePointServiceImpl.java index 27952a0..11228da 100644 --- a/src/main/java/com/xkrs/service/impl/DispatchFirePointServiceImpl.java +++ b/src/main/java/com/xkrs/service/impl/DispatchFirePointServiceImpl.java @@ -179,19 +179,19 @@ public class DispatchFirePointServiceImpl implements DispatchFirePointService { }; //根据fireCode找到火点 List firePointList = firePointOrdinaryDao.findAll(specification); - if (firePointList.size() == 1) { - FirePointOrdinaryEntity firePoint = firePointList.get(0); + for (FirePointOrdinaryEntity firePoint : firePointList) { firePoint.setFireStatus(status);//设置火点的研判标志属性 firePointOrdinaryDao.save(firePoint);//数据库保存 - } else { - ErrorInfoLogUtils.log("操作异常,审核系统发送的fireCode在秸秆系统中size() != 1:fireCode = " + fireCode + ",status = " + fireCode); + } + if (firePointList.size() != 1) { + ErrorInfoLogUtils.log("item 更新成功。数据异常,审核系统发送的fireCode在秸秆系统中size() != 1:fireCode = " + fireCode + ",status = " + fireCode); } } catch (Exception e) { e.printStackTrace(); - return outputEncapsulationObject(PromptMessageEnum.PROCESS_FAIL, "更新失败", locale); + return outputEncapsulationObject(PromptMessageEnum.PROCESS_FAIL, "item 更新失败", locale); } } - return outputEncapsulationObject(PromptMessageEnum.SUCCESS, "更新成功", locale); + return outputEncapsulationObject(PromptMessageEnum.SUCCESS, "for 更新成功", locale); } }