Commit 048bc5f4 authored by hongguangwu's avatar hongguangwu

暂时不限制

parent 1a045d4c
......@@ -41,6 +41,7 @@ import com.yifu.cloud.plus.v1.yifu.social.constants.SocialConstants;
import com.yifu.cloud.plus.v1.yifu.social.entity.*;
import com.yifu.cloud.plus.v1.yifu.social.mapper.TSocialFundInfoMapper;
import com.yifu.cloud.plus.v1.yifu.social.service.*;
import com.yifu.cloud.plus.v1.yifu.social.util.ServiceUtil;
import com.yifu.cloud.plus.v1.yifu.social.vo.*;
import lombok.RequiredArgsConstructor;
import lombok.extern.log4j.Log4j2;
......@@ -357,6 +358,10 @@ public class TSocialFundInfoServiceImpl extends ServiceImpl<TSocialFundInfoMappe
errorMessageList.add(new ErrorMessage(i, "未找到公积金基数配置!"));
continue;
}
/*if (!ServiceUtil.checkFundPercentByList(fundSetInfo.getFundProList(), history)) {
errorMessageList.add(new ErrorMessage(i, "无对应公积金比例,请查验公积金户+缴纳地+缴纳月份的公积金比例配置!"));
continue;
}*/
history.setUnitFundMoney(Common.formatMoneyForFund(BigDecimalUtils.safeMultiply(history.getUnitFundBase()
, history.getUnitFundProp(), CommonConstants.ONE_OF_PERCENT), fundSetInfo.getFundPayPoint()));
history.setPersonalFundMoney(Common.formatMoneyForFund(BigDecimalUtils.safeMultiply(history.getPersonalFundBase()
......
......@@ -4,11 +4,14 @@ import com.yifu.cloud.plus.v1.yifu.common.core.constant.CommonConstants;
import com.yifu.cloud.plus.v1.yifu.common.core.exception.CheckedException;
import com.yifu.cloud.plus.v1.yifu.common.core.util.Common;
import com.yifu.cloud.plus.v1.yifu.common.core.util.DateUtil;
import com.yifu.cloud.plus.v1.yifu.social.entity.SysPayProportion;
import com.yifu.cloud.plus.v1.yifu.social.entity.TSocialFundHistory;
import lombok.extern.slf4j.Slf4j;
import java.math.BigDecimal;
import java.time.LocalDateTime;
import java.util.Date;
import java.util.List;
/**
* 公用方法提取
......@@ -127,4 +130,29 @@ public class ServiceUtil {
}
return string;
}
/**
* 验证公积金 比例 是否符合公积金基数配置
* @Author fxj
* @Date 2019-09-29
* @param lst
* @return
**/
public static boolean checkFundPercentByList(List<SysPayProportion> lst, TSocialFundHistory infoVo){
if (Common.isEmpty(lst)){
return false;
}
if (null == infoVo || null == infoVo.getUnitFundProp()){
return false;
}
if (Common.isNotNull(lst)){
for (SysPayProportion t:lst){
if (infoVo.getUnitFundProp().compareTo(BigDecimal.valueOf(t.getCompanyPro())) == CommonConstants.ZERO_INT
&& infoVo.getPersonalFundProp().compareTo(BigDecimal.valueOf(t.getPersonalPro())) == CommonConstants.ZERO_INT){
return true;
}
}
}
return false;
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment