|  | @ -24,6 +24,7 @@ import com.epmet.commons.tools.constant.FieldConstant; | 
			
		
	
		
		
			
				
					|  |  | import com.epmet.commons.tools.constant.NumConstant; |  |  | import com.epmet.commons.tools.constant.NumConstant; | 
			
		
	
		
		
			
				
					|  |  | import com.epmet.commons.tools.constant.StrConstant; |  |  | import com.epmet.commons.tools.constant.StrConstant; | 
			
		
	
		
		
			
				
					|  |  | import com.epmet.commons.tools.dto.result.CustomerStaffInfoCacheResult; |  |  | import com.epmet.commons.tools.dto.result.CustomerStaffInfoCacheResult; | 
			
		
	
		
		
			
				
					|  |  |  |  |  | import com.epmet.commons.tools.enums.DictTypeEnum; | 
			
		
	
		
		
			
				
					|  |  | import com.epmet.commons.tools.exception.EpmetErrorCode; |  |  | import com.epmet.commons.tools.exception.EpmetErrorCode; | 
			
		
	
		
		
			
				
					|  |  | import com.epmet.commons.tools.exception.RenException; |  |  | import com.epmet.commons.tools.exception.RenException; | 
			
		
	
		
		
			
				
					|  |  | import com.epmet.commons.tools.page.PageData; |  |  | import com.epmet.commons.tools.page.PageData; | 
			
		
	
	
		
		
			
				
					|  | @ -43,6 +44,7 @@ import com.epmet.dto.result.AllGridsByUserIdResultDTO; | 
			
		
	
		
		
			
				
					|  |  | import com.epmet.dto.result.UserBaseInfoResultDTO; |  |  | import com.epmet.dto.result.UserBaseInfoResultDTO; | 
			
		
	
		
		
			
				
					|  |  | import com.epmet.dto.result.demand.DemandRecResultDTO; |  |  | import com.epmet.dto.result.demand.DemandRecResultDTO; | 
			
		
	
		
		
			
				
					|  |  | import com.epmet.entity.*; |  |  | import com.epmet.entity.*; | 
			
		
	
		
		
			
				
					|  |  |  |  |  | import com.epmet.feign.EpmetAdminOpenFeignClient; | 
			
		
	
		
		
			
				
					|  |  | import com.epmet.feign.EpmetUserOpenFeignClient; |  |  | import com.epmet.feign.EpmetUserOpenFeignClient; | 
			
		
	
		
		
			
				
					|  |  | import com.epmet.feign.GovOrgOpenFeignClient; |  |  | import com.epmet.feign.GovOrgOpenFeignClient; | 
			
		
	
		
		
			
				
					|  |  | import com.epmet.service.IcResiDemandDictService; |  |  | import com.epmet.service.IcResiDemandDictService; | 
			
		
	
	
		
		
			
				
					|  | @ -50,6 +52,7 @@ import com.epmet.service.IcUserDemandRecService; | 
			
		
	
		
		
			
				
					|  |  | import com.github.pagehelper.PageHelper; |  |  | import com.github.pagehelper.PageHelper; | 
			
		
	
		
		
			
				
					|  |  | import com.github.pagehelper.PageInfo; |  |  | import com.github.pagehelper.PageInfo; | 
			
		
	
		
		
			
				
					|  |  | import org.apache.commons.collections4.CollectionUtils; |  |  | import org.apache.commons.collections4.CollectionUtils; | 
			
		
	
		
		
			
				
					|  |  |  |  |  | import org.apache.commons.collections4.MapUtils; | 
			
		
	
		
		
			
				
					|  |  | import org.apache.commons.lang3.StringUtils; |  |  | import org.apache.commons.lang3.StringUtils; | 
			
		
	
		
		
			
				
					|  |  | import org.springframework.beans.factory.annotation.Autowired; |  |  | import org.springframework.beans.factory.annotation.Autowired; | 
			
		
	
		
		
			
				
					|  |  | import org.springframework.stereotype.Service; |  |  | import org.springframework.stereotype.Service; | 
			
		
	
	
		
		
			
				
					|  | @ -79,7 +82,8 @@ public class IcUserDemandRecServiceImpl extends BaseServiceImpl<IcUserDemandRecD | 
			
		
	
		
		
			
				
					|  |  |     private IcResiDemandDictService demandDictService; |  |  |     private IcResiDemandDictService demandDictService; | 
			
		
	
		
		
			
				
					|  |  |     @Autowired |  |  |     @Autowired | 
			
		
	
		
		
			
				
					|  |  |     private EpmetUserOpenFeignClient epmetUserOpenFeignClient; |  |  |     private EpmetUserOpenFeignClient epmetUserOpenFeignClient; | 
			
		
	
		
		
			
				
					
					|  |  | 
 |  |  |     @Autowired | 
			
				
				
			
		
	
		
		
	
		
		
			
				
					|  |  |  |  |  |     private EpmetAdminOpenFeignClient adminOpenFeignClient; | 
			
		
	
		
		
			
				
					|  |  | 
 |  |  | 
 | 
			
		
	
		
		
			
				
					|  |  |     @Override |  |  |     @Override | 
			
		
	
		
		
			
				
					|  |  |     public PageData<IcUserDemandRecDTO> page(Map<String, Object> params) { |  |  |     public PageData<IcUserDemandRecDTO> page(Map<String, Object> params) { | 
			
		
	
	
		
		
			
				
					|  | @ -238,6 +242,17 @@ public class IcUserDemandRecServiceImpl extends BaseServiceImpl<IcUserDemandRecD | 
			
		
	
		
		
			
				
					|  |  |                 } |  |  |                 } | 
			
		
	
		
		
			
				
					|  |  |                 userInfoMap=userInfoRes.getData().stream().collect(Collectors.toMap(UserBaseInfoResultDTO::getUserId, UserBaseInfoResultDTO::getRealName)); |  |  |                 userInfoMap=userInfoRes.getData().stream().collect(Collectors.toMap(UserBaseInfoResultDTO::getUserId, UserBaseInfoResultDTO::getRealName)); | 
			
		
	
		
		
			
				
					|  |  |             } |  |  |             } | 
			
		
	
		
		
			
				
					|  |  |  |  |  | 
 | 
			
		
	
		
		
			
				
					|  |  |  |  |  |             //查询字典表
 | 
			
		
	
		
		
			
				
					|  |  |  |  |  |             Result<Map<String, String>> reportTypeRes=adminOpenFeignClient.dictMap(DictTypeEnum.USER_DEMAND_REPORT_TYPE.getCode()); | 
			
		
	
		
		
			
				
					|  |  |  |  |  |             Map<String,String> reportTypeMap=reportTypeRes.success()&& MapUtils.isNotEmpty(reportTypeRes.getData())?reportTypeRes.getData():new HashMap<>(); | 
			
		
	
		
		
			
				
					|  |  |  |  |  | 
 | 
			
		
	
		
		
			
				
					|  |  |  |  |  |             Result<Map<String, String>> statusRes=adminOpenFeignClient.dictMap(DictTypeEnum.USER_DEMAND_STATUS.getCode()); | 
			
		
	
		
		
			
				
					|  |  |  |  |  |             Map<String,String> statusMap=statusRes.success()&& MapUtils.isNotEmpty(statusRes.getData())?statusRes.getData():new HashMap<>(); | 
			
		
	
		
		
			
				
					|  |  |  |  |  | 
 | 
			
		
	
		
		
			
				
					|  |  |  |  |  |             Result<Map<String, String>> serviceTypeRes=adminOpenFeignClient.dictMap(DictTypeEnum.USER_DEMAND_SERVICE_TYPE.getCode()); | 
			
		
	
		
		
			
				
					|  |  |  |  |  |             Map<String,String> serviceTypeMap=serviceTypeRes.success()&& MapUtils.isNotEmpty(serviceTypeRes.getData())?serviceTypeRes.getData():new HashMap<>(); | 
			
		
	
		
		
			
				
					|  |  |  |  |  | 
 | 
			
		
	
		
		
			
				
					|  |  |             for(DemandRecResultDTO res:list){ |  |  |             for(DemandRecResultDTO res:list){ | 
			
		
	
		
		
			
				
					|  |  |                 if (null != gridInfoMap && gridInfoMap.containsKey(res.getGridId())) { |  |  |                 if (null != gridInfoMap && gridInfoMap.containsKey(res.getGridId())) { | 
			
		
	
		
		
			
				
					|  |  |                     res.setGridName(gridInfoMap.get(res.getGridId()).getGridName()); |  |  |                     res.setGridName(gridInfoMap.get(res.getGridId()).getGridName()); | 
			
		
	
	
		
		
			
				
					|  | @ -251,7 +266,8 @@ public class IcUserDemandRecServiceImpl extends BaseServiceImpl<IcUserDemandRecD | 
			
		
	
		
		
			
				
					|  |  |                     res.setServiceName(userInfoMap.get(res.getServerId())); |  |  |                     res.setServiceName(userInfoMap.get(res.getServerId())); | 
			
		
	
		
		
			
				
					|  |  |                 } |  |  |                 } | 
			
		
	
		
		
			
				
					|  |  |                 //社区帮办:community;楼长帮办:building_caption;党员帮办:party;自身上报:self_help
 |  |  |                 //社区帮办:community;楼长帮办:building_caption;党员帮办:party;自身上报:self_help
 | 
			
		
	
		
		
			
				
					
					|  |  |                 switch(res.getReportType()){ |  |  |                 res.setReportTypeName(reportTypeMap.containsKey(res.getReportType())?reportTypeMap.get(res.getReportType()):StrConstant.EPMETY_STR); | 
			
				
				
			
		
	
		
		
	
		
		
			
				
					|  |  |  |  |  |                 /*switch(res.getReportType()){ | 
			
		
	
		
		
			
				
					|  |  |                     case UserDemandConstant.COMMUNITY_REPORT : |  |  |                     case UserDemandConstant.COMMUNITY_REPORT : | 
			
		
	
		
		
			
				
					|  |  |                         res.setReportTypeName("社区帮办"); |  |  |                         res.setReportTypeName("社区帮办"); | 
			
		
	
		
		
			
				
					|  |  |                         break; |  |  |                         break; | 
			
		
	
	
		
		
			
				
					|  | @ -264,9 +280,10 @@ public class IcUserDemandRecServiceImpl extends BaseServiceImpl<IcUserDemandRecD | 
			
		
	
		
		
			
				
					|  |  |                     case UserDemandConstant.SELF_HELP_REPORT : |  |  |                     case UserDemandConstant.SELF_HELP_REPORT : | 
			
		
	
		
		
			
				
					|  |  |                         res.setReportTypeName("自身上报"); |  |  |                         res.setReportTypeName("自身上报"); | 
			
		
	
		
		
			
				
					|  |  |                         break; |  |  |                         break; | 
			
		
	
		
		
			
				
					
					|  |  |                 } |  |  |                 }*/ | 
			
				
				
			
		
	
		
		
	
		
		
			
				
					|  |  |                  //待处理:pending;已取消canceled;已派单:assigned;已接单:have_order;已完成:finished
 |  |  |                  //待处理:pending;已取消canceled;已派单:assigned;已接单:have_order;已完成:finished
 | 
			
		
	
		
		
			
				
					
					|  |  |                 switch(res.getStatus()){ |  |  |                 res.setStatusName(statusMap.containsKey(res.getStatus())?statusMap.get(res.getStatus()):StrConstant.EPMETY_STR); | 
			
				
				
			
		
	
		
		
	
		
		
			
				
					|  |  |  |  |  |                 /*switch(res.getStatus()){ | 
			
		
	
		
		
			
				
					|  |  |                     case UserDemandConstant.PENDING : |  |  |                     case UserDemandConstant.PENDING : | 
			
		
	
		
		
			
				
					|  |  |                         res.setStatusName("待处理"); |  |  |                         res.setStatusName("待处理"); | 
			
		
	
		
		
			
				
					|  |  |                         break; |  |  |                         break; | 
			
		
	
	
		
		
			
				
					|  | @ -282,9 +299,10 @@ public class IcUserDemandRecServiceImpl extends BaseServiceImpl<IcUserDemandRecD | 
			
		
	
		
		
			
				
					|  |  |                     case UserDemandConstant.FINISHED : |  |  |                     case UserDemandConstant.FINISHED : | 
			
		
	
		
		
			
				
					|  |  |                         res.setStatusName("已完成"); |  |  |                         res.setStatusName("已完成"); | 
			
		
	
		
		
			
				
					|  |  |                         break; |  |  |                         break; | 
			
		
	
		
		
			
				
					
					|  |  |                 } |  |  |                 }*/ | 
			
				
				
			
		
	
		
		
	
		
		
			
				
					|  |  |                  //服务方类型:志愿者:volunteer;社会组织:social_org;社区自组织:community_org;区域党建单位:party_unit;
 |  |  |                  //服务方类型:志愿者:volunteer;社会组织:social_org;社区自组织:community_org;区域党建单位:party_unit;
 | 
			
		
	
		
		
			
				
					
					|  |  |                 switch(res.getServiceType()){ |  |  |                 res.setServiceShowName(serviceTypeMap.containsKey(res.getServiceType())?serviceTypeMap.get(res.getServiceType()):StrConstant.EPMETY_STR); | 
			
				
				
			
		
	
		
		
	
		
		
			
				
					|  |  |  |  |  |                 /*switch(res.getServiceType()){ | 
			
		
	
		
		
			
				
					|  |  |                     case UserDemandConstant.VOLUNTEER : |  |  |                     case UserDemandConstant.VOLUNTEER : | 
			
		
	
		
		
			
				
					|  |  |                         res.setServiceShowName(res.getServiceName().concat("(志愿者)")); |  |  |                         res.setServiceShowName(res.getServiceName().concat("(志愿者)")); | 
			
		
	
		
		
			
				
					|  |  |                         break; |  |  |                         break; | 
			
		
	
	
		
		
			
				
					|  | @ -297,7 +315,7 @@ public class IcUserDemandRecServiceImpl extends BaseServiceImpl<IcUserDemandRecD | 
			
		
	
		
		
			
				
					|  |  |                     case UserDemandConstant.PARTY_UNIT : |  |  |                     case UserDemandConstant.PARTY_UNIT : | 
			
		
	
		
		
			
				
					|  |  |                         res.setServiceShowName(res.getServiceName().concat("(区域化党建单位)")); |  |  |                         res.setServiceShowName(res.getServiceName().concat("(区域化党建单位)")); | 
			
		
	
		
		
			
				
					|  |  |                         break; |  |  |                         break; | 
			
		
	
		
		
			
				
					
					|  |  |                 } |  |  |                 }*/ | 
			
				
				
			
		
	
		
		
	
		
		
			
				
					|  |  |             } |  |  |             } | 
			
		
	
		
		
			
				
					|  |  |         } |  |  |         } | 
			
		
	
		
		
			
				
					|  |  |         return new PageData<>(list, pageInfo.getTotal()); |  |  |         return new PageData<>(list, pageInfo.getTotal()); | 
			
		
	
	
		
		
			
				
					|  | 
 |