Browse Source

Merge branch 'dev'

dev
sunyuchao 4 years ago
parent
commit
3f3e8c1a1e
  1. 2
      epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/form/GetListSocietyOrgFormDTO.java
  2. 4
      epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcSocietyOrgServiceImpl.java
  3. 5
      epmet-module/epmet-heart/epmet-heart-server/src/main/resources/mapper/IcSocietyOrgDao.xml

2
epmet-module/epmet-heart/epmet-heart-client/src/main/java/com/epmet/dto/form/GetListSocietyOrgFormDTO.java

@ -54,5 +54,7 @@ public class GetListSocietyOrgFormDTO implements Serializable {
private String staffId; private String staffId;
//token中userId所属组织的pid //token中userId所属组织的pid
private String pids; private String pids;
//token中userId所属组织Id
private String agencyId;
} }

4
epmet-module/epmet-heart/epmet-heart-server/src/main/java/com/epmet/service/impl/IcSocietyOrgServiceImpl.java

@ -117,7 +117,9 @@ public class IcSocietyOrgServiceImpl extends BaseServiceImpl<IcSocietyOrgDao, Ic
public GetListSocietyOrgResultDTO getList(GetListSocietyOrgFormDTO formDTO) { public GetListSocietyOrgResultDTO getList(GetListSocietyOrgFormDTO formDTO) {
GetListSocietyOrgResultDTO resultDTO = new GetListSocietyOrgResultDTO(); GetListSocietyOrgResultDTO resultDTO = new GetListSocietyOrgResultDTO();
CustomerStaffInfoCacheResult staffInfoCache = CustomerStaffRedis.getStaffInfo(formDTO.getCustomerId(), formDTO.getStaffId()); CustomerStaffInfoCacheResult staffInfoCache = CustomerStaffRedis.getStaffInfo(formDTO.getCustomerId(), formDTO.getStaffId());
formDTO.setPids(staffInfoCache.getAgencyPIds()); //2022.1.7 应产品要求 当前组织只能看到自己组织添加的社会组织数据,不允许看其他下级的
//formDTO.setPids(staffInfoCache.getAgencyPIds());
formDTO.setAgencyId(staffInfoCache.getAgencyId());
//1.根据查询条件分页查询社会组织数据 //1.根据查询条件分页查询社会组织数据
PageInfo<SocietyOrgListResultDTO> result = PageInfo<SocietyOrgListResultDTO> result =
PageHelper.startPage(formDTO.getPageNo(), formDTO.getPageSize(), formDTO.getIsPage()).doSelectPageInfo(() -> baseDao.getList(formDTO)); PageHelper.startPage(formDTO.getPageNo(), formDTO.getPageSize(), formDTO.getIsPage()).doSelectPageInfo(() -> baseDao.getList(formDTO));

5
epmet-module/epmet-heart/epmet-heart-server/src/main/resources/mapper/IcSocietyOrgDao.xml

@ -24,8 +24,11 @@
<if test="customerId != null and customerId.trim() != ''"> <if test="customerId != null and customerId.trim() != ''">
AND customer_id = #{customerId} AND customer_id = #{customerId}
</if> </if>
<if test="pids != null and pids.trim() != ''"> <!-- <if test="pids != null and pids.trim() != ''">
AND pids LIKE CONCAT('%', #{pids}, '%') AND pids LIKE CONCAT('%', #{pids}, '%')
</if>-->
<if test="agencyId != null and agencyId.trim() != ''">
AND agency_id = #{agencyId}
</if> </if>
<if test="societyName != null and societyName.trim() != ''"> <if test="societyName != null and societyName.trim() != ''">
AND society_name LIKE CONCAT('%', #{societyName}, '%') AND society_name LIKE CONCAT('%', #{societyName}, '%')

Loading…
Cancel
Save