|
@ -58,9 +58,11 @@ public class HouseInformationServiceImpl implements HouseInformationService { |
|
|
*/ |
|
|
*/ |
|
|
@Override |
|
|
@Override |
|
|
public CommunityCountResultDTO getCommunityCount(HouseInformationFormDTO formDTO) { |
|
|
public CommunityCountResultDTO getCommunityCount(HouseInformationFormDTO formDTO) { |
|
|
if (StringUtils.isEmpty(formDTO.getCommunityId())) { |
|
|
|
|
|
//获取工作人员所属组织
|
|
|
//获取工作人员所属组织
|
|
|
CustomerStaffInfoCacheResult staffInfo = CustomerStaffRedis.getStaffInfo(formDTO.getCustomerId(), formDTO.getStaffId()); |
|
|
CustomerStaffInfoCacheResult staffInfo = CustomerStaffRedis.getStaffInfo(formDTO.getCustomerId(), formDTO.getStaffId()); |
|
|
|
|
|
if (StringUtils.isEmpty(formDTO.getCommunityId())) { |
|
|
|
|
|
//获取工作人员所属组织
|
|
|
|
|
|
// CustomerStaffInfoCacheResult staffInfo = CustomerStaffRedis.getStaffInfo(formDTO.getCustomerId(), formDTO.getStaffId());
|
|
|
if (null == staffInfo) { |
|
|
if (null == staffInfo) { |
|
|
throw new EpmetException(EpmetErrorCode.EPMET_COMMON_OPERATION_FAIL.getCode(), "获取用户信息失败", "获取用户信息失败"); |
|
|
throw new EpmetException(EpmetErrorCode.EPMET_COMMON_OPERATION_FAIL.getCode(), "获取用户信息失败", "获取用户信息失败"); |
|
|
} |
|
|
} |
|
@ -68,9 +70,12 @@ public class HouseInformationServiceImpl implements HouseInformationService { |
|
|
} |
|
|
} |
|
|
String orgName; |
|
|
String orgName; |
|
|
CustomerAgencyEntity agency = customerAgencyDao.selectById(formDTO.getCommunityId()); |
|
|
CustomerAgencyEntity agency = customerAgencyDao.selectById(formDTO.getCommunityId()); |
|
|
|
|
|
if (null == agency) { |
|
|
|
|
|
agency = customerAgencyDao.selectById(staffInfo.getAgencyId()); |
|
|
if (null == agency) { |
|
|
if (null == agency) { |
|
|
throw new EpmetException(EpmetErrorCode.EPMET_COMMON_OPERATION_FAIL.getCode(), "社区不存在", "社区不存在"); |
|
|
throw new EpmetException(EpmetErrorCode.EPMET_COMMON_OPERATION_FAIL.getCode(), "社区不存在", "社区不存在"); |
|
|
} |
|
|
} |
|
|
|
|
|
} |
|
|
CustomerAgencyEntity parentAgency = customerAgencyDao.selectById(agency.getPid()); |
|
|
CustomerAgencyEntity parentAgency = customerAgencyDao.selectById(agency.getPid()); |
|
|
if (null == parentAgency) { |
|
|
if (null == parentAgency) { |
|
|
orgName = agency.getOrganizationName(); |
|
|
orgName = agency.getOrganizationName(); |
|
|