--- tools/v1-decompiled/cfr-from-cw-lib-current/cw-elevator-application-service-1.0-SNAPSHOT/cn/cloudwalk/elevator/device/impl/AcsElevatorDeviceServiceImpl.java	2026-04-28 12:58:08.622839342 +0800
+++ cw-elevator-application-service/src/main/java/cn/cloudwalk/elevator/device/impl/AcsElevatorDeviceServiceImpl.java	2026-04-24 09:14:40.201128466 +0800
@@ -1,52 +1,3 @@
-/*
- * Decompiled with CFR 0.152.
- * 
- * Could not load the following classes:
- *  cn.cloudwalk.client.cwoscomponent.intelligent.device.param.DeviceQueryParam
- *  cn.cloudwalk.client.cwoscomponent.intelligent.device.result.DeviceResult
- *  cn.cloudwalk.client.cwoscomponent.intelligent.device.service.DeviceService
- *  cn.cloudwalk.client.cwoscomponent.intelligent.imagestore.param.ImageStoreAddParam
- *  cn.cloudwalk.client.cwoscomponent.intelligent.imagestore.param.ImageStoreDelParam
- *  cn.cloudwalk.client.cwoscomponent.intelligent.imagestore.service.ImageStoreService
- *  cn.cloudwalk.client.cwoscomponent.intelligent.person.param.PersonDetailParam
- *  cn.cloudwalk.client.cwoscomponent.intelligent.person.result.PersonResult
- *  cn.cloudwalk.client.cwoscomponent.intelligent.person.service.PersonService
- *  cn.cloudwalk.client.cwoscomponent.intelligent.sysetting.param.DeviceAreaTreeParam
- *  cn.cloudwalk.client.cwoscomponent.intelligent.sysetting.result.AreaTreeResult
- *  cn.cloudwalk.cloud.context.CloudwalkCallContext
- *  cn.cloudwalk.cloud.exception.ServiceException
- *  cn.cloudwalk.cloud.page.CloudwalkPageAble
- *  cn.cloudwalk.cloud.page.CloudwalkPageInfo
- *  cn.cloudwalk.cloud.result.CloudwalkResult
- *  cn.cloudwalk.cloud.utils.BeanCopyUtils
- *  cn.cloudwalk.elevator.device.dao.AcsDeviceTaskDao
- *  cn.cloudwalk.elevator.device.dao.AcsElevatorDeviceDao
- *  cn.cloudwalk.elevator.device.dao.DeviceImageStoreDao
- *  cn.cloudwalk.elevator.device.dto.AcsDeviceTaskAddDto
- *  cn.cloudwalk.elevator.device.dto.AcsDeviceTaskDTO
- *  cn.cloudwalk.elevator.device.dto.AcsElevatorDeviceAddDTO
- *  cn.cloudwalk.elevator.device.dto.AcsElevatorDeviceEditDTO
- *  cn.cloudwalk.elevator.device.dto.AcsElevatorDeviceListDto
- *  cn.cloudwalk.elevator.device.dto.AcsElevatorDeviceQueryByIdDTO
- *  cn.cloudwalk.elevator.device.dto.AcsElevatorDeviceQueryDTO
- *  cn.cloudwalk.elevator.device.dto.AcsElevatorDeviceQueryFoDTO
- *  cn.cloudwalk.elevator.device.dto.AcsElevatorDeviceResultDTO
- *  cn.cloudwalk.elevator.passrule.dao.AcsPassRuleDao
- *  cn.cloudwalk.elevator.passrule.dao.ImageRuleRefDao
- *  cn.cloudwalk.elevator.passrule.dto.AcsPassRuleImageDto
- *  cn.cloudwalk.elevator.passrule.dto.AcsPassRuleImageResultDto
- *  cn.cloudwalk.elevator.passrule.dto.AcsPassRuleLabelResultDto
- *  cn.cloudwalk.elevator.passrule.dto.AcsPassRuleQueryDto
- *  cn.cloudwalk.elevator.util.CollectionUtils
- *  cn.cloudwalk.elevator.util.StringUtils
- *  com.alibaba.fastjson.JSONObject
- *  org.slf4j.Logger
- *  org.slf4j.LoggerFactory
- *  org.springframework.beans.factory.annotation.Autowired
- *  org.springframework.beans.factory.annotation.Value
- *  org.springframework.stereotype.Repository
- *  org.springframework.util.ObjectUtils
- */
 package cn.cloudwalk.elevator.device.impl;
 
 import cn.cloudwalk.client.cwoscomponent.intelligent.device.param.DeviceQueryParam;
@@ -124,10 +75,8 @@
 import org.springframework.util.ObjectUtils;
 
 @Repository
-public class AcsElevatorDeviceServiceImpl
-extends AbstractAcsPassService
-implements AcsElevatorDeviceService {
-    @Value(value="${floor.building.id}")
+public class AcsElevatorDeviceServiceImpl extends AbstractAcsPassService implements AcsElevatorDeviceService {
+    @Value("${floor.building.id}")
     private String floorBuildingId;
     @Resource
     private ImageStoreService imageStoreService;
@@ -157,26 +106,27 @@
     private AcsPassRuleService acsPassRuleService;
     @Resource
     private AcsAreaTreeCacheableService acsAreaTreeCacheableService;
-    protected final Logger logger = LoggerFactory.getLogger(this.getClass());
+    protected final Logger logger = LoggerFactory.getLogger(getClass());
 
-    @Override
     public Integer add(AcsElevatorDeviceAddParam param, CloudwalkCallContext context) throws ServiceException {
-        AcsElevatorDeviceAddDTO dto = (AcsElevatorDeviceAddDTO)BeanCopyUtils.copyProperties((Object)param, AcsElevatorDeviceAddDTO.class);
+        AcsElevatorDeviceAddDTO dto =
+            (AcsElevatorDeviceAddDTO)BeanCopyUtils.copyProperties(param, AcsElevatorDeviceAddDTO.class);
         try {
-            Long createTime = System.currentTimeMillis();
+            Long createTime = Long.valueOf(System.currentTimeMillis());
             dto.setCreateTime(createTime);
             dto.setLastUpdateTime(createTime);
             String currentBuildingId = dto.getCurrentBuildingId();
             if (dto.getDeleteFlag() == null) {
                 dto.setDeleteFlag(Integer.valueOf(1));
             }
-            if (StringUtils.isNotBlank((String)currentBuildingId)) {
+            if (StringUtils.isNotBlank(currentBuildingId)) {
                 String imageStoreId = this.deviceImageStoreDao.getByBuildingId(currentBuildingId);
-                if (ObjectUtils.isEmpty((Object)imageStoreId)) {
-                    String bigImageStoreId = this.addImageStore(param, context);
+                if (ObjectUtils.isEmpty(imageStoreId)) {
+                    String bigImageStoreId = addImageStore(param, context);
                     this.deviceImageStoreDao.save(currentBuildingId, bigImageStoreId);
                 } else {
-                    String applicationId = this.acsApplicationService.getApplicationId(context.getCompany().getCompanyId());
+                    String applicationId =
+                        this.acsApplicationService.getApplicationId(context.getCompany().getCompanyId());
                     DeviceImageStoreAppBindParam bindParam = new DeviceImageStoreAppBindParam();
                     bindParam.setImageStoreId(imageStoreId);
                     bindParam.setDeviceId(param.getDeviceId());
@@ -185,53 +135,55 @@
                 }
             }
             return this.acsElevatorDeviceDao.add(dto);
-        }
-        catch (Exception e) {
-            this.logger.error("\u4fdd\u5b58\u6d3e\u68af\u8bbe\u5907\u4fe1\u606f\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
-            throw new ServiceException((Throwable)e);
+        } catch (Exception e) {
+            this.logger.error("保存派梯设备信息失败，原因：", e);
+            throw new ServiceException(e);
         }
     }
 
-    @Override
     public Integer edit(AcsElevatorDeviceEditParam param, CloudwalkCallContext context) throws ServiceException {
-        AcsElevatorDeviceEditDTO dto = (AcsElevatorDeviceEditDTO)BeanCopyUtils.copyProperties((Object)param, AcsElevatorDeviceEditDTO.class);
+        AcsElevatorDeviceEditDTO dto =
+            (AcsElevatorDeviceEditDTO)BeanCopyUtils.copyProperties(param, AcsElevatorDeviceEditDTO.class);
         try {
             AcsElevatorDeviceQueryByIdDTO deviceQueryByIdDTO = new AcsElevatorDeviceQueryByIdDTO();
             deviceQueryByIdDTO.setId(param.getId());
             AcsElevatorDeviceResultDTO deviceResultDTO = this.acsElevatorDeviceDao.getById(deviceQueryByIdDTO);
             String oldImageStoreId = this.deviceImageStoreDao.getByBuildingId(deviceResultDTO.getCurrentBuildingId());
-            if (deviceResultDTO != null && StringUtils.isNotBlank((String)deviceResultDTO.getCurrentFloorId()) && !deviceResultDTO.getCurrentBuildingId().equals(param.getCurrentBuildingId())) {
-                String applicationId = this.acsApplicationService.getApplicationId(context.getCompany().getCompanyId());
-                DeviceImageStoreAppUnbindParam unbindParam = new DeviceImageStoreAppUnbindParam();
-                unbindParam.setApplicationId(applicationId);
-                unbindParam.setImageStoreId(oldImageStoreId);
-                unbindParam.setDeviceId(deviceResultDTO.getDeviceId());
-                unbindParam.setDeviceCode(deviceResultDTO.getDeviceCode());
-                this.acsDeviceImageStoreAppBindService.unbindAppImageStoreDeviceNotDeleteImage(unbindParam, context);
-                String imageStoreId = this.deviceImageStoreDao.getByBuildingId(param.getCurrentBuildingId());
-                if (ObjectUtils.isEmpty((Object)imageStoreId)) {
-                    AcsElevatorDeviceAddParam addParam = (AcsElevatorDeviceAddParam)BeanCopyUtils.copyProperties((Object)param, AcsElevatorDeviceAddParam.class);
-                    String bigImageStoreId = this.addImageStore(addParam, context);
-                    this.deviceImageStoreDao.save(param.getCurrentBuildingId(), bigImageStoreId);
-                } else {
-                    DeviceImageStoreAppBindParam bindParam = new DeviceImageStoreAppBindParam();
-                    bindParam.setImageStoreId(imageStoreId);
-                    bindParam.setDeviceId(deviceResultDTO.getDeviceId());
-                    bindParam.setApplicationId(applicationId);
-                    this.acsDeviceImageStoreAppBindService.bindDeviceAndImageStore(bindParam, context);
+            if (deviceResultDTO != null && StringUtils.isNotBlank(deviceResultDTO.getCurrentFloorId())) {
+                if (!deviceResultDTO.getCurrentBuildingId().equals(param.getCurrentBuildingId())) {
+                    String applicationId =
+                        this.acsApplicationService.getApplicationId(context.getCompany().getCompanyId());
+                    DeviceImageStoreAppUnbindParam unbindParam = new DeviceImageStoreAppUnbindParam();
+                    unbindParam.setApplicationId(applicationId);
+                    unbindParam.setImageStoreId(oldImageStoreId);
+                    unbindParam.setDeviceId(deviceResultDTO.getDeviceId());
+                    unbindParam.setDeviceCode(deviceResultDTO.getDeviceCode());
+                    this.acsDeviceImageStoreAppBindService.unbindAppImageStoreDeviceNotDeleteImage(unbindParam,
+                        context);
+                    String imageStoreId = this.deviceImageStoreDao.getByBuildingId(param.getCurrentBuildingId());
+                    if (ObjectUtils.isEmpty(imageStoreId)) {
+                        AcsElevatorDeviceAddParam addParam = (AcsElevatorDeviceAddParam)BeanCopyUtils
+                            .copyProperties(param, AcsElevatorDeviceAddParam.class);
+                        String bigImageStoreId = addImageStore(addParam, context);
+                        this.deviceImageStoreDao.save(param.getCurrentBuildingId(), bigImageStoreId);
+                    } else {
+                        DeviceImageStoreAppBindParam bindParam = new DeviceImageStoreAppBindParam();
+                        bindParam.setImageStoreId(imageStoreId);
+                        bindParam.setDeviceId(deviceResultDTO.getDeviceId());
+                        bindParam.setApplicationId(applicationId);
+                        this.acsDeviceImageStoreAppBindService.bindDeviceAndImageStore(bindParam, context);
+                    }
                 }
             }
-            Long nowTime = System.currentTimeMillis();
+            Long nowTime = Long.valueOf(System.currentTimeMillis());
             dto.setLastUpdateTime(nowTime);
             return this.acsElevatorDeviceDao.edit(dto);
-        }
-        catch (Exception e) {
-            this.logger.error("\u66f4\u65b0\u6d3e\u68af\u8bbe\u5907\u4fe1\u606f\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
-            throw new ServiceException((Throwable)e);
+        } catch (Exception e) {
+            this.logger.error("更新派梯设备信息失败，原因：", e);
+            throw new ServiceException(e);
         }
     }
 
-    @Override
     public Integer delete(List<String> ids, CloudwalkCallContext context) throws ServiceException {
         try {
             String applicationId = this.acsApplicationService.getApplicationId(context.getCompany().getCompanyId());
@@ -247,195 +199,193 @@
                 unbindParam.setDeviceCode(deviceResultDTO.getDeviceCode());
                 this.acsDeviceImageStoreAppBindService.unbindAppImageStoreDeviceNotDeleteImage(unbindParam, context);
             }
-            int result = this.acsElevatorDeviceDao.delete(ids);
-            return 1;
-        }
-        catch (Exception e) {
-            this.logger.error("\u66f4\u65b0\u6d3e\u68af\u8bbe\u5907\u4fe1\u606f\u5931\u8d25\uff0c\u539f\u56e0\uff1a", (Throwable)e);
-            throw new ServiceException((Throwable)e);
+            int result = this.acsElevatorDeviceDao.delete(ids).intValue();
+            return Integer.valueOf(1);
+        } catch (Exception e) {
+            this.logger.error("更新派梯设备信息失败，原因：", e);
+            throw new ServiceException(e);
         }
     }
 
-    @Override
     public String getBuildingId(AcsElevatorDeviceQueryParam param) throws ServiceException {
-        AcsElevatorDeviceQueryDTO dto = (AcsElevatorDeviceQueryDTO)BeanCopyUtils.copyProperties((Object)param, AcsElevatorDeviceQueryDTO.class);
+        AcsElevatorDeviceQueryDTO dto =
+            (AcsElevatorDeviceQueryDTO)BeanCopyUtils.copyProperties(param, AcsElevatorDeviceQueryDTO.class);
         return this.acsElevatorDeviceDao.getBuildingId(dto);
     }
 
-    @Override
     public String getBusinessId(AcsElevatorDeviceQueryParam param) throws ServiceException {
-        AcsElevatorDeviceQueryDTO dto = (AcsElevatorDeviceQueryDTO)BeanCopyUtils.copyProperties((Object)param, AcsElevatorDeviceQueryDTO.class);
+        AcsElevatorDeviceQueryDTO dto =
+            (AcsElevatorDeviceQueryDTO)BeanCopyUtils.copyProperties(param, AcsElevatorDeviceQueryDTO.class);
         return this.acsElevatorDeviceDao.getBusinessId(dto);
     }
 
-    @Override
-    public CloudwalkResult<CloudwalkPageAble<AcsElevatorDeviceResultDTO>> get(AcsElevatorDeviceQueryParam param, CloudwalkCallContext context) throws ServiceException {
-        AcsElevatorDeviceQueryDTO dto = (AcsElevatorDeviceQueryDTO)BeanCopyUtils.copyProperties((Object)param, AcsElevatorDeviceQueryDTO.class);
+    public CloudwalkResult<CloudwalkPageAble<AcsElevatorDeviceResultDTO>> get(AcsElevatorDeviceQueryParam param,
+        CloudwalkCallContext context) throws ServiceException {
+        AcsElevatorDeviceQueryDTO dto =
+            (AcsElevatorDeviceQueryDTO)BeanCopyUtils.copyProperties(param, AcsElevatorDeviceQueryDTO.class);
         dto.setBusinessId(context.getCompany().getCompanyId());
         CloudwalkPageInfo page = new CloudwalkPageInfo(param.getCurrentPage(), param.getRowsOfPage());
         try {
-            CloudwalkPageAble deviceList = this.acsElevatorDeviceDao.page(dto, page);
-            return CloudwalkResult.success((Object)deviceList);
-        }
-        catch (Exception e) {
-            this.logger.error("\u5206\u9875\u67e5\u8be2\u6d3e\u68af\u8bbe\u5907\u5931\u8d25\uff0c\u5931\u8d25\u539f\u56e0\uff1a", (Throwable)e);
-            throw new ServiceException("76260108", this.getMessage("76260108"));
+            CloudwalkPageAble<AcsElevatorDeviceResultDTO> deviceList = this.acsElevatorDeviceDao.page(dto, page);
+            return CloudwalkResult.success(deviceList);
+        } catch (Exception e) {
+            this.logger.error("分页查询派梯设备失败，失败原因：", e);
+            throw new ServiceException("76260108", getMessage("76260108"));
         }
     }
 
-    @Override
-    public CloudwalkResult<CloudwalkPageAble<DeviceResult>> devicePage(AcsDeviceQueryParam param, CloudwalkPageInfo pageInfo, CloudwalkCallContext context) throws ServiceException {
+    public CloudwalkResult<CloudwalkPageAble<DeviceResult>> devicePage(AcsDeviceQueryParam param,
+        CloudwalkPageInfo pageInfo, CloudwalkCallContext context) throws ServiceException {
         try {
             DeviceQueryParam queryParam = new DeviceQueryParam();
-            if (!ObjectUtils.isEmpty((Object)param.getDeviceName())) {
+            if (!ObjectUtils.isEmpty(param.getDeviceName())) {
                 queryParam.setDeviceName(param.getDeviceName());
             }
-            if (!ObjectUtils.isEmpty((Object)param.getAreaId())) {
+            if (!ObjectUtils.isEmpty(param.getAreaId())) {
                 queryParam.setAreaIds(Collections.singletonList(param.getAreaId()));
             }
-            if (!ObjectUtils.isEmpty((Object)param.getDeviceCategoryId())) {
+            if (!ObjectUtils.isEmpty(param.getDeviceCategoryId())) {
                 queryParam.setDeviceTypeCategoryId(param.getDeviceCategoryId());
             }
             queryParam.setBusinessId(context.getCompany().getCompanyId());
-            CloudwalkResult pageResult = this.deviceService.list(queryParam, context);
-            List<Object> result = new ArrayList();
-            if (!pageResult.isSuccess() || CollectionUtils.isEmpty((Collection)((Collection)pageResult.getData()))) {
-                return CloudwalkResult.success((Object)new CloudwalkPageAble(result, pageInfo, 0L));
+            CloudwalkResult<List<DeviceResult>> pageResult = this.deviceService.list(queryParam, context);
+            List<DeviceResult> result = new ArrayList<>();
+            if (!pageResult.isSuccess() || CollectionUtils.isEmpty((Collection)pageResult.getData())) {
+                return CloudwalkResult.success(new CloudwalkPageAble(result, pageInfo, 0L));
             }
-            List<DeviceResult> deviceResult = this.deviceFilter((List)pageResult.getData(), context);
+            List<DeviceResult> deviceResult = deviceFilter((List<DeviceResult>)pageResult.getData(), context);
             if (CollectionUtils.isEmpty(deviceResult)) {
-                return CloudwalkResult.success((Object)new CloudwalkPageAble(result, pageInfo, 0L));
+                return CloudwalkResult.success(new CloudwalkPageAble(result, pageInfo, 0L));
             }
-            Map<String, String> areaMap = this.getAllAreaMap(context);
-            result = this.page(this.convertDeviceNewResult(deviceResult, areaMap), pageInfo.getPageSize(), pageInfo.getCurrentPage());
-            return CloudwalkResult.success((Object)new CloudwalkPageAble(result, pageInfo, (long)deviceResult.size()));
-        }
-        catch (Exception e) {
-            this.logger.error("\u5206\u9875\u67e5\u8be2\u8bbe\u5907\u5f02\u5e38\uff0c\u539f\u56e0\uff1a", (Throwable)e);
-            throw new ServiceException((Throwable)e);
+            Map<String, String> areaMap = getAllAreaMap(context);
+            result =
+                page(convertDeviceNewResult(deviceResult, areaMap), pageInfo.getPageSize(), pageInfo.getCurrentPage());
+            return CloudwalkResult.success(new CloudwalkPageAble(result, pageInfo, deviceResult.size()));
+        } catch (Exception e) {
+            this.logger.error("分页查询设备异常，原因：", e);
+            throw new ServiceException(e);
         }
     }
 
-    @Override
     public List<AcsElevatorDeviceQueryFoDTO> getFo(AcsElevatorDeviceQueryParam param) throws ServiceException {
-        AcsElevatorDeviceQueryDTO dto = (AcsElevatorDeviceQueryDTO)BeanCopyUtils.copyProperties((Object)param, AcsElevatorDeviceQueryDTO.class);
-        List deviceList = this.acsElevatorDeviceDao.get(dto);
-        ArrayList<AcsElevatorDeviceQueryFoDTO> deviceFoList = new ArrayList<AcsElevatorDeviceQueryFoDTO>();
+        AcsElevatorDeviceQueryDTO dto =
+            (AcsElevatorDeviceQueryDTO)BeanCopyUtils.copyProperties(param, AcsElevatorDeviceQueryDTO.class);
+        List<AcsElevatorDeviceResultDTO> deviceList = this.acsElevatorDeviceDao.get(dto);
+        List<AcsElevatorDeviceQueryFoDTO> deviceFoList = new ArrayList<>();
         for (AcsElevatorDeviceResultDTO resultDTO : deviceList) {
-            AcsElevatorDeviceQueryFoDTO foDto = (AcsElevatorDeviceQueryFoDTO)BeanCopyUtils.copyProperties((Object)resultDTO, AcsElevatorDeviceQueryFoDTO.class);
+            AcsElevatorDeviceQueryFoDTO foDto =
+                (AcsElevatorDeviceQueryFoDTO)BeanCopyUtils.copyProperties(resultDTO, AcsElevatorDeviceQueryFoDTO.class);
             deviceFoList.add(foDto);
         }
         return deviceFoList;
     }
 
-    @Override
-    public AcsElevatorDeviceResultDTO getById(AcsElevatorDeviceQueryByIdParam param, CloudwalkCallContext var2) throws ServiceException {
-        AcsElevatorDeviceQueryByIdDTO dto = (AcsElevatorDeviceQueryByIdDTO)BeanCopyUtils.copyProperties((Object)param, AcsElevatorDeviceQueryByIdDTO.class);
+    public AcsElevatorDeviceResultDTO getById(AcsElevatorDeviceQueryByIdParam param, CloudwalkCallContext var2)
+        throws ServiceException {
+        AcsElevatorDeviceQueryByIdDTO dto =
+            (AcsElevatorDeviceQueryByIdDTO)BeanCopyUtils.copyProperties(param, AcsElevatorDeviceQueryByIdDTO.class);
         AcsElevatorDeviceResultDTO resultDTO = this.acsElevatorDeviceDao.getById(dto);
-        if (resultDTO != null && StringUtils.isNotBlank((String)resultDTO.getDeviceId())) {
-            DeviceResult deviceResult;
+        if (resultDTO != null && StringUtils.isNotBlank(resultDTO.getDeviceId())) {
             DeviceQueryParam deviceQueryParam = new DeviceQueryParam();
             deviceQueryParam.setId(resultDTO.getId());
-            CloudwalkResult result = this.deviceService.list(deviceQueryParam, var2);
-            List list = (List)result.getData();
-            if (list != null && list.size() > 0 && (deviceResult = (DeviceResult)list.get(0)) != null) {
-                String id = deviceResult.getId();
-                Long lastHeartbeatTime = deviceResult.getLastHeartbeatTime();
-                String status = deviceResult.getOnlineStatus();
-                resultDTO.setStatusString(status);
-                resultDTO.setLastHeartbeatTime(lastHeartbeatTime);
+            CloudwalkResult<List<DeviceResult>> result = this.deviceService.list(deviceQueryParam, var2);
+            List<DeviceResult> list = (List<DeviceResult>)result.getData();
+            if (list != null && list.size() > 0) {
+                DeviceResult deviceResult = list.get(0);
+                if (deviceResult != null) {
+                    String id = deviceResult.getId();
+                    Long lastHeartbeatTime = deviceResult.getLastHeartbeatTime();
+                    String status = deviceResult.getOnlineStatus();
+                    resultDTO.setStatusString(status);
+                    resultDTO.setLastHeartbeatTime(lastHeartbeatTime);
+                }
             }
         }
         return resultDTO;
     }
 
-    @Override
     public AcsElevatorDeviceResultDTO getByDeciveCode(String deviceCode) throws ServiceException {
         return this.acsElevatorDeviceDao.getByDeciveCode(deviceCode);
     }
 
-    @Override
-    public CloudwalkResult listUnbindFloors(AcsRestructureQueryParam param, CloudwalkCallContext context) throws ServiceException {
+    public CloudwalkResult listUnbindFloors(AcsRestructureQueryParam param, CloudwalkCallContext context)
+        throws ServiceException {
         try {
-            List floorList;
-            AcsPassRuleImageDto dto;
-            ArrayList results = new ArrayList();
-            if (!ObjectUtils.isEmpty((Object)param.getPersonId())) {
-                dto = new AcsPassRuleImageDto();
+            List<AcsPassRuleImageResultDto> floorList;
+            List<AcsDeviceRestructureResult> results = new ArrayList<>();
+            if (!ObjectUtils.isEmpty(param.getPersonId())) {
+                AcsPassRuleImageDto dto = new AcsPassRuleImageDto();
                 dto.setPersonId(param.getPersonId());
                 PersonDetailParam detailParam = new PersonDetailParam();
                 detailParam.setId(param.getPersonId());
                 detailParam.setBusinessId(context.getCompany().getCompanyId());
-                CloudwalkResult detail = this.personService.detail(detailParam, context);
-                if (!CollectionUtils.isEmpty((Collection)((PersonResult)detail.getData()).getLabelIds())) {
+                CloudwalkResult<PersonResult> detail = this.personService.detail(detailParam, context);
+                if (!CollectionUtils.isEmpty(((PersonResult)detail.getData()).getLabelIds())) {
                     dto.setIncludeLabels(((PersonResult)detail.getData()).getLabelIds());
                 }
-                if (!CollectionUtils.isEmpty((Collection)((PersonResult)detail.getData()).getOrganizationIds())) {
+                if (!CollectionUtils.isEmpty(((PersonResult)detail.getData()).getOrganizationIds())) {
                     dto.setIncludeOrganizations(((PersonResult)detail.getData()).getOrganizationIds());
                 }
                 floorList = this.imageRuleRefDao.listByPersonInfo(dto);
             } else {
-                dto = new AcsPassRuleImageDto();
-                if (!ObjectUtils.isEmpty((Object)param.getLabelId())) {
+                AcsPassRuleImageDto dto = new AcsPassRuleImageDto();
+                if (!ObjectUtils.isEmpty(param.getLabelId())) {
                     dto.setIncludeLabels(Collections.singletonList(param.getLabelId()));
                 }
-                if (!ObjectUtils.isEmpty((Object)param.getOrgId())) {
+                if (!ObjectUtils.isEmpty(param.getOrgId())) {
                     dto.setIncludeOrganizations(Collections.singletonList(param.getOrgId()));
                 }
                 floorList = this.imageRuleRefDao.listByRestructure(dto);
             }
-            ArrayList floorIds = new ArrayList();
-            if (!CollectionUtils.isEmpty((Collection)floorList)) {
+            List<String> floorIds = new ArrayList<>();
+            if (!CollectionUtils.isEmpty(floorList)) {
                 floorList.forEach(floor -> floorIds.add(floor.getZoneId()));
             }
             AcsPassRuleQueryDto queryDto = new AcsPassRuleQueryDto();
             queryDto.setZoneIds(floorIds);
-            return CloudwalkResult.success((Object)this.imageRuleRefDao.listByNotZoneIds(queryDto));
-        }
-        catch (Exception e) {
-            this.logger.error("\u67e5\u8be2\u672a\u7ed1\u5b9a\u7684\u6d3e\u68af\u697c\u5c42\u5f02\u5e38\uff0c\u539f\u56e0\uff1a", (Throwable)e);
-            throw new ServiceException((Throwable)e);
+            return CloudwalkResult.success(this.imageRuleRefDao.listByNotZoneIds(queryDto));
+        } catch (Exception e) {
+            this.logger.error("查询未绑定的派梯楼层异常，原因：", e);
+            throw new ServiceException(e);
         }
     }
 
-    @Override
-    public CloudwalkResult listFloors(AcsRestructureQueryParam param, CloudwalkCallContext context) throws ServiceException {
+    public CloudwalkResult listFloors(AcsRestructureQueryParam param, CloudwalkCallContext context)
+        throws ServiceException {
         try {
-            List unBindFloors;
-            List floorList;
-            AcsPassRuleImageDto dto;
-            ArrayList<AcsDeviceRestructureResult> results = new ArrayList<AcsDeviceRestructureResult>();
-            if (!ObjectUtils.isEmpty((Object)param.getPersonId())) {
-                dto = new AcsPassRuleImageDto();
-                dto.setPersonId(param.getPersonId());
+            List<AcsPassRuleImageResultDto> floorList, unBindFloors;
+            List<AcsDeviceRestructureResult> results = new ArrayList<>();
+            if (!ObjectUtils.isEmpty(param.getPersonId())) {
+                AcsPassRuleImageDto acsPassRuleImageDto = new AcsPassRuleImageDto();
+                acsPassRuleImageDto.setPersonId(param.getPersonId());
                 PersonDetailParam detailParam = new PersonDetailParam();
                 detailParam.setId(param.getPersonId());
                 detailParam.setBusinessId(context.getCompany().getCompanyId());
-                CloudwalkResult detail = this.personService.detail(detailParam, context);
-                if (!CollectionUtils.isEmpty((Collection)((PersonResult)detail.getData()).getLabelIds())) {
-                    dto.setIncludeLabels(((PersonResult)detail.getData()).getLabelIds());
+                CloudwalkResult<PersonResult> detail = this.personService.detail(detailParam, context);
+                if (!CollectionUtils.isEmpty(((PersonResult)detail.getData()).getLabelIds())) {
+                    acsPassRuleImageDto.setIncludeLabels(((PersonResult)detail.getData()).getLabelIds());
                 }
-                if (!CollectionUtils.isEmpty((Collection)((PersonResult)detail.getData()).getOrganizationIds())) {
-                    dto.setIncludeOrganizations(((PersonResult)detail.getData()).getOrganizationIds());
+                if (!CollectionUtils.isEmpty(((PersonResult)detail.getData()).getOrganizationIds())) {
+                    acsPassRuleImageDto.setIncludeOrganizations(((PersonResult)detail.getData()).getOrganizationIds());
                 }
-                floorList = this.imageRuleRefDao.listByPersonInfo(dto);
+                floorList = this.imageRuleRefDao.listByPersonInfo(acsPassRuleImageDto);
             } else {
-                dto = new AcsPassRuleImageDto();
-                if (!ObjectUtils.isEmpty((Object)param.getLabelId())) {
-                    dto.setIncludeLabels(Collections.singletonList(param.getLabelId()));
-                }
-                if (!ObjectUtils.isEmpty((Object)param.getOrgId())) {
-                    dto.setIncludeOrganizations(Collections.singletonList(param.getOrgId()));
-                }
-                floorList = this.imageRuleRefDao.listByRestructure(dto);
-            }
-            dto = new AcsElevatorDeviceListDto();
-            ArrayList floorIds = new ArrayList();
-            if (!CollectionUtils.isEmpty((Collection)floorList)) {
+                AcsPassRuleImageDto acsPassRuleImageDto = new AcsPassRuleImageDto();
+                if (!ObjectUtils.isEmpty(param.getLabelId())) {
+                    acsPassRuleImageDto.setIncludeLabels(Collections.singletonList(param.getLabelId()));
+                }
+                if (!ObjectUtils.isEmpty(param.getOrgId())) {
+                    acsPassRuleImageDto.setIncludeOrganizations(Collections.singletonList(param.getOrgId()));
+                }
+                floorList = this.imageRuleRefDao.listByRestructure(acsPassRuleImageDto);
+            }
+            AcsElevatorDeviceListDto dto = new AcsElevatorDeviceListDto();
+            List<String> floorIds = new ArrayList<>();
+            if (!CollectionUtils.isEmpty(floorList)) {
                 floorList.forEach(floor -> floorIds.add(floor.getZoneId()));
             }
             AcsPassRuleQueryDto queryDto = new AcsPassRuleQueryDto();
-            if (!ObjectUtils.isEmpty((Object)param.getZoneId())) {
+            if (!ObjectUtils.isEmpty(param.getZoneId())) {
                 if (floorIds.contains(param.getZoneId())) {
                     return CloudwalkResult.success(results);
                 }
@@ -445,56 +395,64 @@
                 queryDto.setZoneIds(floorIds);
                 unBindFloors = this.imageRuleRefDao.listByNotZoneIds(queryDto);
             }
-            ArrayList unBindFloorIds = new ArrayList();
-            if (CollectionUtils.isEmpty((Collection)unBindFloors)) {
+            List<String> unBindFloorIds = new ArrayList<>();
+            if (!CollectionUtils.isEmpty(unBindFloors)) {
+                unBindFloors.forEach(floor -> unBindFloorIds.add(floor.getZoneId()));
+            } else {
                 return CloudwalkResult.success(results);
             }
-            unBindFloors.forEach(floor -> unBindFloorIds.add(floor.getZoneId()));
-            if (!ObjectUtils.isEmpty((Object)param.getZoneId())) {
+            if (!ObjectUtils.isEmpty(param.getZoneId())) {
                 dto.setCurrentFloorId(param.getZoneId());
             } else {
                 dto.setCurrentFloorIds(unBindFloorIds);
             }
-            List deviceList = this.acsElevatorDeviceDao.listByZoneIds((AcsElevatorDeviceListDto)dto);
-            ArrayList deviceIds = new ArrayList();
-            HashMap<String, DeviceResult> mapDevice = new HashMap<String, DeviceResult>();
-            if (!CollectionUtils.isEmpty((Collection)deviceList)) {
+            List<AcsElevatorDeviceResultDTO> deviceList = this.acsElevatorDeviceDao.listByZoneIds(dto);
+            List<String> deviceIds = new ArrayList<>();
+            Map<String, DeviceResult> mapDevice = new HashMap<>();
+            if (!CollectionUtils.isEmpty(deviceList)) {
                 deviceList.forEach(device -> deviceIds.add(device.getDeviceId()));
                 DeviceQueryParam queryParam = new DeviceQueryParam();
                 queryParam.setBusinessId(context.getCompany().getCompanyId());
                 queryParam.setIds(deviceIds);
-                CloudwalkResult resultList = this.deviceService.list(queryParam, context);
-                List list = (List)resultList.getData();
+                CloudwalkResult<List<DeviceResult>> resultList = this.deviceService.list(queryParam, context);
+                List<DeviceResult> list = (List<DeviceResult>)resultList.getData();
                 if (list != null && list.size() > 0) {
                     for (DeviceResult deviceResult : list) {
                         mapDevice.put(deviceResult.getId(), deviceResult);
                     }
                 }
             }
-            for (AcsPassRuleImageResultDto floor2 : unBindFloors) {
+            for (AcsPassRuleImageResultDto floor : unBindFloors) {
                 AcsDeviceRestructureResult result = new AcsDeviceRestructureResult();
-                result.setZoneId(floor2.getZoneId());
-                result.setZoneName(floor2.getZoneName());
-                if (!CollectionUtils.isEmpty((Collection)deviceList)) {
+                result.setZoneId(floor.getZoneId());
+                result.setZoneName(floor.getZoneName());
+                if (!CollectionUtils.isEmpty(deviceList)) {
                     result.setParentId(((AcsElevatorDeviceResultDTO)deviceList.get(0)).getCurrentBuildingId());
                 } else {
                     result.setParentId(this.floorBuildingId);
                 }
                 String online = "";
                 String offline = "";
-                if (!CollectionUtils.isEmpty((Collection)deviceList)) {
-                    for (int i = 0; i < deviceList.size(); ++i) {
-                        DeviceResult deviceResult;
-                        if (!floor2.getZoneId().equals(((AcsElevatorDeviceResultDTO)deviceList.get(i)).getCurrentFloorId()) || ObjectUtils.isEmpty((Object)(deviceResult = (DeviceResult)mapDevice.get(((AcsElevatorDeviceResultDTO)deviceList.get(i)).getDeviceId())))) continue;
-                        if ("2".equals(deviceResult.getOnlineStatus())) {
-                            if ("".equals(online)) {
-                                online = online + deviceResult.getDeviceName();
-                                continue;
+                if (!CollectionUtils.isEmpty(deviceList)) {
+                    for (int i = 0; i < deviceList.size(); i++) {
+                        if (floor.getZoneId()
+                            .equals(((AcsElevatorDeviceResultDTO)deviceList.get(i)).getCurrentFloorId())) {
+                            DeviceResult deviceResult =
+                                mapDevice.get(((AcsElevatorDeviceResultDTO)deviceList.get(i)).getDeviceId());
+                            if (!ObjectUtils.isEmpty(deviceResult)) {
+                                if ("2".equals(deviceResult.getOnlineStatus())) {
+                                    if ("".equals(online)) {
+                                        online = online + deviceResult.getDeviceName();
+                                    } else {
+                                        online = online + "," + deviceResult.getDeviceName();
+                                    }
+                                } else if ("".equals(offline)) {
+                                    offline = offline + deviceResult.getDeviceName();
+                                } else {
+                                    offline = offline + ',' + deviceResult.getDeviceName();
+                                }
                             }
-                            online = online + "," + deviceResult.getDeviceName();
-                            continue;
                         }
-                        offline = "".equals(offline) ? offline + deviceResult.getDeviceName() : offline + ',' + deviceResult.getDeviceName();
                     }
                 }
                 result.setOnlineDevices(online);
@@ -502,143 +460,148 @@
                 results.add(result);
             }
             return CloudwalkResult.success(results);
-        }
-        catch (Exception e) {
-            this.logger.error("\u67e5\u8be2\u672a\u7ed1\u5b9a\u7684\u6d3e\u68af\u697c\u5c42\u5f02\u5e38\uff0c\u539f\u56e0\uff1a", (Throwable)e);
-            throw new ServiceException((Throwable)e);
+        } catch (Exception e) {
+            this.logger.error("查询未绑定的派梯楼层异常，原因：", e);
+            throw new ServiceException(e);
         }
     }
 
-    /*
-     * Enabled force condition propagation
-     * Lifted jumps to return sites
-     */
-    @Override
-    public CloudwalkResult listCondition(AcsRestructureQueryParam param, CloudwalkCallContext context) throws ServiceException {
-        try {
-            List floorList;
-            AcsPassRuleImageDto dto;
-            ArrayList<AcsDeviceRestructureResult> results = new ArrayList<AcsDeviceRestructureResult>();
-            if (!ObjectUtils.isEmpty((Object)param.getBusinessId())) {
+    public CloudwalkResult listCondition(AcsRestructureQueryParam param, CloudwalkCallContext context)
+        throws ServiceException {
+        try {
+            List<AcsPassRuleImageResultDto> floorList;
+            List<AcsDeviceRestructureResult> results = new ArrayList<>();
+            if (!ObjectUtils.isEmpty(param.getBusinessId())) {
                 context.getCompany().setCompanyId(param.getBusinessId());
             }
-            if (!ObjectUtils.isEmpty((Object)param.getPersonId())) {
-                dto = new AcsPassRuleImageDto();
+            if (!ObjectUtils.isEmpty(param.getPersonId())) {
+                AcsPassRuleImageDto dto = new AcsPassRuleImageDto();
                 dto.setPersonId(param.getPersonId());
                 PersonDetailParam detailParam = new PersonDetailParam();
                 detailParam.setId(param.getPersonId());
                 detailParam.setBusinessId(context.getCompany().getCompanyId());
-                CloudwalkResult detail = this.personService.detail(detailParam, context);
-                if (!CollectionUtils.isEmpty((Collection)((PersonResult)detail.getData()).getLabelIds())) {
+                CloudwalkResult<PersonResult> detail = this.personService.detail(detailParam, context);
+                if (!CollectionUtils.isEmpty(((PersonResult)detail.getData()).getLabelIds())) {
                     dto.setIncludeLabels(((PersonResult)detail.getData()).getLabelIds());
                 }
-                if (!CollectionUtils.isEmpty((Collection)((PersonResult)detail.getData()).getOrganizationIds())) {
+                if (!CollectionUtils.isEmpty(((PersonResult)detail.getData()).getOrganizationIds())) {
                     dto.setIncludeOrganizations(((PersonResult)detail.getData()).getOrganizationIds());
                 }
                 floorList = this.imageRuleRefDao.listByPersonInfo(dto);
             } else {
-                dto = new AcsPassRuleImageDto();
-                if (!ObjectUtils.isEmpty((Object)param.getLabelId())) {
+                AcsPassRuleImageDto dto = new AcsPassRuleImageDto();
+                if (!ObjectUtils.isEmpty(param.getLabelId())) {
                     dto.setIncludeLabels(Collections.singletonList(param.getLabelId()));
                 }
-                if (!ObjectUtils.isEmpty((Object)param.getOrgId())) {
+                if (!ObjectUtils.isEmpty(param.getOrgId())) {
                     dto.setIncludeOrganizations(Collections.singletonList(param.getOrgId()));
                 }
                 floorList = this.imageRuleRefDao.listByRestructure(dto);
             }
-            if (CollectionUtils.isEmpty((Collection)floorList)) return CloudwalkResult.success(results);
-            dto = new AcsElevatorDeviceListDto();
-            ArrayList floorIds = new ArrayList();
-            floorList.forEach(floor -> floorIds.add(floor.getZoneId()));
-            if (!ObjectUtils.isEmpty((Object)param.getZoneId())) {
-                if (!floorIds.contains(param.getZoneId())) return CloudwalkResult.success(results);
-                dto.setCurrentFloorIds(Collections.singletonList(param.getZoneId()));
-            } else {
-                dto.setCurrentFloorIds(floorIds);
-            }
-            List deviceList = this.acsElevatorDeviceDao.listByZoneIds((AcsElevatorDeviceListDto)dto);
-            if (!CollectionUtils.isEmpty((Collection)deviceList)) {
-                ArrayList deviceIds = new ArrayList();
-                deviceList.forEach(device -> deviceIds.add(device.getDeviceId()));
-                HashMap<String, DeviceResult> mapDevice = new HashMap<String, DeviceResult>();
-                DeviceQueryParam queryParam = new DeviceQueryParam();
-                queryParam.setBusinessId(context.getCompany().getCompanyId());
-                queryParam.setIds(deviceIds);
-                CloudwalkResult resultList = this.deviceService.list(queryParam, context);
-                List list = (List)resultList.getData();
-                if (list != null && list.size() > 0) {
-                    for (DeviceResult deviceResult : list) {
-                        mapDevice.put(deviceResult.getId(), deviceResult);
+            if (!CollectionUtils.isEmpty(floorList)) {
+                AcsElevatorDeviceListDto dto = new AcsElevatorDeviceListDto();
+                List<String> floorIds = new ArrayList<>();
+                floorList.forEach(floor -> floorIds.add(floor.getZoneId()));
+                if (!ObjectUtils.isEmpty(param.getZoneId())) {
+                    if (floorIds.contains(param.getZoneId())) {
+                        dto.setCurrentFloorIds(Collections.singletonList(param.getZoneId()));
+                    } else {
+                        return CloudwalkResult.success(results);
                     }
+                } else {
+                    dto.setCurrentFloorIds(floorIds);
                 }
-                for (AcsPassRuleImageResultDto floor2 : floorList) {
-                    if (!ObjectUtils.isEmpty((Object)param.getZoneId()) && !param.getZoneId().equals(floor2.getZoneId())) continue;
-                    AcsDeviceRestructureResult result = new AcsDeviceRestructureResult();
-                    result.setZoneId(floor2.getZoneId());
-                    result.setZoneName(floor2.getZoneName());
-                    result.setParentId(this.floorBuildingId);
-                    String online = "";
-                    String offline = "";
-                    for (int i = 0; i < deviceList.size(); ++i) {
-                        if (!floor2.getZoneId().equals(((AcsElevatorDeviceResultDTO)deviceList.get(i)).getCurrentFloorId())) continue;
-                        DeviceResult deviceResult = (DeviceResult)mapDevice.get(((AcsElevatorDeviceResultDTO)deviceList.get(i)).getDeviceId());
-                        result.setParentId(((AcsElevatorDeviceResultDTO)deviceList.get(i)).getCurrentBuildingId());
-                        if (ObjectUtils.isEmpty((Object)deviceResult)) continue;
-                        if ("2".equals(deviceResult.getOnlineStatus())) {
-                            if ("".equals(online)) {
-                                online = online + deviceResult.getDeviceName();
-                                continue;
-                            }
-                            online = online + "," + deviceResult.getDeviceName();
+                List<AcsElevatorDeviceResultDTO> deviceList = this.acsElevatorDeviceDao.listByZoneIds(dto);
+                if (!CollectionUtils.isEmpty(deviceList)) {
+                    List<String> deviceIds = new ArrayList<>();
+                    deviceList.forEach(device -> deviceIds.add(device.getDeviceId()));
+                    Map<String, DeviceResult> mapDevice = new HashMap<>();
+                    DeviceQueryParam queryParam = new DeviceQueryParam();
+                    queryParam.setBusinessId(context.getCompany().getCompanyId());
+                    queryParam.setIds(deviceIds);
+                    CloudwalkResult<List<DeviceResult>> resultList = this.deviceService.list(queryParam, context);
+                    List<DeviceResult> list = (List<DeviceResult>)resultList.getData();
+                    if (list != null && list.size() > 0) {
+                        for (DeviceResult deviceResult : list) {
+                            mapDevice.put(deviceResult.getId(), deviceResult);
+                        }
+                    }
+                    for (AcsPassRuleImageResultDto floor : floorList) {
+                        if (!ObjectUtils.isEmpty(param.getZoneId()) && !param.getZoneId().equals(floor.getZoneId())) {
                             continue;
                         }
-                        offline = "".equals(offline) ? offline + deviceResult.getDeviceName() : offline + ',' + deviceResult.getDeviceName();
+                        AcsDeviceRestructureResult result = new AcsDeviceRestructureResult();
+                        result.setZoneId(floor.getZoneId());
+                        result.setZoneName(floor.getZoneName());
+                        result.setParentId(this.floorBuildingId);
+                        String online = "";
+                        String offline = "";
+                        for (int i = 0; i < deviceList.size(); i++) {
+                            if (floor.getZoneId()
+                                .equals(((AcsElevatorDeviceResultDTO)deviceList.get(i)).getCurrentFloorId())) {
+                                DeviceResult deviceResult =
+                                    mapDevice.get(((AcsElevatorDeviceResultDTO)deviceList.get(i)).getDeviceId());
+                                result.setParentId(
+                                    ((AcsElevatorDeviceResultDTO)deviceList.get(i)).getCurrentBuildingId());
+                                if (!ObjectUtils.isEmpty(deviceResult)) {
+                                    if ("2".equals(deviceResult.getOnlineStatus())) {
+                                        if ("".equals(online)) {
+                                            online = online + deviceResult.getDeviceName();
+                                        } else {
+                                            online = online + "," + deviceResult.getDeviceName();
+                                        }
+                                    } else if ("".equals(offline)) {
+                                        offline = offline + deviceResult.getDeviceName();
+                                    } else {
+                                        offline = offline + ',' + deviceResult.getDeviceName();
+                                    }
+                                }
+                            }
+                        }
+                        result.setOnlineDevices(online);
+                        result.setOfflineDevices(offline);
+                        results.add(result);
+                    }
+                } else if (!ObjectUtils.isEmpty(param.getZoneId())) {
+                    for (AcsPassRuleImageResultDto floor : floorList) {
+                        if (floor.getZoneId().equals(param.getZoneId())) {
+                            AcsDeviceRestructureResult result = new AcsDeviceRestructureResult();
+                            result.setZoneId(floor.getZoneId());
+                            result.setZoneName(floor.getZoneName());
+                            result.setParentId(this.floorBuildingId);
+                            results.add(result);
+                            break;
+                        }
+                    }
+                } else {
+                    for (AcsPassRuleImageResultDto floor : floorList) {
+                        AcsDeviceRestructureResult result = new AcsDeviceRestructureResult();
+                        result.setZoneId(floor.getZoneId());
+                        result.setZoneName(floor.getZoneName());
+                        result.setParentId(this.floorBuildingId);
+                        results.add(result);
                     }
-                    result.setOnlineDevices(online);
-                    result.setOfflineDevices(offline);
-                    results.add(result);
-                }
-                return CloudwalkResult.success(results);
-            }
-            if (!ObjectUtils.isEmpty((Object)param.getZoneId())) {
-                for (AcsPassRuleImageResultDto floor3 : floorList) {
-                    if (!floor3.getZoneId().equals(param.getZoneId())) continue;
-                    AcsDeviceRestructureResult result = new AcsDeviceRestructureResult();
-                    result.setZoneId(floor3.getZoneId());
-                    result.setZoneName(floor3.getZoneName());
-                    result.setParentId(this.floorBuildingId);
-                    results.add(result);
-                    return CloudwalkResult.success(results);
                 }
-                return CloudwalkResult.success(results);
-            }
-            for (AcsPassRuleImageResultDto floor4 : floorList) {
-                AcsDeviceRestructureResult result = new AcsDeviceRestructureResult();
-                result.setZoneId(floor4.getZoneId());
-                result.setZoneName(floor4.getZoneName());
-                result.setParentId(this.floorBuildingId);
-                results.add(result);
             }
             return CloudwalkResult.success(results);
-        }
-        catch (Exception e) {
-            this.logger.error("\u6839\u636e\u673a\u6784id\u3001\u6807\u7b7eid\u3001\u4eba\u5458id\u67e5\u8be2\u6d3e\u68af\u8bbe\u5907\u5f02\u5e38\uff0c\u539f\u56e0\uff1a", (Throwable)e);
-            throw new ServiceException((Throwable)e);
+        } catch (Exception e) {
+            this.logger.error("根据机构id、标签id、人员id查询派梯设备异常，原因：", e);
+            throw new ServiceException(e);
         }
     }
 
-    @Override
-    public CloudwalkResult listConditionByLabelIds(AcsRestructureQueryParam param, CloudwalkCallContext context) throws ServiceException {
+    public CloudwalkResult listConditionByLabelIds(AcsRestructureQueryParam param, CloudwalkCallContext context)
+        throws ServiceException {
         try {
-            ArrayList<AcsLabelElevatorResult> results = new ArrayList<AcsLabelElevatorResult>();
+            List<AcsLabelElevatorResult> results = new ArrayList<>();
             if (CollectionUtils.isEmpty(param.getLabelIds())) {
                 return CloudwalkResult.success(null);
             }
             AcsPassRuleImageDto dto = new AcsPassRuleImageDto();
             dto.setIncludeLabels(param.getLabelIds());
-            List floorList = this.imageRuleRefDao.listFloorsByRestructure(dto);
-            HashMap<String, List> maps = new HashMap<String, List>();
-            if (CollectionUtils.isEmpty((Collection)floorList)) {
+            List<AcsPassRuleLabelResultDto> floorList = this.imageRuleRefDao.listFloorsByRestructure(dto);
+            Map<String, List<AcsPassRuleLabelResultDto>> maps = new HashMap<>();
+            if (CollectionUtils.isEmpty(floorList)) {
                 for (String label : param.getLabelIds()) {
                     AcsLabelElevatorResult result = new AcsLabelElevatorResult();
                     result.setLabelId(label);
@@ -647,21 +610,21 @@
                 }
             } else {
                 for (AcsPassRuleLabelResultDto resultDto : floorList) {
-                    List dtos = (List)maps.get(resultDto.getLabelId());
-                    if (!CollectionUtils.isEmpty((Collection)dtos)) {
+                    List<AcsPassRuleLabelResultDto> dtos = maps.get(resultDto.getLabelId());
+                    if (!CollectionUtils.isEmpty(dtos)) {
                         dtos.add(resultDto);
                         maps.put(resultDto.getLabelId(), dtos);
                         continue;
                     }
-                    ArrayList<AcsPassRuleLabelResultDto> dtoList = new ArrayList<AcsPassRuleLabelResultDto>();
+                    List<AcsPassRuleLabelResultDto> dtoList = new ArrayList<>();
                     dtoList.add(resultDto);
                     maps.put(resultDto.getLabelId(), dtoList);
                 }
                 for (String label : param.getLabelIds()) {
-                    List dtoList = (List)maps.get(label);
+                    List<AcsPassRuleLabelResultDto> dtoList = maps.get(label);
                     AcsLabelElevatorResult result = new AcsLabelElevatorResult();
                     result.setLabelId(label);
-                    if (!CollectionUtils.isEmpty((Collection)dtoList)) {
+                    if (!CollectionUtils.isEmpty(dtoList)) {
                         result.setDetails(dtoList);
                     } else {
                         result.setDetails(null);
@@ -670,41 +633,42 @@
                 }
             }
             return CloudwalkResult.success(results);
-        }
-        catch (Exception e) {
-            this.logger.error("\u6839\u636e\u6807\u7b7eid\u96c6\u5408\u67e5\u8be2\u6d3e\u68af\u697c\u5c42\u6743\u9650\u5f02\u5e38\uff0c\u539f\u56e0\uff1a", (Throwable)e);
-            throw new ServiceException((Throwable)e);
+        } catch (Exception e) {
+            this.logger.error("根据标签id集合查询派梯楼层权限异常，原因：", e);
+            throw new ServiceException(e);
         }
     }
 
-    @Override
-    public CloudwalkResult<String> bindingFloors(AcsRestructureBindingParam param, CloudwalkCallContext context) throws ServiceException {
+    public CloudwalkResult<String> bindingFloors(AcsRestructureBindingParam param, CloudwalkCallContext context)
+        throws ServiceException {
         try {
             AcsPassRuleImageDto dto = new AcsPassRuleImageDto();
-            if (!ObjectUtils.isEmpty((Object)param.getLabelId())) {
+            if (!ObjectUtils.isEmpty(param.getLabelId())) {
                 dto.setIncludeLabels(Collections.singletonList(param.getLabelId()));
             }
-            if (!ObjectUtils.isEmpty((Object)param.getOrgId())) {
+            if (!ObjectUtils.isEmpty(param.getOrgId())) {
                 dto.setIncludeOrganizations(Collections.singletonList(param.getOrgId()));
             }
-            List floorList = this.imageRuleRefDao.listByRestructure(dto);
-            ArrayList<String> floorIds = new ArrayList<String>();
-            HashMap<String, AcsPassRuleImageResultDto> zoneMap = new HashMap<String, AcsPassRuleImageResultDto>();
+            List<AcsPassRuleImageResultDto> floorList = this.imageRuleRefDao.listByRestructure(dto);
+            List<String> floorIds = new ArrayList<>();
+            Map<String, AcsPassRuleImageResultDto> zoneMap = new HashMap<>();
             for (AcsPassRuleImageResultDto resultDto : floorList) {
                 floorIds.add(resultDto.getZoneId());
                 zoneMap.put(resultDto.getZoneId(), resultDto);
             }
-            ArrayList<AcsPassRuleImageResultDto> addFloors = new ArrayList<AcsPassRuleImageResultDto>();
-            ArrayList<String> delFloorIds = new ArrayList<String>();
-            ArrayList<String> addFloorIds = new ArrayList<String>();
-            if (!CollectionUtils.isEmpty((Collection)floorList)) {
+            List<AcsPassRuleImageResultDto> addFloors = new ArrayList<>();
+            List<String> delFloorIds = new ArrayList<>();
+            List<String> addFloorIds = new ArrayList<>();
+            if (!CollectionUtils.isEmpty(floorList)) {
                 for (AcsPassRuleImageResultDto floor : floorList) {
-                    if (param.getZoneIds().contains(floor.getZoneId())) continue;
-                    delFloorIds.add(floor.getZoneId());
+                    if (!param.getZoneIds().contains(floor.getZoneId())) {
+                        delFloorIds.add(floor.getZoneId());
+                    }
                 }
                 for (String zoneId : param.getZoneIds()) {
-                    if (floorIds.contains(zoneId)) continue;
-                    addFloorIds.add(zoneId);
+                    if (!floorIds.contains(zoneId)) {
+                        addFloorIds.add(zoneId);
+                    }
                 }
                 if (!CollectionUtils.isEmpty(addFloorIds)) {
                     addFloors.addAll(this.imageRuleRefDao.listZoneInfoByIds(addFloorIds));
@@ -713,7 +677,7 @@
                 addFloors.addAll(this.imageRuleRefDao.listZoneInfoByIds(param.getZoneIds()));
             }
             if (!CollectionUtils.isEmpty(addFloors) || !CollectionUtils.isEmpty(delFloorIds)) {
-                String taskId = this.genUUID();
+                String taskId = genUUID();
                 AcsDeviceTaskAddDto addDto = new AcsDeviceTaskAddDto();
                 addDto.setId(taskId);
                 addDto.setAllDevices(Integer.valueOf(addFloors.size() + delFloorIds.size()));
@@ -722,50 +686,51 @@
                 this.acsDeviceTaskDao.insert(addDto);
                 param.setTaskId(taskId);
                 this.acsDeviceTaskService.updateFloors(param, addFloors, delFloorIds, context);
-                return CloudwalkResult.success((Object)taskId);
+                return CloudwalkResult.success(taskId);
             }
             return CloudwalkResult.success(null);
-        }
-        catch (Exception e) {
-            this.logger.error("\u6839\u636e\u673a\u6784id\u3001\u6807\u7b7eid\u3001\u4eba\u5458id\u67e5\u8be2\u6d3e\u68af\u8bbe\u5907\u5f02\u5e38\uff0c\u539f\u56e0\uff1a", (Throwable)e);
-            throw new ServiceException((Throwable)e);
+        } catch (Exception e) {
+            this.logger.error("根据机构id、标签id、人员id查询派梯设备异常，原因：", e);
+            throw new ServiceException(e);
         }
     }
 
-    @Override
-    public CloudwalkResult<String> bindingPerson(AcsRestructureBindingParam param, CloudwalkCallContext context) throws ServiceException {
+    public CloudwalkResult<String> bindingPerson(AcsRestructureBindingParam param, CloudwalkCallContext context)
+        throws ServiceException {
         try {
             AcsPassRuleImageDto dto = new AcsPassRuleImageDto();
             dto.setPersonId(param.getPersonId());
             PersonDetailParam detailParam = new PersonDetailParam();
             detailParam.setId(param.getPersonId());
             detailParam.setBusinessId(context.getCompany().getCompanyId());
-            CloudwalkResult detail = this.personService.detail(detailParam, context);
-            if (!CollectionUtils.isEmpty((Collection)((PersonResult)detail.getData()).getLabelIds())) {
+            CloudwalkResult<PersonResult> detail = this.personService.detail(detailParam, context);
+            if (!CollectionUtils.isEmpty(((PersonResult)detail.getData()).getLabelIds())) {
                 dto.setIncludeLabels(((PersonResult)detail.getData()).getLabelIds());
             }
-            if (!CollectionUtils.isEmpty((Collection)((PersonResult)detail.getData()).getLabelIds())) {
+            if (!CollectionUtils.isEmpty(((PersonResult)detail.getData()).getLabelIds())) {
                 dto.setIncludeOrganizations(((PersonResult)detail.getData()).getOrganizationIds());
             }
-            List floorList = this.imageRuleRefDao.listByPersonInfo(dto);
-            ArrayList<String> floorIds = new ArrayList<String>();
-            HashMap<String, AcsPassRuleImageResultDto> zoneMap = new HashMap<String, AcsPassRuleImageResultDto>();
+            List<AcsPassRuleImageResultDto> floorList = this.imageRuleRefDao.listByPersonInfo(dto);
+            List<String> floorIds = new ArrayList<>();
+            Map<String, AcsPassRuleImageResultDto> zoneMap = new HashMap<>();
             floorList.forEach(floor -> floorIds.add(floor.getZoneId()));
             for (AcsPassRuleImageResultDto resultDto : floorList) {
                 floorIds.add(resultDto.getZoneId());
                 zoneMap.put(resultDto.getZoneId(), resultDto);
             }
-            ArrayList<AcsPassRuleImageResultDto> addFloors = new ArrayList<AcsPassRuleImageResultDto>();
-            ArrayList<String> delFloorIds = new ArrayList<String>();
-            ArrayList<String> addFloorIds = new ArrayList<String>();
-            if (!CollectionUtils.isEmpty((Collection)floorList)) {
-                for (AcsPassRuleImageResultDto floor2 : floorList) {
-                    if (param.getZoneIds().contains(floor2.getZoneId())) continue;
-                    delFloorIds.add(floor2.getZoneId());
+            List<AcsPassRuleImageResultDto> addFloors = new ArrayList<>();
+            List<String> delFloorIds = new ArrayList<>();
+            List<String> addFloorIds = new ArrayList<>();
+            if (!CollectionUtils.isEmpty(floorList)) {
+                for (AcsPassRuleImageResultDto floor : floorList) {
+                    if (!param.getZoneIds().contains(floor.getZoneId())) {
+                        delFloorIds.add(floor.getZoneId());
+                    }
                 }
                 for (String zoneId : param.getZoneIds()) {
-                    if (floorIds.contains(zoneId)) continue;
-                    addFloorIds.add(zoneId);
+                    if (!floorIds.contains(zoneId)) {
+                        addFloorIds.add(zoneId);
+                    }
                 }
                 if (!CollectionUtils.isEmpty(addFloorIds)) {
                     addFloors.addAll(this.imageRuleRefDao.listZoneInfoByIds(addFloorIds));
@@ -774,7 +739,7 @@
                 addFloors.addAll(this.imageRuleRefDao.listZoneInfoByIds(param.getZoneIds()));
             }
             if (!CollectionUtils.isEmpty(addFloors) || !CollectionUtils.isEmpty(delFloorIds)) {
-                String taskId = this.genUUID();
+                String taskId = genUUID();
                 AcsDeviceTaskAddDto addDto = new AcsDeviceTaskAddDto();
                 addDto.setId(taskId);
                 addDto.setAllDevices(Integer.valueOf(addFloors.size() + delFloorIds.size()));
@@ -783,55 +748,53 @@
                 this.acsDeviceTaskDao.insert(addDto);
                 param.setTaskId(taskId);
                 this.acsDeviceTaskService.updateFloors(param, addFloors, delFloorIds, context);
-                return CloudwalkResult.success((Object)taskId);
+                return CloudwalkResult.success(taskId);
             }
             return CloudwalkResult.success(null);
-        }
-        catch (Exception e) {
-            this.logger.error("\u6839\u4eba\u5458\u6279\u91cf\u7ed1\u5b9a\u6d3e\u68af\u697c\u5c42\u5f02\u5e38\uff0c\u539f\u56e0\uff1a", (Throwable)e);
-            throw new ServiceException((Throwable)e);
+        } catch (Exception e) {
+            this.logger.error("根人员批量绑定派梯楼层异常，原因：", e);
+            throw new ServiceException(e);
         }
     }
 
-    @Override
-    public CloudwalkResult<AcsDeviceTaskDTO> getTask(AcsDeviceRestructureTaskParam param, CloudwalkCallContext context) throws ServiceException {
+    public CloudwalkResult<AcsDeviceTaskDTO> getTask(AcsDeviceRestructureTaskParam param, CloudwalkCallContext context)
+        throws ServiceException {
         try {
-            return CloudwalkResult.success((Object)this.acsDeviceTaskDao.getById(param.getTaskId()));
-        }
-        catch (Exception e) {
-            this.logger.error("\u6839\u636e\u4efb\u52a1id\u67e5\u8be2\u4efb\u52a1\u8be6\u60c5\u5f02\u5e38\uff0c\u539f\u56e0\uff1a", (Throwable)e);
-            throw new ServiceException((Throwable)e);
+            return CloudwalkResult.success(this.acsDeviceTaskDao.getById(param.getTaskId()));
+        } catch (Exception e) {
+            this.logger.error("根据任务id查询任务详情异常，原因：", e);
+            throw new ServiceException(e);
         }
     }
 
-    @Override
-    public CloudwalkResult<Boolean> setTaskStop(AcsDeviceRestructureTaskParam param, CloudwalkCallContext context) throws ServiceException {
+    public CloudwalkResult<Boolean> setTaskStop(AcsDeviceRestructureTaskParam param, CloudwalkCallContext context)
+        throws ServiceException {
         try {
             AcsDeviceTaskAddDto dto = new AcsDeviceTaskAddDto();
             dto.setId(param.getTaskId());
             dto.setIsStop(Integer.valueOf(1));
             this.acsDeviceTaskDao.updateIsStop(dto);
-            return CloudwalkResult.success((Object)true);
-        }
-        catch (Exception e) {
-            this.logger.error("\u7f16\u8f91\u4efb\u52a1\u8fdb\u7a0b\u5f02\u5e38\uff0c\u539f\u56e0\uff1a", (Throwable)e);
-            throw new ServiceException((Throwable)e);
+            return CloudwalkResult.success(Boolean.valueOf(true));
+        } catch (Exception e) {
+            this.logger.error("编辑任务进程异常，原因：", e);
+            throw new ServiceException(e);
         }
     }
 
-    private String addImageStore(AcsElevatorDeviceAddParam param, CloudwalkCallContext context) throws ServiceException {
+    private String addImageStore(AcsElevatorDeviceAddParam param, CloudwalkCallContext context)
+        throws ServiceException {
         ImageStoreAddParam imageStoreAddParam = new ImageStoreAddParam();
         String applicationId = this.acsApplicationService.getApplicationId(context.getCompany().getCompanyId());
-        imageStoreAddParam.setName(param.getCurrentBuilding() + "-\u9ed8\u8ba4\u56fe\u5e93");
+        imageStoreAddParam.setName(param.getCurrentBuilding() + "-默认图库");
         imageStoreAddParam.setType(Short.valueOf((short)1));
         imageStoreAddParam.setSourceApplicationId(applicationId);
         imageStoreAddParam.setBusinessId(context.getCompany().getCompanyId());
-        CloudwalkResult imageStoreId = this.imageStoreService.add(imageStoreAddParam, context);
+        CloudwalkResult<String> imageStoreId = this.imageStoreService.add(imageStoreAddParam, context);
         if (!imageStoreId.isSuccess()) {
-            this.logger.info("\u8fdc\u7a0b\u8c03\u7528\u65b0\u589e\u56fe\u5e93\u5931\u8d25,\u539f\u56e0\uff1a" + imageStoreId.getMessage());
+            this.logger.info("远程调用新增图库失败,原因：" + imageStoreId.getMessage());
             throw new ServiceException(imageStoreId.getCode(), imageStoreId.getMessage());
         }
-        this.logger.info("\u8fdc\u7a0b\u8c03\u7528\u65b0\u589e\u56fe\u5e93\u51fa\u53c2\uff1aimageStoreId=[{}]", imageStoreId.getData());
+        this.logger.info("远程调用新增图库出参：imageStoreId=[{}]", imageStoreId.getData());
         DeviceImageStoreAppBindParam appBindParam = new DeviceImageStoreAppBindParam();
         appBindParam.setImageStoreId((String)imageStoreId.getData());
         appBindParam.setApplicationId(applicationId);
@@ -842,27 +805,31 @@
             bindParam.setDeviceId(param.getDeviceId());
             bindParam.setApplicationId(applicationId);
             this.acsDeviceImageStoreAppBindService.bindDeviceAndImageStore(bindParam, context);
-        }
-        catch (ServiceException e) {
-            this.logger.error("\u56fe\u5e93\u5173\u8054\u5931\u8d25,\u56fe\u5e93id={},\u539f\u56e0:{}", imageStoreId.getData(), (Object)e.getMessage());
+        } catch (ServiceException e) {
+            this.logger.error("图库关联失败,图库id={},原因:{}", imageStoreId.getData(), e.getMessage());
             ImageStoreDelParam delParam = new ImageStoreDelParam();
             delParam.setId((String)imageStoreId.getData());
             delParam.setBusinessId(context.getCompany().getCompanyId());
-            this.logger.info("\u56de\u6eda\u5220\u9664\u56fe\u5e93\u5f00\u59cb,delParam={},context={}", JSONObject.toJSON((Object)delParam), JSONObject.toJSON((Object)context));
-            CloudwalkResult deleteResult = this.imageStoreService.delete(delParam, context);
-            this.logger.info("\u5220\u9664\u56fe\u5e93\uff1a\u56fe\u5e93id={},\u7ed3\u679c:{}", (Object)imageStoreId, (Object)deleteResult.getMessage());
+            this.logger.info("回滚删除图库开始,delParam={},context={}", JSONObject.toJSON(delParam),
+                JSONObject.toJSON(context));
+            CloudwalkResult<Boolean> deleteResult = this.imageStoreService.delete(delParam, context);
+            this.logger.info("删除图库：图库id={},结果:{}", imageStoreId, deleteResult.getMessage());
             throw new ServiceException(e.getCode(), e.getMessage());
         }
         return (String)imageStoreId.getData();
     }
 
-    private List<DeviceResult> deviceFilter(List<DeviceResult> pageResult, CloudwalkCallContext context) throws ServiceException {
-        List<AcsDeviceNewResult> acsDeviceNewResults = this.getAcsDeviceIds(context);
-        List acsDeviceIds = acsDeviceNewResults.stream().map(AcsDeviceNewResult::getDeviceId).collect(Collectors.toList());
-        List deviceIds = pageResult.stream().map(DeviceResult::getId).collect(Collectors.toList());
-        List newList = CollectionUtils.removeList(deviceIds, acsDeviceIds);
-        ArrayList<DeviceResult> newDeviceResultList = new ArrayList<DeviceResult>();
-        Map<String, DeviceResult> deviceResultMap = pageResult.stream().collect(Collectors.toMap(DeviceResult::getId, d -> d));
+    private List<DeviceResult> deviceFilter(List<DeviceResult> pageResult, CloudwalkCallContext context)
+        throws ServiceException {
+        List<AcsDeviceNewResult> acsDeviceNewResults = getAcsDeviceIds(context);
+        List<String> acsDeviceIds = (List<String>)acsDeviceNewResults.stream().map(AcsDeviceNewResult::getDeviceId)
+            .collect(Collectors.toList());
+        List<String> deviceIds =
+            (List<String>)pageResult.stream().map(DeviceResult::getId).collect(Collectors.toList());
+        List<String> newList = CollectionUtils.removeList(deviceIds, acsDeviceIds);
+        List<DeviceResult> newDeviceResultList = new ArrayList<>();
+        Map<String, DeviceResult> deviceResultMap =
+            (Map<String, DeviceResult>)pageResult.stream().collect(Collectors.toMap(DeviceResult::getId, d -> d));
         for (String id : newList) {
             newDeviceResultList.add(deviceResultMap.get(id));
         }
@@ -870,30 +837,31 @@
     }
 
     private List<AcsDeviceNewResult> getAcsDeviceIds(CloudwalkCallContext context) throws ServiceException {
-        List acsDeviceList;
-        List<AcsDeviceNewResult> acsDeviceNewResultList = new ArrayList<AcsDeviceNewResult>();
+        List<AcsElevatorDeviceResultDTO> acsDeviceList;
+        List<AcsDeviceNewResult> acsDeviceNewResultList = new ArrayList<>();
         AcsElevatorDeviceQueryDTO dto = new AcsElevatorDeviceQueryDTO();
         dto.setBusinessId(context.getCompany().getCompanyId());
         try {
             acsDeviceList = this.acsElevatorDeviceDao.get(dto);
+        } catch (ServiceException e) {
+            throw new ServiceException("76260007", getMessage("76260007"));
         }
-        catch (ServiceException e) {
-            throw new ServiceException("76260007", this.getMessage("76260007"));
-        }
-        Map<String, String> areaMap = this.getAllAreaMap(context);
-        if (CollectionUtils.isNotEmpty((Collection)acsDeviceList)) {
-            List deviceIds = acsDeviceList.stream().map(AcsElevatorDeviceResultDTO::getDeviceId).collect(Collectors.toList());
+        Map<String, String> areaMap = getAllAreaMap(context);
+        if (CollectionUtils.isNotEmpty(acsDeviceList)) {
+            List<String> deviceIds = (List<String>)acsDeviceList.stream().map(AcsElevatorDeviceResultDTO::getDeviceId)
+                .collect(Collectors.toList());
             DeviceQueryParam queryParam = new DeviceQueryParam();
             queryParam.setIds(deviceIds);
             queryParam.setBusinessId(context.getCompany().getCompanyId());
-            CloudwalkResult deviceResult = this.deviceService.list(queryParam, context);
+            CloudwalkResult<List<DeviceResult>> deviceResult = this.deviceService.list(queryParam, context);
             if (deviceResult.isSuccess()) {
-                if (CollectionUtils.isNotEmpty((Collection)((Collection)deviceResult.getData()))) {
-                    acsDeviceNewResultList = this.convertDeviceNewResult((Collection)deviceResult.getData(), areaMap);
+                if (CollectionUtils.isNotEmpty((Collection)deviceResult.getData())) {
+                    acsDeviceNewResultList =
+                        convertDeviceNewResult((Collection<DeviceResult>)deviceResult.getData(), areaMap);
                 }
             } else {
-                this.logger.error("\u67e5\u8be2\u8bbe\u5907\u4fe1\u606f\u5217\u8868\u5931\u8d25,\u539f\u56e0={}", (Object)deviceResult.getMessage());
-                throw new ServiceException("\u67e5\u8be2\u8bbe\u5907\u4fe1\u606f\u5217\u8868\u5931\u8d25");
+                this.logger.error("查询设备信息列表失败,原因={}", deviceResult.getMessage());
+                throw new ServiceException("查询设备信息列表失败");
             }
         }
         return acsDeviceNewResultList;
@@ -903,29 +871,31 @@
         DeviceAreaTreeParam areaTreeParam = new DeviceAreaTreeParam();
         areaTreeParam.setBusinessId(context.getCompany().getCompanyId());
         CloudwalkResult<List<AreaTreeResult>> areaTree = this.acsAreaTreeCacheableService.tree(areaTreeParam, context);
-        HashMap<String, String> areaMap = new HashMap<String, String>();
-        this.getAreaMap((List)areaTree.getData(), areaMap);
+        Map<String, String> areaMap = new HashMap<>();
+        getAreaMap((List<AreaTreeResult>)areaTree.getData(), areaMap);
         return areaMap;
     }
 
     protected void getAreaMap(List<AreaTreeResult> areaTreeResultList, Map<String, String> areaMap) {
         for (AreaTreeResult areaTree : areaTreeResultList) {
             areaMap.put(areaTree.getId(), areaTree.getName());
-            if (areaTree.getChildren() == null) continue;
-            this.getAreaMap(areaTree.getChildren(), areaMap);
+            if (areaTree.getChildren() != null) {
+                getAreaMap(areaTree.getChildren(), areaMap);
+            }
         }
     }
 
-    protected List<AcsDeviceNewResult> convertDeviceNewResult(Collection<DeviceResult> datas, Map<String, String> areaMap) {
-        ArrayList<AcsDeviceNewResult> result = new ArrayList<AcsDeviceNewResult>();
+    protected List<AcsDeviceNewResult> convertDeviceNewResult(Collection<DeviceResult> datas,
+        Map<String, String> areaMap) {
+        List<AcsDeviceNewResult> result = new ArrayList<>();
         for (DeviceResult data : datas) {
             AcsDeviceNewResult acsDeviceResult = new AcsDeviceNewResult();
-            BeanCopyUtils.copyProperties((Object)data, (Object)acsDeviceResult);
+            BeanCopyUtils.copyProperties(data, acsDeviceResult);
             acsDeviceResult.setId(data.getId());
             acsDeviceResult.setDeviceId(data.getId());
             acsDeviceResult.setDeviceStatus(Integer.valueOf(data.getStatus()));
             acsDeviceResult.setDeviceOnlineStatus(Integer.valueOf(data.getOnlineStatus()));
-            acsDeviceResult.setAddress(this.getAddress(data));
+            acsDeviceResult.setAddress(getAddress(data));
             acsDeviceResult.setAreaName(areaMap.get(data.getAreaId()));
             result.add(acsDeviceResult);
         }
@@ -934,10 +904,10 @@
 
     protected String getAddress(DeviceResult data) {
         StringBuffer sb = new StringBuffer();
-        if (StringUtils.isNotBlank((String)data.getDistrictMergeName())) {
+        if (StringUtils.isNotBlank(data.getDistrictMergeName())) {
             sb.append(data.getDistrictMergeName());
         }
-        if (StringUtils.isNotBlank((String)data.getAreaName())) {
+        if (StringUtils.isNotBlank(data.getAreaName())) {
             sb.append(" ");
             sb.append(data.getAreaName());
         }
@@ -945,16 +915,15 @@
     }
 
     private List<DeviceResult> page(List<AcsDeviceNewResult> dataList, int pageSize, int currentPage) {
-        ArrayList<DeviceResult> currentPageList = new ArrayList<DeviceResult>();
+        List<DeviceResult> currentPageList = new ArrayList<>();
         if (dataList != null && dataList.size() > 0) {
-            int currIdx = currentPage > 1 ? (currentPage - 1) * pageSize : 0;
-            for (int i = 0; i < pageSize && i < dataList.size() - currIdx; ++i) {
+            int currIdx = (currentPage > 1) ? ((currentPage - 1) * pageSize) : 0;
+            for (int i = 0; i < pageSize && i < dataList.size() - currIdx; i++) {
                 AcsDeviceNewResult data = dataList.get(currIdx + i);
-                DeviceResult deviceResult = (DeviceResult)BeanCopyUtils.copyProperties((Object)data, DeviceResult.class);
+                DeviceResult deviceResult = (DeviceResult)BeanCopyUtils.copyProperties(data, DeviceResult.class);
                 currentPageList.add(deviceResult);
             }
         }
         return currentPageList;
     }
 }
-
