社保台账:
1、批量新建核算记录并核算。 2、批量归档 3、批量重新核算 薪资核算: 1、批量新建核算记录并核算。 2、批量归档 3、批量重新核算 工资单: 1、批量发放 2、批量撤回 申报表: 1、批量申报
This commit is contained in:
parent
0762fbee4d
commit
2767114bfb
|
|
@ -0,0 +1,27 @@
|
||||||
|
package com.engine.salary.entity.salaryBill.param;
|
||||||
|
|
||||||
|
import lombok.AllArgsConstructor;
|
||||||
|
import lombok.Builder;
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.NoArgsConstructor;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 工资单批量操作参数
|
||||||
|
* <p>Copyright: Copyright (c) 2024</p>
|
||||||
|
* <p>Company: 泛微软件</p>
|
||||||
|
*
|
||||||
|
* @author qiantao
|
||||||
|
* @version 1.0
|
||||||
|
**/
|
||||||
|
@Data
|
||||||
|
@Builder
|
||||||
|
@NoArgsConstructor
|
||||||
|
@AllArgsConstructor
|
||||||
|
public class SalarySendBatParam {
|
||||||
|
|
||||||
|
// 工资单发放Id
|
||||||
|
private List<Long> salarySendIds;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,34 @@
|
||||||
|
package com.engine.salary.entity.salaryacct.param;
|
||||||
|
|
||||||
|
import lombok.AllArgsConstructor;
|
||||||
|
import lombok.Builder;
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.NoArgsConstructor;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量操作参数
|
||||||
|
* <p>Copyright: Copyright (c) 2024</p>
|
||||||
|
* <p>Company: 泛微软件</p>
|
||||||
|
*
|
||||||
|
* @author qiantao
|
||||||
|
* @version 1.0
|
||||||
|
**/
|
||||||
|
@Data
|
||||||
|
@Builder
|
||||||
|
@NoArgsConstructor
|
||||||
|
@AllArgsConstructor
|
||||||
|
public class SalaryAcctBatParam {
|
||||||
|
|
||||||
|
//薪资所属月
|
||||||
|
private Date salaryMonth;
|
||||||
|
//薪资账套id
|
||||||
|
private List<Long> salarySobIds;
|
||||||
|
//备注
|
||||||
|
private String description;
|
||||||
|
|
||||||
|
|
||||||
|
private List<Long> salaryAcctRecordIds;
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,40 @@
|
||||||
|
package com.engine.salary.entity.siaccount.param;
|
||||||
|
|
||||||
|
|
||||||
|
import com.engine.salary.util.valid.DataCheck;
|
||||||
|
import lombok.AllArgsConstructor;
|
||||||
|
import lombok.Builder;
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.NoArgsConstructor;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
|
||||||
|
@Data
|
||||||
|
@Builder
|
||||||
|
@NoArgsConstructor
|
||||||
|
@AllArgsConstructor
|
||||||
|
public class AccountBatParam {
|
||||||
|
|
||||||
|
//账单月份")
|
||||||
|
//@NotNull
|
||||||
|
@DataCheck(require = true,message = "账单月份不能为空")
|
||||||
|
private String billMonth;
|
||||||
|
|
||||||
|
//备注")
|
||||||
|
//@Length(max = 60)
|
||||||
|
@DataCheck(max = 60,message = "备注长度不能超过60个字符")
|
||||||
|
private String remarks;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 个税扣缴义务人id
|
||||||
|
*/
|
||||||
|
@DataCheck(require = true,message = "个税扣缴义务人不能为空")
|
||||||
|
private List<Long> paymentOrganizations;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
private List<Long> ids;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,54 @@
|
||||||
|
package com.engine.salary.entity.taxdeclaration.param;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import lombok.AllArgsConstructor;
|
||||||
|
import lombok.Builder;
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.NoArgsConstructor;
|
||||||
|
|
||||||
|
import java.time.YearMonth;
|
||||||
|
import java.util.Date;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生成个税申报表参数
|
||||||
|
* <p>Copyright: Copyright (c) 2022</p>
|
||||||
|
* <p>Company: 泛微软件</p>
|
||||||
|
*
|
||||||
|
* @author qiantao
|
||||||
|
* @version 1.0
|
||||||
|
**/
|
||||||
|
@Data
|
||||||
|
@Builder
|
||||||
|
@NoArgsConstructor
|
||||||
|
@AllArgsConstructor
|
||||||
|
public class TaxDeclarationBatParam {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 个税申报id
|
||||||
|
*/
|
||||||
|
private Long taxDeclarationId;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 薪资所属月
|
||||||
|
*/
|
||||||
|
private YearMonth salaryMonth;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 个税扣缴义务人
|
||||||
|
*/
|
||||||
|
private List<Long> taxAgentIds;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 备注
|
||||||
|
*/
|
||||||
|
private String description;
|
||||||
|
|
||||||
|
private String salaryMonthStr;
|
||||||
|
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
private Date taxCycle;
|
||||||
|
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
private Date salaryDate;
|
||||||
|
}
|
||||||
|
|
@ -320,5 +320,13 @@ public interface SIAccountService {
|
||||||
void cacheWelfareField(List<String> welfareNames);
|
void cacheWelfareField(List<String> welfareNames);
|
||||||
|
|
||||||
void cacheBalanceWelfareField(List<String> welfareNames);
|
void cacheBalanceWelfareField(List<String> welfareNames);
|
||||||
|
|
||||||
|
void batSave(AccountBatParam param);
|
||||||
|
|
||||||
|
void batDelete(AccountBatParam param);
|
||||||
|
|
||||||
|
void batFile(AccountBatParam param);
|
||||||
|
|
||||||
|
void batSocialSecurityBenefitsRecalculate(AccountBatParam batParam);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
package com.engine.salary.service;
|
package com.engine.salary.service;
|
||||||
|
|
||||||
import com.engine.salary.common.LocalDateRange;
|
import com.engine.salary.common.LocalDateRange;
|
||||||
|
import com.engine.salary.entity.salaryacct.param.SalaryAcctBatParam;
|
||||||
import com.engine.salary.entity.salaryacct.param.SalaryAcctRecordQueryParam;
|
import com.engine.salary.entity.salaryacct.param.SalaryAcctRecordQueryParam;
|
||||||
import com.engine.salary.entity.salaryacct.param.SalaryAcctRecordSaveParam;
|
import com.engine.salary.entity.salaryacct.param.SalaryAcctRecordSaveParam;
|
||||||
import com.engine.salary.entity.salaryacct.po.SalaryAcctRecordPO;
|
import com.engine.salary.entity.salaryacct.po.SalaryAcctRecordPO;
|
||||||
|
|
@ -210,4 +211,11 @@ public interface SalaryAcctRecordService {
|
||||||
List<SalaryAcctRecordPO> listSome(SalaryAcctRecordPO po);
|
List<SalaryAcctRecordPO> listSome(SalaryAcctRecordPO po);
|
||||||
|
|
||||||
void updateDate(Long id, Date updateTime);
|
void updateDate(Long id, Date updateTime);
|
||||||
|
|
||||||
|
void batSave(SalaryAcctBatParam saveParam);
|
||||||
|
|
||||||
|
void batFile(SalaryAcctBatParam param);
|
||||||
|
|
||||||
|
void batReCalculate(SalaryAcctBatParam param);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -6802,6 +6802,52 @@ public class SIAccountServiceImpl extends Service implements SIAccountService {
|
||||||
Util_DataCache.setObjVal(cacheKey, JsonUtil.toJsonString(welfareNames));
|
Util_DataCache.setObjVal(cacheKey, JsonUtil.toJsonString(welfareNames));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void batSave(AccountBatParam accountBatParam) {
|
||||||
|
List<Long> paymentOrganizations = accountBatParam.getPaymentOrganizations();
|
||||||
|
for (Long paymentOrganization : paymentOrganizations) {
|
||||||
|
AccountParam param = AccountParam.builder()
|
||||||
|
.billMonth(accountBatParam.getBillMonth())
|
||||||
|
.paymentOrganization(paymentOrganization)
|
||||||
|
.remarks(accountBatParam.getRemarks())
|
||||||
|
.build();
|
||||||
|
save(param);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void batDelete(AccountBatParam batParam) {
|
||||||
|
List<Long> paymentOrganizations = batParam.getPaymentOrganizations();
|
||||||
|
for (Long paymentOrganization : paymentOrganizations) {
|
||||||
|
AccountParam param = AccountParam.builder()
|
||||||
|
.billMonth(batParam.getBillMonth())
|
||||||
|
.paymentOrganization(paymentOrganization)
|
||||||
|
.build();
|
||||||
|
delete(param);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void batFile(AccountBatParam batParam) {
|
||||||
|
List<Long> paymentOrganizations = batParam.getPaymentOrganizations();
|
||||||
|
for (Long paymentOrganization : paymentOrganizations) {
|
||||||
|
AccountParam param = AccountParam.builder()
|
||||||
|
.billMonth(batParam.getBillMonth())
|
||||||
|
.paymentOrganization(paymentOrganization)
|
||||||
|
.build();
|
||||||
|
file(param);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void batSocialSecurityBenefitsRecalculate(AccountBatParam batParam) {
|
||||||
|
List<Long> ids = batParam.getIds();
|
||||||
|
for (Long id : ids) {
|
||||||
|
InsuranceAccountBatchPO param = InsuranceAccountBatchPO.builder().id(id).build();
|
||||||
|
socialSecurityBenefitsRecalculate(param);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public void accountOtherView(InsuranceAccountViewListDTO dto, List<InsuranceAccountDetailPO> pos) {
|
public void accountOtherView(InsuranceAccountViewListDTO dto, List<InsuranceAccountDetailPO> pos) {
|
||||||
int otherNum = 0;
|
int otherNum = 0;
|
||||||
BigDecimal otherPaySum = new BigDecimal("0");
|
BigDecimal otherPaySum = new BigDecimal("0");
|
||||||
|
|
|
||||||
|
|
@ -4,11 +4,12 @@ import cn.hutool.core.collection.CollUtil;
|
||||||
import com.api.formmode.mybatis.util.SqlProxyHandle;
|
import com.api.formmode.mybatis.util.SqlProxyHandle;
|
||||||
import com.engine.common.util.ServiceUtil;
|
import com.engine.common.util.ServiceUtil;
|
||||||
import com.engine.core.impl.Service;
|
import com.engine.core.impl.Service;
|
||||||
|
import com.engine.hrmelog.entity.dto.LoggerContext;
|
||||||
import com.engine.salary.common.LocalDateRange;
|
import com.engine.salary.common.LocalDateRange;
|
||||||
import com.engine.salary.config.SalaryElogConfig;
|
import com.engine.salary.config.SalaryElogConfig;
|
||||||
import com.engine.hrmelog.entity.dto.LoggerContext;
|
|
||||||
import com.engine.salary.entity.salaryBill.po.SalarySendPO;
|
import com.engine.salary.entity.salaryBill.po.SalarySendPO;
|
||||||
import com.engine.salary.entity.salaryacct.bo.SalaryAcctRecordBO;
|
import com.engine.salary.entity.salaryacct.bo.SalaryAcctRecordBO;
|
||||||
|
import com.engine.salary.entity.salaryacct.param.SalaryAcctBatParam;
|
||||||
import com.engine.salary.entity.salaryacct.param.SalaryAcctRecordQueryParam;
|
import com.engine.salary.entity.salaryacct.param.SalaryAcctRecordQueryParam;
|
||||||
import com.engine.salary.entity.salaryacct.param.SalaryAcctRecordSaveParam;
|
import com.engine.salary.entity.salaryacct.param.SalaryAcctRecordSaveParam;
|
||||||
import com.engine.salary.entity.salaryacct.po.SalaryAcctEmployeePO;
|
import com.engine.salary.entity.salaryacct.po.SalaryAcctEmployeePO;
|
||||||
|
|
@ -40,6 +41,7 @@ import org.apache.commons.lang3.StringUtils;
|
||||||
import org.apache.commons.lang3.math.NumberUtils;
|
import org.apache.commons.lang3.math.NumberUtils;
|
||||||
import weaver.hrm.User;
|
import weaver.hrm.User;
|
||||||
|
|
||||||
|
import java.time.YearMonth;
|
||||||
import java.util.*;
|
import java.util.*;
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
|
|
@ -845,4 +847,38 @@ public class SalaryAcctRecordServiceImpl extends Service implements SalaryAcctRe
|
||||||
public void updateDate(Long id, Date updateTime) {
|
public void updateDate(Long id, Date updateTime) {
|
||||||
getSalaryAcctRecordMapper().updateDate(id, updateTime);
|
getSalaryAcctRecordMapper().updateDate(id, updateTime);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void batSave(SalaryAcctBatParam saveParam) {
|
||||||
|
|
||||||
|
List<Long> salarySobIds = saveParam.getSalarySobIds();
|
||||||
|
YearMonth salaryMonth = SalaryDateUtil.localDate2YearMonth(saveParam.getSalaryMonth());
|
||||||
|
for (int i = 0; i < salarySobIds.size(); i++) {
|
||||||
|
Long salarySobId = salarySobIds.get(i);
|
||||||
|
SalaryAcctRecordSaveParam param = SalaryAcctRecordSaveParam.builder()
|
||||||
|
.salarySobId(salarySobId)
|
||||||
|
.salaryMonth(salaryMonth)
|
||||||
|
.description(saveParam.getDescription())
|
||||||
|
.build();
|
||||||
|
save(param);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void batFile(SalaryAcctBatParam param) {
|
||||||
|
List<Long> salaryAcctRecordIds = param.getSalaryAcctRecordIds();
|
||||||
|
for (int i = 0; i < salaryAcctRecordIds.size(); i++) {
|
||||||
|
Long recordId = salaryAcctRecordIds.get(i);
|
||||||
|
file(recordId);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void batReCalculate(SalaryAcctBatParam param) {
|
||||||
|
List<Long> salaryAcctRecordIds = param.getSalaryAcctRecordIds();
|
||||||
|
for (int i = 0; i < salaryAcctRecordIds.size(); i++) {
|
||||||
|
Long recordId = salaryAcctRecordIds.get(i);
|
||||||
|
reCalculate(recordId);
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -217,6 +217,38 @@ public class SIAccountController {
|
||||||
return new ResponseResult<AccountParam, String>(user).run(getService(user)::save, param);
|
return new ResponseResult<AccountParam, String>(user).run(getService(user)::save, param);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@POST
|
||||||
|
@Path("/batSave")
|
||||||
|
@Produces(MediaType.APPLICATION_JSON)
|
||||||
|
public String batSave(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody AccountBatParam param) {
|
||||||
|
User user = HrmUserVarify.getUser(request, response);
|
||||||
|
return new ResponseResult<AccountBatParam, String>(user).run(getService(user)::batSave, param);
|
||||||
|
}
|
||||||
|
|
||||||
|
@POST
|
||||||
|
@Path("/batDelete")
|
||||||
|
@Produces(MediaType.APPLICATION_JSON)
|
||||||
|
public String batDelete(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody AccountBatParam param) {
|
||||||
|
User user = HrmUserVarify.getUser(request, response);
|
||||||
|
return new ResponseResult<AccountBatParam, String>(user).run(getService(user)::batDelete, param);
|
||||||
|
}
|
||||||
|
|
||||||
|
@POST
|
||||||
|
@Path("/batFile")
|
||||||
|
@Produces(MediaType.APPLICATION_JSON)
|
||||||
|
public String batFile(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody AccountBatParam param) {
|
||||||
|
User user = HrmUserVarify.getUser(request, response);
|
||||||
|
return new ResponseResult<AccountBatParam, String>(user).run(getService(user)::batFile, param);
|
||||||
|
}
|
||||||
|
|
||||||
|
@POST
|
||||||
|
@Path("/batSocialSecurityBenefitsRecalculate")
|
||||||
|
@Produces(MediaType.APPLICATION_JSON)
|
||||||
|
public String batSocialSecurityBenefitsRecalculate(@Context HttpServletRequest request, @Context HttpServletResponse response,@RequestBody AccountBatParam batParam ){
|
||||||
|
User user = HrmUserVarify.getUser(request, response);
|
||||||
|
return new ResponseResult<AccountBatParam, String>(user).run(getService(user)::batSocialSecurityBenefitsRecalculate,batParam);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 正常缴纳页核算
|
* 正常缴纳页核算
|
||||||
|
|
|
||||||
|
|
@ -141,6 +141,43 @@ public class SalaryAcctController {
|
||||||
return new ResponseResult<Long, Long>(user).run(getSalaryAcctRecordWrapper(user)::reCalculate, param.getSalaryAcctRecordId());
|
return new ResponseResult<Long, Long>(user).run(getSalaryAcctRecordWrapper(user)::reCalculate, param.getSalaryAcctRecordId());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//薪资核算
|
||||||
|
@POST
|
||||||
|
@Path("/batAccounting")
|
||||||
|
@Produces(MediaType.APPLICATION_JSON)
|
||||||
|
public String batAccounting(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody SalaryAcctBatParam param) {
|
||||||
|
User user = HrmUserVarify.getUser(request, response);
|
||||||
|
return new ResponseResult<SalaryAcctBatParam, String>(user).run(getSalaryAcctRecordWrapper(user)::batCalculate, param);
|
||||||
|
}
|
||||||
|
|
||||||
|
//保存薪资核算的基本信息
|
||||||
|
@POST
|
||||||
|
@Path("/basic/batSave")
|
||||||
|
@Produces(MediaType.APPLICATION_JSON)
|
||||||
|
public String batSave(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody SalaryAcctBatParam param) {
|
||||||
|
User user = HrmUserVarify.getUser(request, response);
|
||||||
|
return new ResponseResult<SalaryAcctBatParam, Long>(user).run(getSalaryAcctRecordWrapper(user)::batSave, param);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
//归档薪资核算记录
|
||||||
|
@POST
|
||||||
|
@Path("/batFile")
|
||||||
|
@Produces(MediaType.APPLICATION_JSON)
|
||||||
|
public String batFile(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody SalaryAcctBatParam param) {
|
||||||
|
User user = HrmUserVarify.getUser(request, response);
|
||||||
|
return new ResponseResult<SalaryAcctBatParam, Long>(user).run(getSalaryAcctRecordWrapper(user)::batFile, param);
|
||||||
|
}
|
||||||
|
|
||||||
|
//重新核算
|
||||||
|
@POST
|
||||||
|
@Path("/batReAccounting")
|
||||||
|
@Produces(MediaType.APPLICATION_JSON)
|
||||||
|
public String batReAccounting(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody SalaryAcctBatParam param) {
|
||||||
|
User user = HrmUserVarify.getUser(request, response);
|
||||||
|
return new ResponseResult<SalaryAcctBatParam, Long>(user).run(getSalaryAcctRecordWrapper(user)::batReCalculate, param);
|
||||||
|
}
|
||||||
|
|
||||||
//判断是否存在合并计税
|
//判断是否存在合并计税
|
||||||
@GET
|
@GET
|
||||||
@Path("/hasConsolidatedTax")
|
@Path("/hasConsolidatedTax")
|
||||||
|
|
|
||||||
|
|
@ -480,6 +480,29 @@ public class SalaryBillController {
|
||||||
return new ResponseResult<SalarySendWithdrawParam, Map<String, Object>>(user).run(getSalarySendWrapper(user)::withdraw, queryParam);
|
return new ResponseResult<SalarySendWithdrawParam, Map<String, Object>>(user).run(getSalarySendWrapper(user)::withdraw, queryParam);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@POST
|
||||||
|
@Path("/send/batGrant")
|
||||||
|
@Produces(MediaType.APPLICATION_JSON)
|
||||||
|
public String batGrant(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody SalarySendBatParam queryParam) {
|
||||||
|
User user = HrmUserVarify.getUser(request, response);
|
||||||
|
return new ResponseResult<SalarySendBatParam, Map<String, Object>>(user).run(getSalarySendWrapper(user)::batGrant, queryParam);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 工资单撤回
|
||||||
|
*
|
||||||
|
* @param queryParam
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@POST
|
||||||
|
@Path("/send/batWithdraw")
|
||||||
|
@Produces(MediaType.APPLICATION_JSON)
|
||||||
|
public String batWithdraw(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody SalarySendBatParam queryParam) {
|
||||||
|
User user = HrmUserVarify.getUser(request, response);
|
||||||
|
return new ResponseResult<SalarySendBatParam, Map<String, Object>>(user).run(getSalarySendWrapper(user)::batWithdraw, queryParam);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 工资单发放详情列表的高级搜索
|
* 工资单发放详情列表的高级搜索
|
||||||
*
|
*
|
||||||
|
|
|
||||||
|
|
@ -4,6 +4,7 @@ import com.engine.common.util.ServiceUtil;
|
||||||
import com.engine.salary.entity.taxdeclaration.dto.TaxDeclarationFormDTO;
|
import com.engine.salary.entity.taxdeclaration.dto.TaxDeclarationFormDTO;
|
||||||
import com.engine.salary.entity.taxdeclaration.dto.TaxDeclarationInfoDTO;
|
import com.engine.salary.entity.taxdeclaration.dto.TaxDeclarationInfoDTO;
|
||||||
import com.engine.salary.entity.taxdeclaration.dto.TaxDeclarationListDTO;
|
import com.engine.salary.entity.taxdeclaration.dto.TaxDeclarationListDTO;
|
||||||
|
import com.engine.salary.entity.taxdeclaration.param.TaxDeclarationBatParam;
|
||||||
import com.engine.salary.entity.taxdeclaration.param.TaxDeclarationDetailListQueryParam;
|
import com.engine.salary.entity.taxdeclaration.param.TaxDeclarationDetailListQueryParam;
|
||||||
import com.engine.salary.entity.taxdeclaration.param.TaxDeclarationListQueryParam;
|
import com.engine.salary.entity.taxdeclaration.param.TaxDeclarationListQueryParam;
|
||||||
import com.engine.salary.entity.taxdeclaration.param.TaxDeclarationSaveParam;
|
import com.engine.salary.entity.taxdeclaration.param.TaxDeclarationSaveParam;
|
||||||
|
|
@ -99,6 +100,15 @@ public class TaxDeclarationController {
|
||||||
return new ResponseResult<TaxDeclarationSaveParam, Long>(user).run(getTaxDeclarationWrapper(user)::save, param);
|
return new ResponseResult<TaxDeclarationSaveParam, Long>(user).run(getTaxDeclarationWrapper(user)::save, param);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@POST
|
||||||
|
@Path("/batSave")
|
||||||
|
@Produces(MediaType.APPLICATION_JSON)
|
||||||
|
public String batSave(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody TaxDeclarationBatParam param) {
|
||||||
|
User user = HrmUserVarify.getUser(request, response);
|
||||||
|
param.setSalaryMonth(SalaryDateUtil.String2YearMonth(param.getSalaryMonthStr()));
|
||||||
|
return new ResponseResult<TaxDeclarationBatParam, Long>(user).run(getTaxDeclarationWrapper(user)::batSave, param);
|
||||||
|
}
|
||||||
|
|
||||||
//个税申报表详情列表
|
//个税申报表详情列表
|
||||||
@POST
|
@POST
|
||||||
@Path("/detail/list")
|
@Path("/detail/list")
|
||||||
|
|
|
||||||
|
|
@ -10,12 +10,13 @@ import com.engine.salary.entity.salaryacct.bo.SalaryAcctRecordBO;
|
||||||
import com.engine.salary.entity.salaryacct.dto.SalaryAcctEmployeeCountDTO;
|
import com.engine.salary.entity.salaryacct.dto.SalaryAcctEmployeeCountDTO;
|
||||||
import com.engine.salary.entity.salaryacct.dto.SalaryAcctRecordFormDTO;
|
import com.engine.salary.entity.salaryacct.dto.SalaryAcctRecordFormDTO;
|
||||||
import com.engine.salary.entity.salaryacct.dto.SalaryAcctRecordListDTO;
|
import com.engine.salary.entity.salaryacct.dto.SalaryAcctRecordListDTO;
|
||||||
|
import com.engine.salary.entity.salaryacct.param.SalaryAcctBatParam;
|
||||||
|
import com.engine.salary.entity.salaryacct.param.SalaryAcctCalculateParam;
|
||||||
import com.engine.salary.entity.salaryacct.param.SalaryAcctRecordQueryParam;
|
import com.engine.salary.entity.salaryacct.param.SalaryAcctRecordQueryParam;
|
||||||
import com.engine.salary.entity.salaryacct.param.SalaryAcctRecordSaveParam;
|
import com.engine.salary.entity.salaryacct.param.SalaryAcctRecordSaveParam;
|
||||||
import com.engine.salary.entity.salaryacct.po.SalaryAcctRecordPO;
|
import com.engine.salary.entity.salaryacct.po.SalaryAcctRecordPO;
|
||||||
import com.engine.salary.entity.salaryacct.po.SalaryAcctSobConfigPO;
|
import com.engine.salary.entity.salaryacct.po.SalaryAcctSobConfigPO;
|
||||||
import com.engine.salary.entity.salarysob.dto.SalarySobCycleDTO;
|
import com.engine.salary.entity.salarysob.dto.SalarySobCycleDTO;
|
||||||
import com.engine.salary.entity.salarysob.po.SalaryApprovalRulePO;
|
|
||||||
import com.engine.salary.entity.salarysob.po.*;
|
import com.engine.salary.entity.salarysob.po.*;
|
||||||
import com.engine.salary.entity.taxagent.po.TaxAgentPO;
|
import com.engine.salary.entity.taxagent.po.TaxAgentPO;
|
||||||
import com.engine.salary.enums.salaryaccounting.SalaryAcctRecordStatusEnum;
|
import com.engine.salary.enums.salaryaccounting.SalaryAcctRecordStatusEnum;
|
||||||
|
|
@ -55,6 +56,9 @@ public class SalaryAcctRecordWrapper extends Service implements SalaryAcctRecord
|
||||||
private SalaryAcctRecordService getSalaryAcctRecordService(User user) {
|
private SalaryAcctRecordService getSalaryAcctRecordService(User user) {
|
||||||
return ServiceUtil.getService(SalaryAcctRecordServiceImpl.class, user);
|
return ServiceUtil.getService(SalaryAcctRecordServiceImpl.class, user);
|
||||||
}
|
}
|
||||||
|
private SalaryAcctResultWrapper getSalaryAcctResultWrapper(User user) {
|
||||||
|
return ServiceUtil.getService(SalaryAcctResultWrapper.class, user);
|
||||||
|
}
|
||||||
|
|
||||||
private SalarySobService getSalarySobService(User user) {
|
private SalarySobService getSalarySobService(User user) {
|
||||||
return ServiceUtil.getService(SalarySobServiceImpl.class, user);
|
return ServiceUtil.getService(SalarySobServiceImpl.class, user);
|
||||||
|
|
@ -396,4 +400,28 @@ public class SalaryAcctRecordWrapper extends Service implements SalaryAcctRecord
|
||||||
public void updateSobConfig(Long id) {
|
public void updateSobConfig(Long id) {
|
||||||
getSalaryAcctSobConfigService(user).updateBySalaryAcctRecordId(id);
|
getSalaryAcctSobConfigService(user).updateBySalaryAcctRecordId(id);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public void batSave(SalaryAcctBatParam param) {
|
||||||
|
getSalaryAcctRecordService(user).batSave(param);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public void batFile(SalaryAcctBatParam param) {
|
||||||
|
getSalaryAcctRecordService(user).batFile(param);
|
||||||
|
}
|
||||||
|
|
||||||
|
public void batReCalculate(SalaryAcctBatParam param) {
|
||||||
|
getSalaryAcctRecordService(user).batReCalculate(param);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
public void batCalculate(SalaryAcctBatParam param) {
|
||||||
|
List<Long> salaryAcctRecordIds = param.getSalaryAcctRecordIds();
|
||||||
|
for (int i = 0; i < salaryAcctRecordIds.size(); i++) {
|
||||||
|
Long recordId = salaryAcctRecordIds.get(i);
|
||||||
|
SalaryAcctCalculateParam calculateParam = SalaryAcctCalculateParam.builder().salaryAcctRecordId(recordId).build();
|
||||||
|
getSalaryAcctResultWrapper(user).calculate(calculateParam);
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -751,4 +751,28 @@ public class SalarySendWrapper extends Service implements SalarySendWrapperProxy
|
||||||
public String genPdfBeforeExport(SalaryExportPdfParam salaryExportPdfParam) {
|
public String genPdfBeforeExport(SalaryExportPdfParam salaryExportPdfParam) {
|
||||||
return getSalaryBillService(user).genPdfBeforeExport(salaryExportPdfParam);
|
return getSalaryBillService(user).genPdfBeforeExport(salaryExportPdfParam);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public void batGrant(SalarySendBatParam param) {
|
||||||
|
List<Long> salarySendIds = param.getSalarySendIds();
|
||||||
|
|
||||||
|
for (int i = 0; i < salarySendIds.size(); i++) {
|
||||||
|
Long sendId = salarySendIds.get(i);
|
||||||
|
SalarySendGrantParam grantParam = SalarySendGrantParam.builder()
|
||||||
|
.salarySendId(sendId)
|
||||||
|
.build();
|
||||||
|
grant(grantParam);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
public void batWithdraw(SalarySendBatParam param) {
|
||||||
|
List<Long> salarySendIds = param.getSalarySendIds();
|
||||||
|
|
||||||
|
for (int i = 0; i < salarySendIds.size(); i++) {
|
||||||
|
Long sendId = salarySendIds.get(i);
|
||||||
|
SalarySendWithdrawParam grantParam = SalarySendWithdrawParam.builder()
|
||||||
|
.salarySendId(sendId)
|
||||||
|
.build();
|
||||||
|
withdraw(grantParam);
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -9,6 +9,7 @@ import com.engine.salary.entity.taxdeclaration.bo.TaxDeclarationBO;
|
||||||
import com.engine.salary.entity.taxdeclaration.dto.TaxDeclarationFormDTO;
|
import com.engine.salary.entity.taxdeclaration.dto.TaxDeclarationFormDTO;
|
||||||
import com.engine.salary.entity.taxdeclaration.dto.TaxDeclarationInfoDTO;
|
import com.engine.salary.entity.taxdeclaration.dto.TaxDeclarationInfoDTO;
|
||||||
import com.engine.salary.entity.taxdeclaration.dto.TaxDeclarationListDTO;
|
import com.engine.salary.entity.taxdeclaration.dto.TaxDeclarationListDTO;
|
||||||
|
import com.engine.salary.entity.taxdeclaration.param.TaxDeclarationBatParam;
|
||||||
import com.engine.salary.entity.taxdeclaration.param.TaxDeclarationListQueryParam;
|
import com.engine.salary.entity.taxdeclaration.param.TaxDeclarationListQueryParam;
|
||||||
import com.engine.salary.entity.taxdeclaration.param.TaxDeclarationSaveParam;
|
import com.engine.salary.entity.taxdeclaration.param.TaxDeclarationSaveParam;
|
||||||
import com.engine.salary.entity.taxdeclaration.po.TaxDeclarationPO;
|
import com.engine.salary.entity.taxdeclaration.po.TaxDeclarationPO;
|
||||||
|
|
@ -158,4 +159,20 @@ public class TaxDeclarationWrapper extends Service {
|
||||||
public void withDrawTaxDeclaration(Long taxDeclarationId) {
|
public void withDrawTaxDeclaration(Long taxDeclarationId) {
|
||||||
getTaxDeclarationService(user).withDrawTaxDeclaration(taxDeclarationId);
|
getTaxDeclarationService(user).withDrawTaxDeclaration(taxDeclarationId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void batSave(TaxDeclarationBatParam param) {
|
||||||
|
List<Long> taxAgentIds = param.getTaxAgentIds();
|
||||||
|
for (int i = 0; i < taxAgentIds.size(); i++) {
|
||||||
|
Long taxAgentId = taxAgentIds.get(i);
|
||||||
|
TaxDeclarationSaveParam saveParam = TaxDeclarationSaveParam.builder()
|
||||||
|
.salaryMonth(param.getSalaryMonth())
|
||||||
|
.taxAgentId(taxAgentId)
|
||||||
|
.description(param.getDescription())
|
||||||
|
.taxCycle(param.getTaxCycle())
|
||||||
|
.salaryDate(param.getSalaryDate())
|
||||||
|
.build();
|
||||||
|
save(saveParam);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue