diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/ImportGeneralDTO.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/ImportGeneralDTO.java index 1bfeb17521..ca5408d581 100644 --- a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/ImportGeneralDTO.java +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/ImportGeneralDTO.java @@ -98,7 +98,7 @@ public class ImportGeneralDTO implements Serializable { private String purpose; /** - * 房屋状态 1:出租 0:自住 2:闲置 + * 房屋状态 1:出租 0:自住 2:闲置 3:未出售 */ private String rentFlagString; private Integer rentFlag; diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/GetAgencyListFormDTO.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/GetAgencyListFormDTO.java index 0d97988fd7..95c371ad83 100644 --- a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/GetAgencyListFormDTO.java +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/GetAgencyListFormDTO.java @@ -15,4 +15,8 @@ public class GetAgencyListFormDTO implements Serializable { private static final long serialVersionUID = -5846836779036328298L; private String customerId; + + + //当前登录用户id,从tokenDto中获取 + private String userId; } diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/IcHouseAddFormDTO.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/IcHouseAddFormDTO.java index 8882060a2e..a07f4fe886 100644 --- a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/IcHouseAddFormDTO.java +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/IcHouseAddFormDTO.java @@ -81,7 +81,7 @@ public class IcHouseAddFormDTO implements Serializable { private String purpose; /** - * 1:出租 0:自住 2:闲置 + * 1:出租 0:自住 2:闲置 3: 未出售 */ @NotNull(message = "房屋状态不能为空", groups = {AddShowGroup.class, UpdateShowGroup.class}) private Integer rentFlag; diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/IcHouseListFormDTO.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/IcHouseListFormDTO.java index 0e2e25a049..bfff2b0709 100644 --- a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/IcHouseListFormDTO.java +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/form/IcHouseListFormDTO.java @@ -48,7 +48,7 @@ public class IcHouseListFormDTO extends PageFormDTO { */ private String ownerPhone; /** - * 房屋状态 【1:出租 0:自住 2:闲置】 + * 房屋状态 【1:出租 0:自住 2:闲置 3:未出售】 */ private String rentFlag; /** diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/HouseChartResultDTO.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/HouseChartResultDTO.java index 7a4e974162..aed43f1b0c 100644 --- a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/HouseChartResultDTO.java +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/dto/result/HouseChartResultDTO.java @@ -50,7 +50,7 @@ public class HouseChartResultDTO implements Serializable { @JsonIgnore private Integer num; - //1:出租 0:自住 2:闲置 + //1:出租 0:自住 2:闲置 3:未出售 @JsonIgnore private Integer rentFlag; diff --git a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/enums/HouseRentFlagEnums.java b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/enums/HouseRentFlagEnums.java index 27cd699bf3..32337f847d 100644 --- a/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/enums/HouseRentFlagEnums.java +++ b/epmet-module/gov-org/gov-org-client/src/main/java/com/epmet/enums/HouseRentFlagEnums.java @@ -8,7 +8,8 @@ public enum HouseRentFlagEnums { NO(0,"否");*/ HOUSE_ZZ(0,"自住"), HOUSE_CZ(1,"出租"), - HOUSE_XZ(2,"闲置"); + HOUSE_XZ(2,"闲置"), + HOUSE_WCS(3,"未出售"); @@ -41,7 +42,7 @@ public enum HouseRentFlagEnums { public static Integer getCodeByName(String name){ if(StringUtils.isEmpty(name)){ - return 0; + return null; } for (HouseRentFlagEnums e : HouseRentFlagEnums.values()) { if (e.getName().equals(name)) { diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/CustomerAgencyController.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/CustomerAgencyController.java index 557a987c09..5325163074 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/CustomerAgencyController.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/CustomerAgencyController.java @@ -354,6 +354,20 @@ public class CustomerAgencyController { return new Result().ok(customerAgencyService.getAgencyList(formDTO)); } + /** + * 工作端,获取当前登录用户所属组织及下级的组织树(不包括网格!!!!!!!!!!) + * @param tokenDTO + * @param formDTO + * @return + */ + @PostMapping("my-subagency-list") + public Result getMySubAgencyList(@LoginUser TokenDto tokenDTO,@RequestBody GetAgencyListFormDTO formDTO) { + formDTO.setCustomerId(tokenDTO.getCustomerId()); + formDTO.setUserId(tokenDTO.getUserId()); + return new Result().ok(customerAgencyService.getMySubAgencyList(formDTO)); + } + + /** * @description 通过staffId查询跟组织列表 * diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/dao/CustomerAgencyDao.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/dao/CustomerAgencyDao.java index 892ef61681..02e483d9f2 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/dao/CustomerAgencyDao.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/dao/CustomerAgencyDao.java @@ -250,7 +250,7 @@ public interface CustomerAgencyDao extends BaseDao { */ OrgResultDTO selectAgencyDetail(@Param("orgId") String orgId, @Param("orgType") String orgType); - AgencyTreeResultDTO getAllAgency(@Param("customerId") String customerId); + AgencyTreeResultDTO getAllAgency(@Param("customerId") String customerId,@Param("staffAgencyId")String staffAgencyId); List getSubAgencyList(@Param("pid") String pid); diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/entity/IcHouseEntity.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/entity/IcHouseEntity.java index 5940608292..a535667426 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/entity/IcHouseEntity.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/entity/IcHouseEntity.java @@ -83,7 +83,7 @@ public class IcHouseEntity extends BaseEpmetEntity { private String purpose; /** - * 1出租;0未出租 + * 1:出租 0:自住 2:闲置 3:未出售 */ private Integer rentFlag; diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/model/ImportHouseInfoListener.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/model/ImportHouseInfoListener.java index b070543014..2d9bb999e8 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/model/ImportHouseInfoListener.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/model/ImportHouseInfoListener.java @@ -191,12 +191,14 @@ public class ImportHouseInfoListener extends AnalysisEventListener */ AgencyTreeResultDTO getAgencyList(GetAgencyListFormDTO formDTO); + /** + * 工作端,获取当前登录用户所属组织及下级的组织树(不包括网格!!!!!!!!!!) + * @param formDTO + * @return + */ + AgencyTreeResultDTO getMySubAgencyList(GetAgencyListFormDTO formDTO); + List getStaffOrgListByStaffId(String staffId); /** diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerAgencyServiceImpl.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerAgencyServiceImpl.java index f21337742e..adaf547abf 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerAgencyServiceImpl.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerAgencyServiceImpl.java @@ -24,6 +24,7 @@ import com.epmet.commons.mybatis.service.impl.BaseServiceImpl; import com.epmet.commons.tools.constant.FieldConstant; import com.epmet.commons.tools.constant.NumConstant; import com.epmet.commons.tools.constant.StrConstant; +import com.epmet.commons.tools.dto.result.CustomerStaffInfoCacheResult; import com.epmet.commons.tools.enums.PartyOrgTypeEnum; import com.epmet.commons.tools.exception.EpmetErrorCode; import com.epmet.commons.tools.exception.EpmetException; @@ -32,6 +33,7 @@ import com.epmet.commons.tools.page.PageData; import com.epmet.commons.tools.redis.RedisKeys; import com.epmet.commons.tools.redis.RedisUtils; import com.epmet.commons.tools.redis.common.CustomerOrgRedis; +import com.epmet.commons.tools.redis.common.CustomerStaffRedis; import com.epmet.commons.tools.redis.common.bean.AgencyInfoCache; import com.epmet.commons.tools.utils.ConvertUtils; import com.epmet.commons.tools.utils.Result; @@ -1136,7 +1138,7 @@ public class CustomerAgencyServiceImpl extends BaseServiceImpl categories = new ArrayList<>(); if (null != countMap && CollectionUtils.isNotEmpty(categoryList)) { for (IcResiCategoryStatsConfigDTO category : categoryList) { @@ -302,4 +290,4 @@ public class IcHouseServiceImpl extends BaseServiceImpl - select ID AS agencyId, ORGANIZATION_NAME AS agencyName, @@ -630,8 +632,13 @@ customer_agency where DEL_FLAG = 0 - AND PID ='0' AND CUSTOMER_ID = #{customerId} + + AND id = #{staffAgencyId} + + + AND PID ='0' +