路维光电支持跨义务人取社保

This commit is contained in:
Harryxzy 2025-07-24 10:10:20 +08:00
parent e225965e33
commit c628c1be85
2 changed files with 355 additions and 336 deletions

View File

@ -34,6 +34,7 @@ import lombok.experimental.Accessors;
import org.apache.commons.lang3.StringUtils;
import org.apache.commons.lang3.math.NumberUtils;
import weaver.general.Util;
import weaver.wechat.util.Utils;
import java.lang.reflect.Field;
import java.math.BigDecimal;
@ -505,9 +506,12 @@ public class CalculateFormulaVarBO {
// 社保福利数据
Map<String, List<FormulaVarValue>> tempMap = new HashMap<>();
welfareData.forEach(map -> {
String key = map.getOrDefault("employeeId", StringUtils.EMPTY) + "_" + map.getOrDefault("taxAgentId", StringUtils.EMPTY);
// String key = map.getOrDefault("employeeId", StringUtils.EMPTY) + "_" + map.getOrDefault("taxAgentId", StringUtils.EMPTY);
String taxAgentId = Utils.null2String(map.getOrDefault("taxAgentId", StringUtils.EMPTY));
String taxAgentIdKey = taxAgentId + "_";
String key = Utils.null2String(map.getOrDefault("employeeId", StringUtils.EMPTY));
List<FormulaVarValue> formulaVarValues = tempMap.computeIfAbsent(key, k -> Lists.newArrayList());
formulaVarValues.addAll(fieldNames.stream().map(fieldName -> {
formulaVarValues.addAll(fieldNames.stream().filter(fieldName -> fieldName.startsWith(taxAgentIdKey)).map(fieldName -> {
String fieldId = SalaryFormulaReferenceEnum.WELFARE.getValue()
+ SalaryFormulaFieldConstant.FIELD_ID_SEPARATOR
+ fieldName;
@ -518,7 +522,8 @@ public class CalculateFormulaVarBO {
for (SalaryAcctEmployeePO salaryAcctEmployeePO : salaryAcctCalculateBO.getSalaryAcctEmployeePOS()) {
List<FormulaVarValue> formulaVarValues = resultMap.computeIfAbsent(salaryAcctEmployeePO.getEmployeeId() + "_" + salaryAcctEmployeePO.getTaxAgentId(),
k -> Lists.newArrayList());
formulaVarValues.addAll(tempMap.getOrDefault(salaryAcctEmployeePO.getEmployeeId() + "_" + salaryAcctEmployeePO.getTaxAgentId(), Collections.emptyList()));
// formulaVarValues.addAll(tempMap.getOrDefault(salaryAcctEmployeePO.getEmployeeId() + "_" + salaryAcctEmployeePO.getTaxAgentId(), Collections.emptyList()));
formulaVarValues.addAll(tempMap.getOrDefault(salaryAcctEmployeePO.getEmployeeId().toString(), Collections.emptyList()));
}
}

View File

@ -904,257 +904,263 @@ public class SIAccountServiceImpl extends Service implements SIAccountService {
}
@Override
public List<Map<String, Object>> welfareData(String billMonth, List<Long> employeeIds, Long taxAgentId) {
InsuranceAccountBatchPO insuranceAccountBatchPO = getInsuranceAccountBatchMapper().getByBillMonth(billMonth, taxAgentId);
insuranceAccountBatchPO = encryptUtil.decrypt(insuranceAccountBatchPO, InsuranceAccountBatchPO.class);
if (insuranceAccountBatchPO == null || Objects.equals(BillStatusEnum.NOT_ARCHIVED.getValue(), insuranceAccountBatchPO.getBillStatus())) {
return Lists.newArrayList();
}
public List<Map<String, Object>> welfareData(String billMonth, List<Long> employeeIds, Long acctTaxAgentId) {
List<TaxAgentPO> taxAgentPOS = getTaxAgentService(user).listAll();
List<Map<String, Object>> result = new ArrayList<>();
for (TaxAgentPO taxAgent : taxAgentPOS) {
Long taxAgentId = taxAgent.getId();
String taxAgentIdKey = taxAgentId + "_";
//20230707增加福利核算明细中的缴纳状态+合计的数据项
InsuranceAccountBatchPO insuranceAccountBatchPO = getInsuranceAccountBatchMapper().getByBillMonth(billMonth, taxAgentId);
insuranceAccountBatchPO = encryptUtil.decrypt(insuranceAccountBatchPO, InsuranceAccountBatchPO.class);
if (insuranceAccountBatchPO == null || Objects.equals(BillStatusEnum.NOT_ARCHIVED.getValue(), insuranceAccountBatchPO.getBillStatus())) {
continue;
}
//20230707增加福利核算明细中的缴纳状态+合计的数据项
// List<InsuranceAccountDetailPO> insuranceAccountDetailPOS = getInsuranceAccountDetailMapper().queryList(billMonth, taxAgentId, employeeIds);
List<InsuranceAccountDetailPO> insuranceAccountDetailPOS = new ArrayList<>();
List<List<Long>> empIdsPart = Lists.partition((List<Long>) employeeIds, 500);
for (List<Long> part : empIdsPart) {
insuranceAccountDetailPOS.addAll(
getInsuranceAccountDetailMapper().queryList(billMonth, taxAgentId, part));
List<InsuranceAccountDetailPO> insuranceAccountDetailPOS = new ArrayList<>();
List<List<Long>> empIdsPart = Lists.partition((List<Long>) employeeIds, 500);
for (List<Long> part : empIdsPart) {
insuranceAccountDetailPOS.addAll(
getInsuranceAccountDetailMapper().queryList(billMonth, taxAgentId, part));
}
//退差数据不参与薪资核算
insuranceAccountDetailPOS = insuranceAccountDetailPOS.stream()
.filter(f -> f.getPaymentStatus().equals(PaymentStatusEnum.COMMON.getValue())
|| f.getPaymentStatus().equals(PaymentStatusEnum.REPAIR.getValue())
|| f.getPaymentStatus().equals(PaymentStatusEnum.BALANCE.getValue()) )
.collect(Collectors.toList());
List<InsuranceAccountDetailPO> list = buildNewInsuranceDetailPOS(insuranceAccountDetailPOS);
Map<String, InsuranceAccountDetailPO> siAcctResultWithEmpAndPayStatus = insuranceAccountDetailPOS.stream()
.collect(Collectors.toMap(po -> po.getEmployeeId() + "_" + po.getPaymentStatus(), a -> a, (a, b) -> a));
list.stream().forEach(item -> {
Map<String, Object> record = new HashMap<>();
record.put("employeeId", item.getEmployeeId());
record.put("taxAgentId", taxAgentId);
if (StringUtils.isNotEmpty(item.getSocialPerJson())) {
Map<String, Object> socialJson = JSON.parseObject(item.getSocialPerJson(), new HashMap<String, Object>().getClass());
socialJson.forEach((k, v) -> {
record.put(taxAgentIdKey + k + "socialPer", v);
});
}
if (StringUtils.isNotEmpty(item.getSocialComJson())) {
Map<String, Object> socialJson = JSON.parseObject(item.getSocialComJson(), new HashMap<String, Object>().getClass());
socialJson.forEach((k, v) -> {
record.put(taxAgentIdKey + k + "socialCom", v);
});
}
record.put(taxAgentIdKey + "socialPerSum", item.getSocialPerSum());
record.put(taxAgentIdKey + "socialComSum", item.getSocialComSum());
if (StringUtils.isNotEmpty(item.getFundPerJson())) {
Map<String, Object> fundPerJson = JSON.parseObject(item.getFundPerJson(), new HashMap<String, Object>().getClass());
fundPerJson.forEach((k, v) -> {
record.put(taxAgentIdKey + k + "fundPer", v);
});
}
if (StringUtils.isNotEmpty(item.getFundComJson())) {
Map<String, Object> fundPerJson = JSON.parseObject(item.getFundComJson(), new HashMap<String, Object>().getClass());
fundPerJson.forEach((k, v) -> {
record.put(taxAgentIdKey + k + "fundCom", v);
});
}
record.put(taxAgentIdKey + "fundPerSum", item.getFundPerSum());
record.put(taxAgentIdKey + "fundComSum", item.getFundComSum());
if (StringUtils.isNotEmpty(item.getOtherPerJson())) {
Map<String, Object> fundPerJson = JSON.parseObject(item.getOtherPerJson(), new HashMap<String, Object>().getClass());
fundPerJson.forEach((k, v) -> {
record.put(taxAgentIdKey + k + "otherPer", v);
});
}
if (StringUtils.isNotEmpty(item.getOtherComJson())) {
Map<String, Object> fundComJson = JSON.parseObject(item.getOtherComJson(), new HashMap<String, Object>().getClass());
if (fundComJson != null) {
}
fundComJson.forEach((k, v) -> {
record.put(taxAgentIdKey + k + "otherCom", v);
});
}
record.put(taxAgentIdKey + "otherPerSum", item.getOtherPerSum());
record.put(taxAgentIdKey + "otherComSum", item.getOtherComSum());
record.put(taxAgentIdKey + "perSum", item.getPerSum());
record.put(taxAgentIdKey + "comSum", item.getComSum());
//20230707增加福利核算明细中的缴纳状态+合计的数据项缴纳状态+福利项的数据项
InsuranceAccountDetailPO commonSiAcct = siAcctResultWithEmpAndPayStatus.get(item.getEmployeeId() + "_" + PaymentStatusEnum.COMMON.getValue());
InsuranceAccountDetailPO repairSiAcct = siAcctResultWithEmpAndPayStatus.get(item.getEmployeeId() + "_" + PaymentStatusEnum.REPAIR.getValue());
InsuranceAccountDetailPO balanceSiAcct = siAcctResultWithEmpAndPayStatus.get(item.getEmployeeId() + "_" + PaymentStatusEnum.BALANCE.getValue());
//取正常缴纳的福利基数信息
if (commonSiAcct != null && StringUtils.isNotEmpty(commonSiAcct.getSocialPaymentBaseString())) {
Map<String, Object> socialBaseJson = JSON.parseObject(commonSiAcct.getSocialPaymentBaseString(), new HashMap<String, Object>().getClass());
socialBaseJson.forEach((k, v) -> {
record.put(taxAgentIdKey + k + "socialBase", v);
});
}
if (commonSiAcct != null && StringUtils.isNotEmpty(commonSiAcct.getFundPaymentBaseString())) {
Map<String, Object> fundBaseJson = JSON.parseObject(commonSiAcct.getFundPaymentBaseString(), new HashMap<String, Object>().getClass());
fundBaseJson.forEach((k, v) -> {
record.put(taxAgentIdKey + k + "fundBase", v);
});
}
if (commonSiAcct != null && StringUtils.isNotEmpty(commonSiAcct.getOtherPaymentBaseString())) {
Map<String, Object> otherBaseJson = JSON.parseObject(commonSiAcct.getOtherPaymentBaseString(), new HashMap<String, Object>().getClass());
otherBaseJson.forEach((k, v) -> {
record.put(taxAgentIdKey + k + "otherBase", v);
});
}
//社保-正常缴纳
if (commonSiAcct != null && StringUtils.isNotEmpty(commonSiAcct.getSocialPerJson())) {
Map<String, Object> socialJson = JSON.parseObject(commonSiAcct.getSocialPerJson(), new HashMap<String, Object>().getClass());
socialJson.forEach((k, v) -> {
record.put(taxAgentIdKey + k + "socialCommonPer", v);
});
}
if (commonSiAcct != null && StringUtils.isNotEmpty(commonSiAcct.getSocialComJson())) {
Map<String, Object> socialJson = JSON.parseObject(commonSiAcct.getSocialComJson(), new HashMap<String, Object>().getClass());
socialJson.forEach((k, v) -> {
record.put(taxAgentIdKey + k + "socialCommonCom", v);
});
}
record.put(taxAgentIdKey + "socialPerCommonSum", commonSiAcct != null ? commonSiAcct.getSocialPerSum() : new BigDecimal("0"));
record.put(taxAgentIdKey + "socialComCommonSum", commonSiAcct != null ? commonSiAcct.getSocialComSum() : new BigDecimal("0"));
//社保-补缴
if (repairSiAcct != null && StringUtils.isNotEmpty(repairSiAcct.getSocialPerJson())) {
Map<String, Object> socialJson = JSON.parseObject(repairSiAcct.getSocialPerJson(), new HashMap<String, Object>().getClass());
socialJson.forEach((k, v) -> {
record.put(taxAgentIdKey + k + "socialRepairPer", v);
});
}
if (repairSiAcct != null && StringUtils.isNotEmpty(repairSiAcct.getSocialComJson())) {
Map<String, Object> socialJson = JSON.parseObject(repairSiAcct.getSocialComJson(), new HashMap<String, Object>().getClass());
socialJson.forEach((k, v) -> {
record.put(taxAgentIdKey + k + "socialRepairCom", v);
});
}
record.put(taxAgentIdKey + "socialPerRepairSum", repairSiAcct != null ? repairSiAcct.getSocialPerSum() : new BigDecimal("0"));
record.put(taxAgentIdKey + "socialComRepairSum", repairSiAcct != null ? repairSiAcct.getSocialComSum() : new BigDecimal("0"));
//社保-补差
if (balanceSiAcct != null && StringUtils.isNotEmpty(balanceSiAcct.getSocialPerJson())) {
Map<String, Object> socialJson = JSON.parseObject(balanceSiAcct.getSocialPerJson(), new HashMap<String, Object>().getClass());
socialJson.forEach((k, v) -> {
record.put(taxAgentIdKey + k + "socialBalancePer", v);
});
}
if (balanceSiAcct != null && StringUtils.isNotEmpty(balanceSiAcct.getSocialComJson())) {
Map<String, Object> socialJson = JSON.parseObject(balanceSiAcct.getSocialComJson(), new HashMap<String, Object>().getClass());
socialJson.forEach((k, v) -> {
record.put(taxAgentIdKey + k + "socialBalanceCom", v);
});
}
record.put(taxAgentIdKey + "socialPerBalanceSum", balanceSiAcct != null ? balanceSiAcct.getSocialPerSum() : new BigDecimal("0"));
record.put(taxAgentIdKey + "socialComBalanceSum", balanceSiAcct != null ? balanceSiAcct.getSocialComSum() : new BigDecimal("0"));
//公积金-正常缴纳
if (commonSiAcct != null && StringUtils.isNotEmpty(commonSiAcct.getFundPerJson())) {
Map<String, Object> socialJson = JSON.parseObject(commonSiAcct.getFundPerJson(), new HashMap<String, Object>().getClass());
socialJson.forEach((k, v) -> {
record.put(taxAgentIdKey + k + "fundCommonPer", v);
});
}
if (commonSiAcct != null && StringUtils.isNotEmpty(commonSiAcct.getFundComJson())) {
Map<String, Object> socialJson = JSON.parseObject(commonSiAcct.getFundComJson(), new HashMap<String, Object>().getClass());
socialJson.forEach((k, v) -> {
record.put(taxAgentIdKey + k + "fundCommonCom", v);
});
}
record.put(taxAgentIdKey + "fundPerCommonSum", commonSiAcct != null ? commonSiAcct.getFundPerSum() : new BigDecimal("0"));
record.put(taxAgentIdKey + "fundComCommonSum", commonSiAcct != null ? commonSiAcct.getFundComSum() : new BigDecimal("0"));
//公积金-补缴
if (repairSiAcct != null && StringUtils.isNotEmpty(repairSiAcct.getFundPerJson())) {
Map<String, Object> fundJson = JSON.parseObject(repairSiAcct.getFundPerJson(), new HashMap<String, Object>().getClass());
fundJson.forEach((k, v) -> {
record.put(taxAgentIdKey + k + "fundRepairPer", v);
});
}
if (repairSiAcct != null && StringUtils.isNotEmpty(repairSiAcct.getFundComJson())) {
Map<String, Object> fundJson = JSON.parseObject(repairSiAcct.getFundComJson(), new HashMap<String, Object>().getClass());
fundJson.forEach((k, v) -> {
record.put(taxAgentIdKey + k + "fundRepairCom", v);
});
}
record.put(taxAgentIdKey + "fundPerRepairSum", repairSiAcct != null ? repairSiAcct.getFundPerSum() : new BigDecimal("0"));
record.put(taxAgentIdKey + "fundComRepairSum", repairSiAcct != null ? repairSiAcct.getFundComSum() : new BigDecimal("0"));
//公积金-补差
if (balanceSiAcct != null && StringUtils.isNotEmpty(balanceSiAcct.getFundPerJson())) {
Map<String, Object> fundJson = JSON.parseObject(balanceSiAcct.getFundPerJson(), new HashMap<String, Object>().getClass());
fundJson.forEach((k, v) -> {
record.put(taxAgentIdKey + k + "fundBalancePer", v);
});
}
if (balanceSiAcct != null && StringUtils.isNotEmpty(balanceSiAcct.getFundComJson())) {
Map<String, Object> fundJson = JSON.parseObject(balanceSiAcct.getFundComJson(), new HashMap<String, Object>().getClass());
fundJson.forEach((k, v) -> {
record.put(taxAgentIdKey + k + "fundBalanceCom", v);
});
}
record.put(taxAgentIdKey + "fundPerBalanceSum", balanceSiAcct != null ? balanceSiAcct.getFundPerSum() : new BigDecimal("0"));
record.put(taxAgentIdKey + "fundComBalanceSum", balanceSiAcct != null ? balanceSiAcct.getFundComSum() : new BigDecimal("0"));
//其他福利-正常缴纳
if (commonSiAcct != null && StringUtils.isNotEmpty(commonSiAcct.getOtherPerJson())) {
Map<String, Object> otherJson = JSON.parseObject(commonSiAcct.getOtherPerJson(), new HashMap<String, Object>().getClass());
otherJson.forEach((k, v) -> {
record.put(taxAgentIdKey + k + "otherCommonPer", v);
});
}
if (commonSiAcct != null && StringUtils.isNotEmpty(commonSiAcct.getOtherComJson())) {
Map<String, Object> otherJson = JSON.parseObject(commonSiAcct.getOtherComJson(), new HashMap<String, Object>().getClass());
otherJson.forEach((k, v) -> {
record.put(taxAgentIdKey + k + "otherCommonCom", v);
});
}
record.put(taxAgentIdKey + "otherPerCommonSum", commonSiAcct != null ? commonSiAcct.getOtherPerSum() : new BigDecimal("0"));
record.put(taxAgentIdKey + "otherComCommonSum", commonSiAcct != null ? commonSiAcct.getOtherComSum() : new BigDecimal("0"));
//其他福利-补缴
if (repairSiAcct != null && StringUtils.isNotEmpty(repairSiAcct.getOtherPerJson())) {
Map<String, Object> otherJson = JSON.parseObject(repairSiAcct.getOtherPerJson(), new HashMap<String, Object>().getClass());
otherJson.forEach((k, v) -> {
record.put(taxAgentIdKey + k + "otherRepairPer", v);
});
}
if (repairSiAcct != null && StringUtils.isNotEmpty(repairSiAcct.getOtherComJson())) {
Map<String, Object> otherJson = JSON.parseObject(repairSiAcct.getOtherComJson(), new HashMap<String, Object>().getClass());
otherJson.forEach((k, v) -> {
record.put(taxAgentIdKey + k + "otherRepairCom", v);
});
}
record.put(taxAgentIdKey + "otherPerRepairSum", repairSiAcct != null ? repairSiAcct.getOtherPerSum() : new BigDecimal("0"));
record.put(taxAgentIdKey + "otherComRepairSum", repairSiAcct != null ? repairSiAcct.getOtherComSum() : new BigDecimal("0"));
//其他福利-补差
if (balanceSiAcct != null && StringUtils.isNotEmpty(balanceSiAcct.getOtherPerJson())) {
Map<String, Object> otherJson = JSON.parseObject(balanceSiAcct.getOtherPerJson(), new HashMap<String, Object>().getClass());
otherJson.forEach((k, v) -> {
record.put(taxAgentIdKey + k + "otherBalancePer", v);
});
}
if (balanceSiAcct != null && StringUtils.isNotEmpty(balanceSiAcct.getOtherComJson())) {
Map<String, Object> otherJson = JSON.parseObject(balanceSiAcct.getOtherComJson(), new HashMap<String, Object>().getClass());
otherJson.forEach((k, v) -> {
record.put(taxAgentIdKey + k + "otherBalanceCom", v);
});
}
record.put(taxAgentIdKey + "otherPerBalanceSum", balanceSiAcct != null ? balanceSiAcct.getOtherPerSum() : new BigDecimal("0"));
record.put(taxAgentIdKey + "otherComBalanceSum", balanceSiAcct != null ? balanceSiAcct.getOtherComSum() : new BigDecimal("0"));
record.put(taxAgentIdKey + "perCommonSum", commonSiAcct != null ? commonSiAcct.getPerSum() : new BigDecimal("0"));
record.put(taxAgentIdKey + "comCommonSum", commonSiAcct != null ? commonSiAcct.getComSum() : new BigDecimal("0"));
record.put(taxAgentIdKey + "perRepairSum", repairSiAcct != null ? repairSiAcct.getPerSum() : new BigDecimal("0"));
record.put(taxAgentIdKey + "comRepairSum", repairSiAcct != null ? repairSiAcct.getComSum() : new BigDecimal("0"));
record.put(taxAgentIdKey + "perBalanceSum", balanceSiAcct != null ? balanceSiAcct.getPerSum() : new BigDecimal("0"));
record.put(taxAgentIdKey + "comBalanceSum", balanceSiAcct != null ? balanceSiAcct.getComSum() : new BigDecimal("0"));
result.add(record);
});
}
//退差数据不参与薪资核算
insuranceAccountDetailPOS = insuranceAccountDetailPOS.stream()
.filter(f -> f.getPaymentStatus().equals(PaymentStatusEnum.COMMON.getValue())
|| f.getPaymentStatus().equals(PaymentStatusEnum.REPAIR.getValue())
|| f.getPaymentStatus().equals(PaymentStatusEnum.BALANCE.getValue()) )
.collect(Collectors.toList());
List<InsuranceAccountDetailPO> list = buildNewInsuranceDetailPOS(insuranceAccountDetailPOS);
Map<String, InsuranceAccountDetailPO> siAcctResultWithEmpAndPayStatus = insuranceAccountDetailPOS.stream()
.collect(Collectors.toMap(po -> po.getEmployeeId() + "_" + po.getPaymentStatus(), a -> a, (a, b) -> a));
List<Map<String, Object>> result = new ArrayList<>();
list.stream().forEach(item -> {
Map<String, Object> record = new HashMap<>();
record.put("employeeId", item.getEmployeeId());
record.put("taxAgentId", taxAgentId);
if (StringUtils.isNotEmpty(item.getSocialPerJson())) {
Map<String, Object> socialJson = JSON.parseObject(item.getSocialPerJson(), new HashMap<String, Object>().getClass());
socialJson.forEach((k, v) -> {
record.put(k + "socialPer", v);
});
}
if (StringUtils.isNotEmpty(item.getSocialComJson())) {
Map<String, Object> socialJson = JSON.parseObject(item.getSocialComJson(), new HashMap<String, Object>().getClass());
socialJson.forEach((k, v) -> {
record.put(k + "socialCom", v);
});
}
record.put("socialPerSum", item.getSocialPerSum());
record.put("socialComSum", item.getSocialComSum());
if (StringUtils.isNotEmpty(item.getFundPerJson())) {
Map<String, Object> fundPerJson = JSON.parseObject(item.getFundPerJson(), new HashMap<String, Object>().getClass());
fundPerJson.forEach((k, v) -> {
record.put(k + "fundPer", v);
});
}
if (StringUtils.isNotEmpty(item.getFundComJson())) {
Map<String, Object> fundPerJson = JSON.parseObject(item.getFundComJson(), new HashMap<String, Object>().getClass());
fundPerJson.forEach((k, v) -> {
record.put(k + "fundCom", v);
});
}
record.put("fundPerSum", item.getFundPerSum());
record.put("fundComSum", item.getFundComSum());
if (StringUtils.isNotEmpty(item.getOtherPerJson())) {
Map<String, Object> fundPerJson = JSON.parseObject(item.getOtherPerJson(), new HashMap<String, Object>().getClass());
fundPerJson.forEach((k, v) -> {
record.put(k + "otherPer", v);
});
}
if (StringUtils.isNotEmpty(item.getOtherComJson())) {
Map<String, Object> fundComJson = JSON.parseObject(item.getOtherComJson(), new HashMap<String, Object>().getClass());
if (fundComJson != null) {
}
fundComJson.forEach((k, v) -> {
record.put(k + "otherCom", v);
});
}
record.put("otherPerSum", item.getOtherPerSum());
record.put("otherComSum", item.getOtherComSum());
record.put("perSum", item.getPerSum());
record.put("comSum", item.getComSum());
//20230707增加福利核算明细中的缴纳状态+合计的数据项缴纳状态+福利项的数据项
InsuranceAccountDetailPO commonSiAcct = siAcctResultWithEmpAndPayStatus.get(item.getEmployeeId() + "_" + PaymentStatusEnum.COMMON.getValue());
InsuranceAccountDetailPO repairSiAcct = siAcctResultWithEmpAndPayStatus.get(item.getEmployeeId() + "_" + PaymentStatusEnum.REPAIR.getValue());
InsuranceAccountDetailPO balanceSiAcct = siAcctResultWithEmpAndPayStatus.get(item.getEmployeeId() + "_" + PaymentStatusEnum.BALANCE.getValue());
//取正常缴纳的福利基数信息
if (commonSiAcct != null && StringUtils.isNotEmpty(commonSiAcct.getSocialPaymentBaseString())) {
Map<String, Object> socialBaseJson = JSON.parseObject(commonSiAcct.getSocialPaymentBaseString(), new HashMap<String, Object>().getClass());
socialBaseJson.forEach((k, v) -> {
record.put(k + "socialBase", v);
});
}
if (commonSiAcct != null && StringUtils.isNotEmpty(commonSiAcct.getFundPaymentBaseString())) {
Map<String, Object> fundBaseJson = JSON.parseObject(commonSiAcct.getFundPaymentBaseString(), new HashMap<String, Object>().getClass());
fundBaseJson.forEach((k, v) -> {
record.put(k + "fundBase", v);
});
}
if (commonSiAcct != null && StringUtils.isNotEmpty(commonSiAcct.getOtherPaymentBaseString())) {
Map<String, Object> otherBaseJson = JSON.parseObject(commonSiAcct.getOtherPaymentBaseString(), new HashMap<String, Object>().getClass());
otherBaseJson.forEach((k, v) -> {
record.put(k + "otherBase", v);
});
}
//社保-正常缴纳
if (commonSiAcct != null && StringUtils.isNotEmpty(commonSiAcct.getSocialPerJson())) {
Map<String, Object> socialJson = JSON.parseObject(commonSiAcct.getSocialPerJson(), new HashMap<String, Object>().getClass());
socialJson.forEach((k, v) -> {
record.put(k + "socialCommonPer", v);
});
}
if (commonSiAcct != null && StringUtils.isNotEmpty(commonSiAcct.getSocialComJson())) {
Map<String, Object> socialJson = JSON.parseObject(commonSiAcct.getSocialComJson(), new HashMap<String, Object>().getClass());
socialJson.forEach((k, v) -> {
record.put(k + "socialCommonCom", v);
});
}
record.put("socialPerCommonSum", commonSiAcct != null ? commonSiAcct.getSocialPerSum() : new BigDecimal("0"));
record.put("socialComCommonSum", commonSiAcct != null ? commonSiAcct.getSocialComSum() : new BigDecimal("0"));
//社保-补缴
if (repairSiAcct != null && StringUtils.isNotEmpty(repairSiAcct.getSocialPerJson())) {
Map<String, Object> socialJson = JSON.parseObject(repairSiAcct.getSocialPerJson(), new HashMap<String, Object>().getClass());
socialJson.forEach((k, v) -> {
record.put(k + "socialRepairPer", v);
});
}
if (repairSiAcct != null && StringUtils.isNotEmpty(repairSiAcct.getSocialComJson())) {
Map<String, Object> socialJson = JSON.parseObject(repairSiAcct.getSocialComJson(), new HashMap<String, Object>().getClass());
socialJson.forEach((k, v) -> {
record.put(k + "socialRepairCom", v);
});
}
record.put("socialPerRepairSum", repairSiAcct != null ? repairSiAcct.getSocialPerSum() : new BigDecimal("0"));
record.put("socialComRepairSum", repairSiAcct != null ? repairSiAcct.getSocialComSum() : new BigDecimal("0"));
//社保-补差
if (balanceSiAcct != null && StringUtils.isNotEmpty(balanceSiAcct.getSocialPerJson())) {
Map<String, Object> socialJson = JSON.parseObject(balanceSiAcct.getSocialPerJson(), new HashMap<String, Object>().getClass());
socialJson.forEach((k, v) -> {
record.put(k + "socialBalancePer", v);
});
}
if (balanceSiAcct != null && StringUtils.isNotEmpty(balanceSiAcct.getSocialComJson())) {
Map<String, Object> socialJson = JSON.parseObject(balanceSiAcct.getSocialComJson(), new HashMap<String, Object>().getClass());
socialJson.forEach((k, v) -> {
record.put(k + "socialBalanceCom", v);
});
}
record.put("socialPerBalanceSum", balanceSiAcct != null ? balanceSiAcct.getSocialPerSum() : new BigDecimal("0"));
record.put("socialComBalanceSum", balanceSiAcct != null ? balanceSiAcct.getSocialComSum() : new BigDecimal("0"));
//公积金-正常缴纳
if (commonSiAcct != null && StringUtils.isNotEmpty(commonSiAcct.getFundPerJson())) {
Map<String, Object> socialJson = JSON.parseObject(commonSiAcct.getFundPerJson(), new HashMap<String, Object>().getClass());
socialJson.forEach((k, v) -> {
record.put(k + "fundCommonPer", v);
});
}
if (commonSiAcct != null && StringUtils.isNotEmpty(commonSiAcct.getFundComJson())) {
Map<String, Object> socialJson = JSON.parseObject(commonSiAcct.getFundComJson(), new HashMap<String, Object>().getClass());
socialJson.forEach((k, v) -> {
record.put(k + "fundCommonCom", v);
});
}
record.put("fundPerCommonSum", commonSiAcct != null ? commonSiAcct.getFundPerSum() : new BigDecimal("0"));
record.put("fundComCommonSum", commonSiAcct != null ? commonSiAcct.getFundComSum() : new BigDecimal("0"));
//公积金-补缴
if (repairSiAcct != null && StringUtils.isNotEmpty(repairSiAcct.getFundPerJson())) {
Map<String, Object> fundJson = JSON.parseObject(repairSiAcct.getFundPerJson(), new HashMap<String, Object>().getClass());
fundJson.forEach((k, v) -> {
record.put(k + "fundRepairPer", v);
});
}
if (repairSiAcct != null && StringUtils.isNotEmpty(repairSiAcct.getFundComJson())) {
Map<String, Object> fundJson = JSON.parseObject(repairSiAcct.getFundComJson(), new HashMap<String, Object>().getClass());
fundJson.forEach((k, v) -> {
record.put(k + "fundRepairCom", v);
});
}
record.put("fundPerRepairSum", repairSiAcct != null ? repairSiAcct.getFundPerSum() : new BigDecimal("0"));
record.put("fundComRepairSum", repairSiAcct != null ? repairSiAcct.getFundComSum() : new BigDecimal("0"));
//公积金-补差
if (balanceSiAcct != null && StringUtils.isNotEmpty(balanceSiAcct.getFundPerJson())) {
Map<String, Object> fundJson = JSON.parseObject(balanceSiAcct.getFundPerJson(), new HashMap<String, Object>().getClass());
fundJson.forEach((k, v) -> {
record.put(k + "fundBalancePer", v);
});
}
if (balanceSiAcct != null && StringUtils.isNotEmpty(balanceSiAcct.getFundComJson())) {
Map<String, Object> fundJson = JSON.parseObject(balanceSiAcct.getFundComJson(), new HashMap<String, Object>().getClass());
fundJson.forEach((k, v) -> {
record.put(k + "fundBalanceCom", v);
});
}
record.put("fundPerBalanceSum", balanceSiAcct != null ? balanceSiAcct.getFundPerSum() : new BigDecimal("0"));
record.put("fundComBalanceSum", balanceSiAcct != null ? balanceSiAcct.getFundComSum() : new BigDecimal("0"));
//其他福利-正常缴纳
if (commonSiAcct != null && StringUtils.isNotEmpty(commonSiAcct.getOtherPerJson())) {
Map<String, Object> otherJson = JSON.parseObject(commonSiAcct.getOtherPerJson(), new HashMap<String, Object>().getClass());
otherJson.forEach((k, v) -> {
record.put(k + "otherCommonPer", v);
});
}
if (commonSiAcct != null && StringUtils.isNotEmpty(commonSiAcct.getOtherComJson())) {
Map<String, Object> otherJson = JSON.parseObject(commonSiAcct.getOtherComJson(), new HashMap<String, Object>().getClass());
otherJson.forEach((k, v) -> {
record.put(k + "otherCommonCom", v);
});
}
record.put("otherPerCommonSum", commonSiAcct != null ? commonSiAcct.getOtherPerSum() : new BigDecimal("0"));
record.put("otherComCommonSum", commonSiAcct != null ? commonSiAcct.getOtherComSum() : new BigDecimal("0"));
//其他福利-补缴
if (repairSiAcct != null && StringUtils.isNotEmpty(repairSiAcct.getOtherPerJson())) {
Map<String, Object> otherJson = JSON.parseObject(repairSiAcct.getOtherPerJson(), new HashMap<String, Object>().getClass());
otherJson.forEach((k, v) -> {
record.put(k + "otherRepairPer", v);
});
}
if (repairSiAcct != null && StringUtils.isNotEmpty(repairSiAcct.getOtherComJson())) {
Map<String, Object> otherJson = JSON.parseObject(repairSiAcct.getOtherComJson(), new HashMap<String, Object>().getClass());
otherJson.forEach((k, v) -> {
record.put(k + "otherRepairCom", v);
});
}
record.put("otherPerRepairSum", repairSiAcct != null ? repairSiAcct.getOtherPerSum() : new BigDecimal("0"));
record.put("otherComRepairSum", repairSiAcct != null ? repairSiAcct.getOtherComSum() : new BigDecimal("0"));
//其他福利-补差
if (balanceSiAcct != null && StringUtils.isNotEmpty(balanceSiAcct.getOtherPerJson())) {
Map<String, Object> otherJson = JSON.parseObject(balanceSiAcct.getOtherPerJson(), new HashMap<String, Object>().getClass());
otherJson.forEach((k, v) -> {
record.put(k + "otherBalancePer", v);
});
}
if (balanceSiAcct != null && StringUtils.isNotEmpty(balanceSiAcct.getOtherComJson())) {
Map<String, Object> otherJson = JSON.parseObject(balanceSiAcct.getOtherComJson(), new HashMap<String, Object>().getClass());
otherJson.forEach((k, v) -> {
record.put(k + "otherBalanceCom", v);
});
}
record.put("otherPerBalanceSum", balanceSiAcct != null ? balanceSiAcct.getOtherPerSum() : new BigDecimal("0"));
record.put("otherComBalanceSum", balanceSiAcct != null ? balanceSiAcct.getOtherComSum() : new BigDecimal("0"));
record.put("perCommonSum", commonSiAcct != null ? commonSiAcct.getPerSum() : new BigDecimal("0"));
record.put("comCommonSum", commonSiAcct != null ? commonSiAcct.getComSum() : new BigDecimal("0"));
record.put("perRepairSum", repairSiAcct != null ? repairSiAcct.getPerSum() : new BigDecimal("0"));
record.put("comRepairSum", repairSiAcct != null ? repairSiAcct.getComSum() : new BigDecimal("0"));
record.put("perBalanceSum", balanceSiAcct != null ? balanceSiAcct.getPerSum() : new BigDecimal("0"));
record.put("comBalanceSum", balanceSiAcct != null ? balanceSiAcct.getComSum() : new BigDecimal("0"));
result.add(record);
});
return result;
}
@ -1168,103 +1174,111 @@ public class SIAccountServiceImpl extends Service implements SIAccountService {
Map<String, String> result = new LinkedHashMap<>();
Map<String, String> commonResult = new LinkedHashMap<>();
Map<String, String> repairResult = new LinkedHashMap<>();
Map<String, String> balanceResult = new LinkedHashMap<>();
Map<String, String> baseResult = new LinkedHashMap<>();
// 获取所有个税扣缴义务人
List<TaxAgentPO> allTaxAgentList = getTaxAgentService(user).listAll();
for (TaxAgentPO taxAgentPO : allTaxAgentList) {
Map<String, String> commonResult = new LinkedHashMap<>();
Map<String, String> repairResult = new LinkedHashMap<>();
Map<String, String> balanceResult = new LinkedHashMap<>();
Map<String, String> baseResult = new LinkedHashMap<>();
result.put(SalaryI18nUtil.getI18nLabel(100393, "个人合计"), "perSum");
result.put(SalaryI18nUtil.getI18nLabel(100388, "社保个人合计"), "socialPerSum");
result.put(SalaryI18nUtil.getI18nLabel(100390, "公积金个人合计"), "fundPerSum");
result.put(SalaryI18nUtil.getI18nLabel(100392, "其他福利个人合计"), "otherPerSum");
String taxAgentNameFlag = taxAgentPO.getName() + "_";
String taxAgentIdFlag = taxAgentPO.getId() + "_";
commonResult.put(SalaryI18nUtil.getI18nLabel(0, "个人正常缴纳合计"), "perCommonSum");
commonResult.put(SalaryI18nUtil.getI18nLabel(0, "社保个人正常缴纳合计"), "socialPerCommonSum");
commonResult.put(SalaryI18nUtil.getI18nLabel(0, "公积金个人正常缴纳合计"), "fundPerCommonSum");
commonResult.put(SalaryI18nUtil.getI18nLabel(0, "其他福利个人正常缴纳合计"), "otherPerCommonSum");
repairResult.put(SalaryI18nUtil.getI18nLabel(0, "个人补缴合计"), "perRepairSum");
repairResult.put(SalaryI18nUtil.getI18nLabel(0, "社保个人补缴合计"), "socialPerRepairSum");
repairResult.put(SalaryI18nUtil.getI18nLabel(0, "公积金个人补缴合计"), "fundPerRepairSum");
repairResult.put(SalaryI18nUtil.getI18nLabel(0, "其他福利个人补缴合计"), "otherPerRepairSum");
balanceResult.put(SalaryI18nUtil.getI18nLabel(0, "个人补差合计"), "perBalanceSum");
balanceResult.put(SalaryI18nUtil.getI18nLabel(0, "社保个人补差合计"), "socialPerBalanceSum");
balanceResult.put(SalaryI18nUtil.getI18nLabel(0, "公积金个人补差合计"), "fundPerBalanceSum");
balanceResult.put(SalaryI18nUtil.getI18nLabel(0, "其他福利个人补差合计"), "otherPerBalanceSum");
result.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(100393, "个人合计"), taxAgentIdFlag + "perSum");
result.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(100388, "社保个人合计"), taxAgentIdFlag + "socialPerSum");
result.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(100390, "公积金个人合计"), taxAgentIdFlag + "fundPerSum");
result.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(100392, "其他福利个人合计"), taxAgentIdFlag + "otherPerSum");
Map<String, String> categoryIdNameMap = getSICategoryService(user).categoryIdNameMap();
list.stream().forEach(item -> {
if (Objects.equals(WelfareTypeEnum.SOCIAL_SECURITY.getValue(), item.getWelfareType())) {
if (Objects.equals(DataTypeEnum.SYSTEM.getValue(), item.getDataType())) {
baseResult.put(categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "申报基数"), item.getId() + "socialBase");
commonResult.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(0, "个人正常缴纳合计"), taxAgentIdFlag + "perCommonSum");
commonResult.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(0, "社保个人正常缴纳合计"), taxAgentIdFlag + "socialPerCommonSum");
commonResult.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(0, "公积金个人正常缴纳合计"), taxAgentIdFlag + "fundPerCommonSum");
commonResult.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(0, "其他福利个人正常缴纳合计"), taxAgentIdFlag + "otherPerCommonSum");
repairResult.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(0, "个人补缴合计"), taxAgentIdFlag + "perRepairSum");
repairResult.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(0, "社保个人补缴合计"), taxAgentIdFlag + "socialPerRepairSum");
repairResult.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(0, "公积金个人补缴合计"), taxAgentIdFlag + "fundPerRepairSum");
repairResult.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(0, "其他福利个人补缴合计"), taxAgentIdFlag + "otherPerRepairSum");
balanceResult.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(0, "个人补差合计"), taxAgentIdFlag + "perBalanceSum");
balanceResult.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(0, "社保个人补差合计"), taxAgentIdFlag + "socialPerBalanceSum");
balanceResult.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(0, "公积金个人补差合计"), taxAgentIdFlag + "fundPerBalanceSum");
balanceResult.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(0, "其他福利个人补差合计"), taxAgentIdFlag + "otherPerBalanceSum");
Map<String, String> categoryIdNameMap = getSICategoryService(user).categoryIdNameMap();
list.stream().forEach(item -> {
if (Objects.equals(WelfareTypeEnum.SOCIAL_SECURITY.getValue(), item.getWelfareType())) {
if (Objects.equals(DataTypeEnum.SYSTEM.getValue(), item.getDataType())) {
baseResult.put(taxAgentNameFlag + categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "申报基数"), taxAgentIdFlag + item.getId() + "socialBase");
}
result.put(taxAgentNameFlag + categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(87159, "个人"), taxAgentIdFlag + item.getId() + "socialPer");
commonResult.put(taxAgentNameFlag + categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "正常缴纳个人"), taxAgentIdFlag + item.getId() + "socialCommonPer");
repairResult.put(taxAgentNameFlag + categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "补缴个人"), taxAgentIdFlag + item.getId() + "socialRepairPer");
balanceResult.put(taxAgentNameFlag + categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "补差个人"), taxAgentIdFlag + item.getId() + "socialBalancePer");
}
result.put(categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(87159, "个人"), item.getId() + "socialPer");
commonResult.put(categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "正常缴纳个人"), item.getId() + "socialCommonPer");
repairResult.put(categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "补缴个人"), item.getId() + "socialRepairPer");
balanceResult.put(categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "补差个人"), item.getId() + "socialBalancePer");
}
if (Objects.equals(WelfareTypeEnum.ACCUMULATION_FUND.getValue(), item.getWelfareType())) {
if (Objects.equals(DataTypeEnum.SYSTEM.getValue(), item.getDataType())) {
baseResult.put(categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "申报基数"), item.getId() + "fundBase");
if (Objects.equals(WelfareTypeEnum.ACCUMULATION_FUND.getValue(), item.getWelfareType())) {
if (Objects.equals(DataTypeEnum.SYSTEM.getValue(), item.getDataType())) {
baseResult.put(taxAgentNameFlag + categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "申报基数"), taxAgentIdFlag + item.getId() + "fundBase");
}
result.put(taxAgentNameFlag + categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(87159, "个人"), taxAgentIdFlag + item.getId() + "fundPer");
commonResult.put(taxAgentNameFlag + categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "正常缴纳个人"), taxAgentIdFlag + item.getId() + "fundCommonPer");
repairResult.put(taxAgentNameFlag + categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "补缴个人"), taxAgentIdFlag + item.getId() + "fundRepairPer");
balanceResult.put(taxAgentNameFlag + categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "补差个人"), taxAgentIdFlag + item.getId() + "fundBalancePer");
}
result.put(categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(87159, "个人"), item.getId() + "fundPer");
commonResult.put(categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "正常缴纳个人"), item.getId() + "fundCommonPer");
repairResult.put(categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "补缴个人"), item.getId() + "fundRepairPer");
balanceResult.put(categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "补差个人"), item.getId() + "fundBalancePer");
}
if (Objects.equals(WelfareTypeEnum.OTHER.getValue(), item.getWelfareType())) {
if (Objects.equals(DataTypeEnum.SYSTEM.getValue(), item.getDataType())) {
baseResult.put(categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "申报基数"), item.getId() + "otherBase");
if (Objects.equals(WelfareTypeEnum.OTHER.getValue(), item.getWelfareType())) {
if (Objects.equals(DataTypeEnum.SYSTEM.getValue(), item.getDataType())) {
baseResult.put(taxAgentNameFlag + categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "申报基数"),taxAgentIdFlag + item.getId() + "otherBase");
}
result.put(taxAgentNameFlag + categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(87159, "个人"), taxAgentIdFlag + item.getId() + "otherPer");
commonResult.put(taxAgentNameFlag + categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "正常缴纳个人"), taxAgentIdFlag + item.getId() + "otherCommonPer");
repairResult.put(taxAgentNameFlag + categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "补缴个人"), taxAgentIdFlag + item.getId() + "otherRepairPer");
balanceResult.put(taxAgentNameFlag + categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "补差个人"), taxAgentIdFlag + item.getId() + "otherBalancePer");
}
result.put(categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(87159, "个人"), item.getId() + "otherPer");
commonResult.put(categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "正常缴纳个人"), item.getId() + "otherCommonPer");
repairResult.put(categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "补缴个人"), item.getId() + "otherRepairPer");
balanceResult.put(categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "补差个人"), item.getId() + "otherBalancePer");
}
});
result.put(SalaryI18nUtil.getI18nLabel(100397, "单位合计"), "comSum");
result.put(SalaryI18nUtil.getI18nLabel(100394, "社保单位合计"), "socialComSum");
result.put(SalaryI18nUtil.getI18nLabel(100395, "公积金单位合计"), "fundComSum");
result.put(SalaryI18nUtil.getI18nLabel(100396, "其他福利单位合计"), "otherComSum");
});
result.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(100397, "单位合计"), taxAgentIdFlag + "comSum");
result.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(100394, "社保单位合计"), taxAgentIdFlag + "socialComSum");
result.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(100395, "公积金单位合计"), taxAgentIdFlag + "fundComSum");
result.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(100396, "其他福利单位合计"), taxAgentIdFlag + "otherComSum");
commonResult.put(SalaryI18nUtil.getI18nLabel(0, "单位正常缴纳合计"), "comCommonSum");
commonResult.put(SalaryI18nUtil.getI18nLabel(0, "社保单位正常缴纳合计"), "socialComCommonSum");
commonResult.put(SalaryI18nUtil.getI18nLabel(0, "公积金单位正常缴纳合计"), "fundComCommonSum");
commonResult.put(SalaryI18nUtil.getI18nLabel(0, "其他福利单位正常缴纳合计"), "otherComCommonSum");
repairResult.put(SalaryI18nUtil.getI18nLabel(0, "单位补缴合计"), "comRepairSum");
repairResult.put(SalaryI18nUtil.getI18nLabel(0, "社保单位补缴合计"), "socialComRepairSum");
repairResult.put(SalaryI18nUtil.getI18nLabel(0, "公积金单位补缴合计"), "fundComRepairSum");
repairResult.put(SalaryI18nUtil.getI18nLabel(0, "其他福利单位补缴合计"), "otherComRepairSum");
balanceResult.put(SalaryI18nUtil.getI18nLabel(0, "单位补差合计"), "comBalanceSum");
balanceResult.put(SalaryI18nUtil.getI18nLabel(0, "社保单位补差合计"), "socialComBalanceSum");
balanceResult.put(SalaryI18nUtil.getI18nLabel(0, "公积金单位补差合计"), "fundComBalanceSum");
balanceResult.put(SalaryI18nUtil.getI18nLabel(0, "其他福利单位补差合计"), "otherComBalanceSum");
commonResult.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(0, "单位正常缴纳合计"), taxAgentIdFlag + "comCommonSum");
commonResult.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(0, "社保单位正常缴纳合计"), taxAgentIdFlag + "socialComCommonSum");
commonResult.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(0, "公积金单位正常缴纳合计"), taxAgentIdFlag + "fundComCommonSum");
commonResult.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(0, "其他福利单位正常缴纳合计"), taxAgentIdFlag + "otherComCommonSum");
repairResult.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(0, "单位补缴合计"), taxAgentIdFlag + "comRepairSum");
repairResult.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(0, "社保单位补缴合计"), taxAgentIdFlag + "socialComRepairSum");
repairResult.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(0, "公积金单位补缴合计"), taxAgentIdFlag + "fundComRepairSum");
repairResult.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(0, "其他福利单位补缴合计"), taxAgentIdFlag + "otherComRepairSum");
balanceResult.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(0, "单位补差合计"), taxAgentIdFlag + "comBalanceSum");
balanceResult.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(0, "社保单位补差合计"), taxAgentIdFlag + "socialComBalanceSum");
balanceResult.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(0, "公积金单位补差合计"), taxAgentIdFlag + "fundComBalanceSum");
balanceResult.put(taxAgentNameFlag + SalaryI18nUtil.getI18nLabel(0, "其他福利单位补差合计"), taxAgentIdFlag + "otherComBalanceSum");
list.stream().forEach(item -> {
if (Objects.equals(WelfareTypeEnum.SOCIAL_SECURITY.getValue(), item.getWelfareType())) {
result.put(categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(100289, "单位"), item.getId() + "socialCom");
commonResult.put(categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "正常缴纳单位"), item.getId() + "socialCommonCom");
repairResult.put(categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "补缴单位"), item.getId() + "socialRepairCom");
balanceResult.put(categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "补差单位"), item.getId() + "socialBalanceCom");
}
if (Objects.equals(WelfareTypeEnum.ACCUMULATION_FUND.getValue(), item.getWelfareType())) {
result.put(categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(100289, "单位"), item.getId() + "fundCom");
commonResult.put(categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "正常缴纳单位"), item.getId() + "fundCommonCom");
repairResult.put(categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "补缴单位"), item.getId() + "fundRepairCom");
balanceResult.put(categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "补差单位"), item.getId() + "fundBalanceCom");
}
if (Objects.equals(WelfareTypeEnum.OTHER.getValue(), item.getWelfareType())) {
result.put(categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(100289, "单位"), item.getId() + "otherCom");
commonResult.put(categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "正常缴纳单位"), item.getId() + "otherCommonCom");
repairResult.put(categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "补缴单位"), item.getId() + "otherRepairCom");
balanceResult.put(categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "补差单位"), item.getId() + "otherBalanceCom");
}
});
list.stream().forEach(item -> {
if (Objects.equals(WelfareTypeEnum.SOCIAL_SECURITY.getValue(), item.getWelfareType())) {
result.put(taxAgentNameFlag + categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(100289, "单位"), taxAgentIdFlag + item.getId() + "socialCom");
commonResult.put(taxAgentNameFlag + categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "正常缴纳单位"), taxAgentIdFlag + item.getId() + "socialCommonCom");
repairResult.put(taxAgentNameFlag + categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "补缴单位"), taxAgentIdFlag + item.getId() + "socialRepairCom");
balanceResult.put(taxAgentNameFlag + categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "补差单位"), taxAgentIdFlag + item.getId() + "socialBalanceCom");
}
if (Objects.equals(WelfareTypeEnum.ACCUMULATION_FUND.getValue(), item.getWelfareType())) {
result.put(taxAgentNameFlag + categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(100289, "单位"), taxAgentIdFlag + item.getId() + "fundCom");
commonResult.put(taxAgentNameFlag + categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "正常缴纳单位"), taxAgentIdFlag + item.getId() + "fundCommonCom");
repairResult.put(taxAgentNameFlag + categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "补缴单位"), taxAgentIdFlag + item.getId() + "fundRepairCom");
balanceResult.put(taxAgentNameFlag + categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "补差单位"), taxAgentIdFlag + item.getId() + "fundBalanceCom");
}
if (Objects.equals(WelfareTypeEnum.OTHER.getValue(), item.getWelfareType())) {
result.put(taxAgentNameFlag + categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(100289, "单位"), taxAgentIdFlag + item.getId() + "otherCom");
commonResult.put(taxAgentNameFlag + categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "正常缴纳单位"), taxAgentIdFlag + item.getId() + "otherCommonCom");
repairResult.put(taxAgentNameFlag + categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "补缴单位"), taxAgentIdFlag + item.getId() + "otherRepairCom");
balanceResult.put(taxAgentNameFlag + categoryIdNameMap.get(String.valueOf(item.getId())) + SalaryI18nUtil.getI18nLabel(0, "补差单位"), taxAgentIdFlag + item.getId() + "otherBalanceCom");
}
});
result.putAll(baseResult);
result.putAll(commonResult);
result.putAll(repairResult);
result.putAll(balanceResult);
}
result.putAll(baseResult);
result.putAll(commonResult);
result.putAll(repairResult);
result.putAll(balanceResult);
return result;
}