| 
					
				 | 
			
			
				@@ -87,6 +87,7 @@ public class InstallListServiceImpl implements InstallListService { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         if (deviceMapper.findByMeterNoUnique(dto.getDeviceId(), dto.getMeterNo()) > 0) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             throw BusinessException.builder(RmcpErrorEnum.RMCP_METER_NO_UNIQUE_ERROR); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        InstallList install = installListMapper.findById(dto.getId()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         if (dto.getDeviceId() != null) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             //更新设备 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             Device update = new Device(); 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -111,7 +112,7 @@ public class InstallListServiceImpl implements InstallListService { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             installList.setDeviceId(dto.getDeviceId()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             this.updateByPrimaryKeySelective(installList); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         }else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            InstallList install = installListMapper.findById(dto.getId()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             InstallPlan installPlan = installPlanMapper.findById(install.getInstallPlanId()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             Product product = productMapper.findById(installPlan.getProductId()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             Device device = new Device(); 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -145,6 +146,8 @@ public class InstallListServiceImpl implements InstallListService { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             installList.setDeviceId(device.getId()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             this.updateByPrimaryKeySelective(installList); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        //更新安装计划状态 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        installPlanMapper.updatePlanStatus(install.getInstallPlanId()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         log.info("end installSave"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -276,7 +279,11 @@ public class InstallListServiceImpl implements InstallListService { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         installList.setIsInstalled(1); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         installList.setDeviceId(device.getId()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         this.updateByPrimaryKeySelective(installList); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        return null; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        excelData.setPlanId(install.getInstallPlanId()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        resultMessage.setStatus(true); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        return resultMessage; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     @Override 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -284,6 +291,8 @@ public class InstallListServiceImpl implements InstallListService { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     public void batchAccept(List<Integer> ids) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         log.info("begin InstallListServiceImpl batchAccept ids = {}",JSON.toJSONString(ids)); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         installListMapper.accept(ids); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        Integer planId = installListMapper.findPlanId(ids); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        installPlanMapper.updateAcceptStatus(planId); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         log.info("end InstallListServiceImpl batchAccept "); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -323,4 +332,11 @@ public class InstallListServiceImpl implements InstallListService { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         log.info("end InstallListServiceImpl allDelete "); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    @Override 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    public void updatePlanStatus(Integer planId) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        log.info("begin InstallListServiceImpl updatePlanStatus planId = {}",JSON.toJSONString(planId)); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        installPlanMapper.updatePlanStatus(planId); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        log.info("end InstallListServiceImpl updatePlanStatus"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 } 
			 |