## Feat - 3个月前的数据不可见&姓名编号脱敏
This commit is contained in:
parent
6e33f76fdf
commit
3cac1a359f
|
@ -2,6 +2,8 @@ package com.hzs.member.marketnews.controller.api;
|
||||||
|
|
||||||
import cn.hutool.core.collection.CollectionUtil;
|
import cn.hutool.core.collection.CollectionUtil;
|
||||||
import cn.hutool.core.date.DateUtil;
|
import cn.hutool.core.date.DateUtil;
|
||||||
|
import cn.hutool.core.util.DesensitizedUtil;
|
||||||
|
import cn.hutool.core.util.StrUtil;
|
||||||
import com.hzs.common.core.constant.CountryConstants;
|
import com.hzs.common.core.constant.CountryConstants;
|
||||||
import com.hzs.common.core.constant.EnumsPrefixConstants;
|
import com.hzs.common.core.constant.EnumsPrefixConstants;
|
||||||
import com.hzs.common.core.domain.R;
|
import com.hzs.common.core.domain.R;
|
||||||
|
@ -38,9 +40,7 @@ import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
import org.springframework.web.bind.annotation.RestController;
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
|
||||||
import java.math.BigDecimal;
|
import java.math.BigDecimal;
|
||||||
import java.util.List;
|
import java.util.*;
|
||||||
import java.util.Map;
|
|
||||||
import java.util.Objects;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @Description: 市场动态部分接口
|
* @Description: 市场动态部分接口
|
||||||
|
@ -122,6 +122,9 @@ public class MarketNewsController extends BaseController {
|
||||||
marketNewsParam.setEndCreationTime(DateUtils.getEndTime(marketNewsParam.getEndCreationTime()));
|
marketNewsParam.setEndCreationTime(DateUtils.getEndTime(marketNewsParam.getEndCreationTime()));
|
||||||
}
|
}
|
||||||
startPage();
|
startPage();
|
||||||
|
// 2025年6月26日 强制3个月之前的数据不可见
|
||||||
|
Date endDate = DateUtils.addDate(new Date(), -90);
|
||||||
|
marketNewsParam.setStartCreationTime(endDate);
|
||||||
List<UserInvestmentVo> list = iCuMemberService.selectRegList(marketNewsParam);
|
List<UserInvestmentVo> list = iCuMemberService.selectRegList(marketNewsParam);
|
||||||
for (UserInvestmentVo userInvestmentVo : list) {
|
for (UserInvestmentVo userInvestmentVo : list) {
|
||||||
if (userInvestmentVo.getPkPlaceParent() != null && userInvestmentVo.getPkParent() != null) {
|
if (userInvestmentVo.getPkPlaceParent() != null && userInvestmentVo.getPkParent() != null) {
|
||||||
|
@ -155,9 +158,24 @@ public class MarketNewsController extends BaseController {
|
||||||
userInvestmentVo.setParentName(CommonUtil.getMemberName(userInvestmentVo.getParentPkVertex(), userInvestmentVo.getParentName(), userInvestmentVo.getParentNickName()));
|
userInvestmentVo.setParentName(CommonUtil.getMemberName(userInvestmentVo.getParentPkVertex(), userInvestmentVo.getParentName(), userInvestmentVo.getParentNickName()));
|
||||||
userInvestmentVo.setPlaceParentCode(CommonUtil.getMemberCode(userInvestmentVo.getPlaceParentCode(), userInvestmentVo.getPlaceServiceCode()));
|
userInvestmentVo.setPlaceParentCode(CommonUtil.getMemberCode(userInvestmentVo.getPlaceParentCode(), userInvestmentVo.getPlaceServiceCode()));
|
||||||
userInvestmentVo.setPlaceParentName(CommonUtil.getMemberName(userInvestmentVo.getPlacePkVertex(), userInvestmentVo.getPlaceParentName(), userInvestmentVo.getPlaceNickName()));
|
userInvestmentVo.setPlaceParentName(CommonUtil.getMemberName(userInvestmentVo.getPlacePkVertex(), userInvestmentVo.getPlaceParentName(), userInvestmentVo.getPlaceNickName()));
|
||||||
|
|
||||||
|
// 2025年6月26日 脱敏
|
||||||
|
userInvestmentVo.setMemberName(desensitizationName(userInvestmentVo.getMemberName()));
|
||||||
|
userInvestmentVo.setParentName(desensitizationName(userInvestmentVo.getParentName()));
|
||||||
|
userInvestmentVo.setMemberCode(desensitizationCode(userInvestmentVo.getMemberCode()));
|
||||||
|
userInvestmentVo.setParentCode(desensitizationCode(userInvestmentVo.getParentCode()));
|
||||||
|
userInvestmentVo.setPlaceParentName(desensitizationName(userInvestmentVo.getPlaceParentName()));
|
||||||
|
userInvestmentVo.setPlaceParentCode(desensitizationCode(userInvestmentVo.getPlaceParentCode()));
|
||||||
|
|
||||||
}
|
}
|
||||||
return getDataTable(list);
|
return getDataTable(list);
|
||||||
}
|
}
|
||||||
|
private String desensitizationName(String name){
|
||||||
|
return StrUtil.hide(name, 1, name.length() - 1);
|
||||||
|
}
|
||||||
|
private String desensitizationCode(String code){
|
||||||
|
return StrUtil.hide(code, 4, code.length() - 3);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 海粉列表
|
* 海粉列表
|
||||||
|
|
Loading…
Reference in New Issue