1、社保福利台账补差下载导入模板,显示的是补差数据; 2、报表分享不设置起始日期时oracle数据库兼容问题;
This commit is contained in:
parent
e4af4b8918
commit
b6331b952c
|
|
@ -116,6 +116,14 @@ public interface InsuranceAccountDetailMapper {
|
|||
*/
|
||||
List<InsuranceAccountDetailPO> querySupplementListByBillMonth(@Param("billMonth") String billMonth, @Param("paymentOrganization") Long paymentOrganization);
|
||||
|
||||
/**
|
||||
* 查询补差数据
|
||||
* @param billMonth 账单月份
|
||||
* @param paymentOrganization 个税扣缴义务人
|
||||
* @return
|
||||
*/
|
||||
List<InsuranceAccountDetailPO> queryBalanceListByBillMonth(@Param("billMonth") String billMonth, @Param("paymentOrganization") Long paymentOrganization);
|
||||
|
||||
/**
|
||||
* 查询正常缴纳数据
|
||||
* @param billMonth 账单月份
|
||||
|
|
|
|||
|
|
@ -541,6 +541,17 @@
|
|||
AND t.payment_organization = #{paymentOrganization}
|
||||
</select>
|
||||
|
||||
<select id="queryBalanceListByBillMonth" resultMap="BaseResultMap">
|
||||
SELECT
|
||||
t.id,t.employee_id,t.supplementary_month,t.supplementary_projects
|
||||
FROM
|
||||
hrsa_bill_detail t
|
||||
WHERE t.delete_type = 0
|
||||
AND t.payment_status = 4
|
||||
AND t.bill_month = #{billMonth}
|
||||
AND t.payment_organization = #{paymentOrganization}
|
||||
</select>
|
||||
|
||||
<select id="queryNormalListByBillMonth" resultMap="BaseResultMap">
|
||||
SELECT
|
||||
t.id,t.employee_id
|
||||
|
|
|
|||
|
|
@ -746,7 +746,7 @@ public class SalaryStatisticsPushServiceImpl extends Service implements SalarySt
|
|||
// 报表分享时间校验
|
||||
String formatLocalDateTime = SalaryDateUtil.getFormatLocalDate(LocalDateTime.now());
|
||||
List<SalaryStatisticsPushPO> result = pushList.stream().filter(pushPO -> {
|
||||
if (pushPO.getStartTime().compareTo(formatLocalDateTime) > 0 || (StringUtils.isNotEmpty(pushPO.getEndTime()) && pushPO.getEndTime().compareTo(formatLocalDateTime) < 0)) {
|
||||
if ((StringUtils.isNotBlank(pushPO.getStartTime()) && pushPO.getStartTime().compareTo(formatLocalDateTime) > 0) || (StringUtils.isNotEmpty(pushPO.getEndTime()) && pushPO.getEndTime().compareTo(formatLocalDateTime) < 0)) {
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
|
|
|
|||
|
|
@ -2056,6 +2056,40 @@ public class SIAccountServiceImpl extends Service implements SIAccountService {
|
|||
return resultList;
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取福利台账中的补差数据
|
||||
* @param billMonth 账单月份
|
||||
* @param paymentOrganization 个税扣缴义务人id
|
||||
* @return
|
||||
*/
|
||||
private List<Map<String, Object>> getBalanceDataByBillMonth(String billMonth, Long paymentOrganization) {
|
||||
|
||||
List<Map<String, Object>> resultList = new ArrayList<>();
|
||||
|
||||
DataCollectionEmployee employee = new DataCollectionEmployee();
|
||||
|
||||
TaxAgentPO taxAgentPO = taxAgentBiz.getById(paymentOrganization);
|
||||
|
||||
List<InsuranceAccountDetailPO> balanceDataList = getInsuranceAccountDetailMapper().queryBalanceListByBillMonth(billMonth, paymentOrganization);
|
||||
|
||||
|
||||
for(InsuranceAccountDetailPO po : balanceDataList) {
|
||||
Map<String, Object> resultMap = new HashMap<>();
|
||||
employee = getSalaryEmployeeService(user).getEmployeeById(po.getEmployeeId());
|
||||
resultMap.put("username", employee.getUsername());
|
||||
resultMap.put("departmentName", employee.getDepartmentName());
|
||||
resultMap.put("mobile", employee.getMobile());
|
||||
resultMap.put("workcode", employee.getWorkcode());
|
||||
resultMap.put("idNo", employee.getIdNo());
|
||||
resultMap.put("taxAgentName", taxAgentPO.getName());
|
||||
resultMap.put("billMonth", billMonth);
|
||||
resultMap.put("supplementaryMonth", po.getSupplementaryMonth());
|
||||
|
||||
resultList.add(resultMap);
|
||||
}
|
||||
return resultList;
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取福利台账中的正常缴纳数据
|
||||
* @param billMonth 账单月份
|
||||
|
|
@ -3774,7 +3808,7 @@ public class SIAccountServiceImpl extends Service implements SIAccountService {
|
|||
|
||||
List<List<Object>> rows = new ArrayList<>();
|
||||
//查询当前已有的补差数据
|
||||
List<Map<String, Object>> resultMapList = getSupplyDataByBillMonth(param.getBillMonth(), param.getPaymentOrganization());
|
||||
List<Map<String, Object>> resultMapList = getBalanceDataByBillMonth(param.getBillMonth(), param.getPaymentOrganization());
|
||||
// excel导出的数据
|
||||
rows.add(headerList);
|
||||
for (Map<String, Object> map : resultMapList) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue