去掉加字段
This commit is contained in:
@@ -66,24 +66,12 @@
|
||||
c.username AS createUserName,
|
||||
c.mobile AS createUserMobile,
|
||||
a.created_time AS createTime,
|
||||
a.audit_status AS auditStatus,
|
||||
b.region_id as regionId,
|
||||
d.investment_manager AS investmentManagerId
|
||||
a.audit_status AS auditStatus
|
||||
FROM
|
||||
xfsg_pre_fry_qualification_apply a
|
||||
LEFT JOIN store_${enterpriseId} b ON a.store_code = b.store_num
|
||||
LEFT JOIN xfsg_line_info c ON c.partner_id = a.created_user_id
|
||||
left join xfsg_shop_info d ON d.shop_code = a.store_code
|
||||
<where>
|
||||
<if test = "regionIds !=null and regionIds.size()>0">
|
||||
and b.region_id in
|
||||
<foreach item="item" index="index" collection="regionIds" separator="," open="(" close=")">
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="investmentManagerId != null and investmentManagerId != ''">
|
||||
and d.investment_manager = #{investmentManagerId}
|
||||
</if>
|
||||
<if test="applyCode !=null and applyCode != ''">
|
||||
and a.apply_code LIKE CONCAT('%', #{applyCode}, '%')
|
||||
</if>
|
||||
|
||||
@@ -26,30 +26,28 @@ public class ApplyManagementDTO {
|
||||
private String applyCode;
|
||||
@ApiModelProperty("申请类型:1-有冷藏展示柜,2-有常温展示柜,3-无展示柜 ")
|
||||
private Integer applyType;
|
||||
@ExcelProperty(value = "申请类型",order =6)
|
||||
@ExcelProperty(value = "申请类型",order =4)
|
||||
private String applyTypeName;
|
||||
@ApiModelProperty("申请人ID")
|
||||
private String createUserId;
|
||||
@ExcelProperty(value = "申请人",order = 7)
|
||||
@ExcelProperty(value = "申请人",order = 5)
|
||||
@ApiModelProperty("申请人名称")
|
||||
private String createUserName;
|
||||
@ExcelProperty(value = "申请人手机号",order =8)
|
||||
@ExcelProperty(value = "申请人手机号",order =6)
|
||||
@ApiModelProperty("申请人手机号")
|
||||
private String createUserMobile;
|
||||
@ExcelProperty(value = "申请时间",order = 9)
|
||||
@ExcelProperty(value = "申请时间",order = 7)
|
||||
private String createTimeStr;
|
||||
@ApiModelProperty("申请时间")
|
||||
private Date createTime;
|
||||
@ExcelProperty(value = "审核状态",order =10)
|
||||
@ExcelProperty(value = "审核状态",order =8)
|
||||
private String auditStatusName;
|
||||
@ApiModelProperty("审核状态:0-审批中,1-审核通过,2-审核不通过")
|
||||
private Integer auditStatus;
|
||||
@ExcelProperty(value = "所属大区",order = 4)
|
||||
@ApiModelProperty("所属大区")
|
||||
private String regionName;
|
||||
private Long regionId;
|
||||
private String investmentManagerId;
|
||||
@ExcelProperty(value = " 督导",order = 5)
|
||||
@ApiModelProperty("督导")
|
||||
private String investmentManagerName;
|
||||
|
||||
|
||||
@@ -131,16 +131,16 @@ public class PreFryQualificationApplyServiceImpl implements PreFryQualificationA
|
||||
public PageInfo<ApplyManagementDTO> queryApplyManagementList(ApplyManagementQueryDTO query) {
|
||||
PageHelper.startPage(query.getPageNum(), query.getPageSize());
|
||||
List<ApplyManagementDTO> applyManagementDTOS = preFryQualificationApplyDAO.selectApplyManagementList(query);
|
||||
if (CollectionUtils.isNotEmpty(applyManagementDTOS)){
|
||||
Set<String> userIds = applyManagementDTOS.stream().map(ApplyManagementDTO::getInvestmentManagerId).collect(Collectors.toSet());
|
||||
Map<String, String> userNameMap = enterpriseUserDAO.getUserNameMap(new ArrayList<>(userIds));
|
||||
Set<Long> regionIds = applyManagementDTOS.stream().map(ApplyManagementDTO::getRegionId).collect(Collectors.toSet());
|
||||
Map<Long, String> regionNameMap = regionDao.getRegionNameMap(new ArrayList<>(regionIds));
|
||||
for (ApplyManagementDTO applyManagementDTO:applyManagementDTOS){
|
||||
applyManagementDTO.setInvestmentManagerName(userNameMap.getOrDefault(applyManagementDTO.getInvestmentManagerId(), ""));
|
||||
applyManagementDTO.setRegionName(regionNameMap.getOrDefault(applyManagementDTO.getRegionId(), ""));
|
||||
}
|
||||
}
|
||||
// if (CollectionUtils.isNotEmpty(applyManagementDTOS)){
|
||||
// Set<String> userIds = applyManagementDTOS.stream().map(ApplyManagementDTO::getInvestmentManagerId).collect(Collectors.toSet());
|
||||
// Map<String, String> userNameMap = enterpriseUserDAO.getUserNameMap(new ArrayList<>(userIds));
|
||||
// Set<Long> regionIds = applyManagementDTOS.stream().map(ApplyManagementDTO::getRegionId).collect(Collectors.toSet());
|
||||
// Map<Long, String> regionNameMap = regionDao.getRegionNameMap(new ArrayList<>(regionIds));
|
||||
// for (ApplyManagementDTO applyManagementDTO:applyManagementDTOS){
|
||||
// applyManagementDTO.setInvestmentManagerName(userNameMap.getOrDefault(applyManagementDTO.getInvestmentManagerId(), ""));
|
||||
// applyManagementDTO.setRegionName(regionNameMap.getOrDefault(applyManagementDTO.getRegionId(), ""));
|
||||
// }
|
||||
// }
|
||||
return new PageInfo<>(applyManagementDTOS);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user