薪酬系统-福利台账,退差数据新增v3
This commit is contained in:
parent
955f8c255e
commit
15477cc8d5
|
|
@ -162,4 +162,10 @@ public interface InsuranceAccountDetailMapper {
|
|||
* 根据id更新数据
|
||||
*/
|
||||
void updateById(InsuranceAccountDetailPO po);
|
||||
|
||||
|
||||
/**
|
||||
* 删除退差数据(账单月份+退差月份+缴纳状态+人员id+个税扣缴义务人)
|
||||
*/
|
||||
void deleteRecessionData(InsuranceAccountDetailPO po);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1184,4 +1184,15 @@
|
|||
</set>
|
||||
WHERE id = #{id}
|
||||
</update>
|
||||
|
||||
<delete id="deleteRecessionData" parameterType="com.engine.salary.entity.siaccount.po.InsuranceAccountDetailPO">
|
||||
DELETE
|
||||
FROM hrsa_bill_detail
|
||||
WHERE delete_type = 0
|
||||
AND bill_month = #{billMonth}
|
||||
AND payment_status = #{paymentStatus}
|
||||
AND payment_organization = #{paymentOrganization}
|
||||
AND supplementary_month = #{supplementaryMonth}
|
||||
AND employee_id = #{employeeId}
|
||||
</delete>
|
||||
</mapper>
|
||||
|
|
@ -90,18 +90,12 @@ public class SIRecessionServiceImpl extends Service implements SIRecessionServic
|
|||
});
|
||||
//退差数据入库
|
||||
if (CollectionUtils.isNotEmpty(finalRecessionDetails)) {
|
||||
|
||||
//
|
||||
//查询退差员工中是否已经进行有过退差记录,有过则更新
|
||||
// List<InsuranceAccountDetailPO> haveRecessionPOS= getInsuranceAccountDetailMapper().list(InsuranceAccountDetailParam.builder()
|
||||
// .paymentStatus(PaymentStatusEnum.RECESSION.getValue())
|
||||
// .recessionMonthList(param.getRecessionMonthList())
|
||||
// .employeeIds(employeeIds)
|
||||
// .paymentOrganization(param.getPaymentOrganization())
|
||||
// .build());
|
||||
//
|
||||
InsuranceAccountDetailPOEncrypt.encryptInsuranceAccountDetailPOList(finalRecessionDetails);
|
||||
|
||||
//删除已有退差记录
|
||||
finalRecessionDetails.forEach(getInsuranceAccountDetailMapper()::deleteRecessionData);
|
||||
|
||||
//入库新数据
|
||||
List<List<InsuranceAccountDetailPO>> partition = Lists.partition((List<InsuranceAccountDetailPO>) finalRecessionDetails, 20);
|
||||
partition.forEach(getInsuranceAccountDetailMapper()::batchSaveAccountDetails);
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue