删除接口
This commit is contained in:
parent
9c99e53288
commit
2e4c3ddaff
|
|
@ -5,6 +5,7 @@ import com.engine.salary.annotation.I18n;
|
|||
import com.engine.salary.annotation.TableTitle;
|
||||
import com.engine.salary.enums.datacollection.DataCollectionEmployeeTypeEnum;
|
||||
import com.engine.salary.util.excel.ExcelProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
|
|
@ -46,6 +47,7 @@ public class DerateDeductionListDTO {
|
|||
private Integer employeeType;
|
||||
|
||||
@TableTitle(title = "税款所属期", dataIndex = "taxYearMonth", key = "taxYearMonth")
|
||||
@JsonFormat(pattern = "yyyy-MM", timezone = "GMT+8")
|
||||
private Date taxYearMonth;
|
||||
|
||||
//姓名
|
||||
|
|
|
|||
|
|
@ -4,6 +4,7 @@ import com.engine.salary.annotation.I18n;
|
|||
import com.engine.salary.annotation.TableTitle;
|
||||
import com.engine.salary.enums.datacollection.DataCollectionEmployeeTypeEnum;
|
||||
import com.engine.salary.util.excel.ExcelProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
|
|
@ -45,6 +46,7 @@ public class EndowmentInsuranceListDTO {
|
|||
private Integer employeeType;
|
||||
|
||||
@TableTitle(title = "税款所属期", dataIndex = "taxYearMonth", key = "taxYearMonth")
|
||||
@JsonFormat(pattern = "yyyy-MM", timezone = "GMT+8")
|
||||
private Date taxYearMonth;
|
||||
|
||||
//姓名
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@ import com.engine.salary.annotation.I18n;
|
|||
import com.engine.salary.annotation.TableTitle;
|
||||
import com.engine.salary.enums.datacollection.DataCollectionEmployeeTypeEnum;
|
||||
import com.engine.salary.util.excel.ExcelProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
|
|
@ -46,6 +47,7 @@ public class FreeIncomeListDTO {
|
|||
private Integer employeeType;
|
||||
|
||||
@TableTitle(title = "税款所属期", dataIndex = "taxYearMonth", key = "taxYearMonth")
|
||||
@JsonFormat(pattern = "yyyy-MM", timezone = "GMT+8")
|
||||
private Date taxYearMonth;
|
||||
|
||||
//姓名
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@ import com.engine.salary.annotation.SalaryTableColumn;
|
|||
import com.engine.salary.annotation.TableTitle;
|
||||
import com.engine.salary.enums.datacollection.DataCollectionEmployeeTypeEnum;
|
||||
import com.engine.salary.util.excel.ExcelProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
|
|
@ -41,6 +42,7 @@ public class GrantDonationListDTO {
|
|||
private Integer employeeType;
|
||||
|
||||
@TableTitle(title = "税款所属期", dataIndex = "taxYearMonth", key = "taxYearMonth")
|
||||
@JsonFormat(pattern = "yyyy-MM", timezone = "GMT+8")
|
||||
private Date taxYearMonth;
|
||||
|
||||
//姓名
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@ import com.engine.salary.annotation.SalaryTableColumn;
|
|||
import com.engine.salary.annotation.TableTitle;
|
||||
import com.engine.salary.enums.datacollection.DataCollectionEmployeeTypeEnum;
|
||||
import com.engine.salary.util.excel.ExcelProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
|
|
@ -42,6 +43,7 @@ public class HealthInsuranceListDTO {
|
|||
private Integer employeeType;
|
||||
|
||||
@TableTitle(title = "税款所属期", dataIndex = "taxYearMonth", key = "taxYearMonth")
|
||||
@JsonFormat(pattern = "yyyy-MM", timezone = "GMT+8")
|
||||
private Date taxYearMonth;
|
||||
|
||||
//姓名
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@ import com.engine.salary.annotation.SalaryTableColumn;
|
|||
import com.engine.salary.annotation.TableTitle;
|
||||
import com.engine.salary.enums.datacollection.DataCollectionEmployeeTypeEnum;
|
||||
import com.engine.salary.util.excel.ExcelProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
|
|
@ -42,6 +43,7 @@ public class OtherDerateDeductionListDTO {
|
|||
private Integer employeeType;
|
||||
|
||||
@TableTitle(title = "税款所属期", dataIndex = "taxYearMonth", key = "taxYearMonth")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
private Date taxYearMonth;
|
||||
|
||||
//姓名
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@ import com.engine.salary.annotation.TableTitle;
|
|||
import com.engine.salary.enums.datacollection.DataCollectionEmployeeTypeEnum;
|
||||
import com.engine.salary.enums.datacollection.EnumDeductionDataSource;
|
||||
import com.engine.salary.util.excel.ExcelProperty;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Builder;
|
||||
import lombok.Data;
|
||||
|
|
@ -47,6 +48,7 @@ public class PersonalPensionListDTO {
|
|||
private Integer employeeType;
|
||||
|
||||
@TableTitle(title = "税款所属期", dataIndex = "taxYearMonth", key = "taxYearMonth")
|
||||
@JsonFormat(pattern = "yyyy-MM", timezone = "GMT+8")
|
||||
private Date taxYearMonth;
|
||||
|
||||
//姓名
|
||||
|
|
|
|||
|
|
@ -0,0 +1,26 @@
|
|||
package com.engine.salary.entity.datacollection.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 OtherDeductionDetailDeleteParam {
|
||||
|
||||
// 主键id
|
||||
private List<Long> ids;
|
||||
}
|
||||
|
|
@ -125,17 +125,13 @@ public interface OtherDeductionService {
|
|||
String extendToLastMonth(OtherDeductionExtendLastParam param);
|
||||
|
||||
PageInfo<FreeIncomeListDTO> freeIncomeList(OtherDeductionDetailQueryParam param);
|
||||
PageInfo<DerateDeductionListDTO> derateDeductionListDTOList(OtherDeductionDetailQueryParam param);
|
||||
PageInfo<EndowmentInsuranceListDTO> endowmentInsuranceListDTOList(OtherDeductionDetailQueryParam param);
|
||||
PageInfo<GrantDonationListDTO> grantDonationListDTOList(OtherDeductionDetailQueryParam param);
|
||||
PageInfo<HealthInsuranceListDTO> healthInsuranceListDTOList(OtherDeductionDetailQueryParam param);
|
||||
PageInfo<OtherDerateDeductionListDTO> otherDerateDeductionListDTOList(OtherDeductionDetailQueryParam param);
|
||||
PageInfo<PersonalPensionListDTO> personalPensionListDTOList(OtherDeductionDetailQueryParam param);
|
||||
PageInfo<DerateDeductionListDTO> derateDeductionList(OtherDeductionDetailQueryParam param);
|
||||
PageInfo<EndowmentInsuranceListDTO> endowmentInsuranceList(OtherDeductionDetailQueryParam param);
|
||||
PageInfo<GrantDonationListDTO> grantDonationList(OtherDeductionDetailQueryParam param);
|
||||
PageInfo<HealthInsuranceListDTO> healthInsuranceList(OtherDeductionDetailQueryParam param);
|
||||
PageInfo<OtherDerateDeductionListDTO> otherDerateDeductionList(OtherDeductionDetailQueryParam param);
|
||||
PageInfo<PersonalPensionListDTO> personalPensionList(OtherDeductionDetailQueryParam param);
|
||||
|
||||
/**
|
||||
* 保存免税收入
|
||||
* @param param
|
||||
*/
|
||||
void saveFreeIncome(FreeIncomeSaveParam param);
|
||||
void saveEndowmentInsurance(EndowmentInsuranceSaveParam param);
|
||||
void saveGrantDonation(GrantDonationSaveParam param);
|
||||
|
|
@ -144,5 +140,12 @@ public interface OtherDeductionService {
|
|||
void saveDerateDeduction(DerateDeductionSaveParam param);
|
||||
void savePersonalPension(PersonalPensionSaveParam param);
|
||||
|
||||
void deleteFreeIncome(OtherDeductionDetailDeleteParam param);
|
||||
void deleteEndowmentInsurance(OtherDeductionDetailDeleteParam param);
|
||||
void deleteGrantDonation(OtherDeductionDetailDeleteParam param);
|
||||
void deleteHealthInsurance(OtherDeductionDetailDeleteParam param);
|
||||
void deleteOtherDerateDeduction(OtherDeductionDetailDeleteParam param);
|
||||
void deleteDerateDeduction(OtherDeductionDetailDeleteParam param);
|
||||
void deletePersonalPension(OtherDeductionDetailDeleteParam param);
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -36,6 +36,7 @@ import com.engine.salary.sys.service.impl.SalarySysConfServiceImpl;
|
|||
import com.engine.salary.util.SalaryDateUtil;
|
||||
import com.engine.salary.util.SalaryEntityUtil;
|
||||
import com.engine.salary.util.SalaryI18nUtil;
|
||||
import com.engine.salary.util.db.IdGenerator;
|
||||
import com.engine.salary.util.db.MapperProxyFactory;
|
||||
import com.engine.salary.util.excel.ExcelComment;
|
||||
import com.engine.salary.util.excel.ExcelParseHelper;
|
||||
|
|
@ -2181,77 +2182,168 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
|||
@Override
|
||||
public PageInfo<FreeIncomeListDTO> freeIncomeList(OtherDeductionDetailQueryParam param) {
|
||||
|
||||
List<FreeIncomePO> freeIncomePOS = getFreeIncomeMapper().listSome(FreeIncomePO.builder().mainId(param.getId()).build());
|
||||
List<FreeIncomeListDTO> listDTOS = freeIncomePOS.stream().map(po -> {
|
||||
FreeIncomeListDTO freeIncomeListDTO = new FreeIncomeListDTO();
|
||||
BeanUtils.copyProperties(po, freeIncomeListDTO);
|
||||
return freeIncomeListDTO;
|
||||
List<FreeIncomePO> pos = getFreeIncomeMapper().listSome(FreeIncomePO.builder().mainId(param.getId()).build());
|
||||
List<Long> empIds = SalaryEntityUtil.properties(pos, FreeIncomePO::getEmployeeId, Collectors.toList());
|
||||
List<DataCollectionEmployee> employeeList = getSalaryEmployeeService(user).listByIds(empIds);
|
||||
Map<Long, DataCollectionEmployee> employeeMap = SalaryEntityUtil.convert2Map(employeeList, DataCollectionEmployee::getEmployeeId);
|
||||
List<TaxAgentPO> taxAgentPOS = getTaxAgentService(user).listAll();
|
||||
Map<Long, TaxAgentPO> taxAgentMap = SalaryEntityUtil.convert2Map(taxAgentPOS, TaxAgentPO::getId);
|
||||
List<FreeIncomeListDTO> listDTOS = pos.stream().map(po -> {
|
||||
FreeIncomeListDTO dto = new FreeIncomeListDTO();
|
||||
BeanUtils.copyProperties(po, dto);
|
||||
DataCollectionEmployee employee = employeeMap.getOrDefault(po.getEmployeeId(), new DataCollectionEmployee());
|
||||
TaxAgentPO taxAgent = taxAgentMap.getOrDefault(po.getTaxAgentId(), new TaxAgentPO());
|
||||
dto.setUsername(employee.getUsername());
|
||||
dto.setTaxAgentName(taxAgent.getName());
|
||||
dto.setDepartmentName(employee.getDepartmentName());
|
||||
dto.setMobile(employee.getMobile());
|
||||
dto.setJobNum(employee.getWorkcode());
|
||||
dto.setIdNo(employee.getIdNo());
|
||||
return dto;
|
||||
}).collect(Collectors.toList());
|
||||
return SalaryPageUtil.buildPage(param.getCurrent(), param.getPageSize(), listDTOS, FreeIncomeListDTO.class);
|
||||
}
|
||||
|
||||
@Override
|
||||
public PageInfo<DerateDeductionListDTO> derateDeductionListDTOList(OtherDeductionDetailQueryParam param) {
|
||||
public PageInfo<DerateDeductionListDTO> derateDeductionList(OtherDeductionDetailQueryParam param) {
|
||||
List<DerateDeductionPO> pos = getDerateDeductionMapper().listSome(DerateDeductionPO.builder().mainId(param.getId()).build());
|
||||
List<Long> empIds = SalaryEntityUtil.properties(pos, DerateDeductionPO::getEmployeeId, Collectors.toList());
|
||||
List<DataCollectionEmployee> employeeList = getSalaryEmployeeService(user).listByIds(empIds);
|
||||
Map<Long, DataCollectionEmployee> employeeMap = SalaryEntityUtil.convert2Map(employeeList, DataCollectionEmployee::getEmployeeId);
|
||||
List<TaxAgentPO> taxAgentPOS = getTaxAgentService(user).listAll();
|
||||
Map<Long, TaxAgentPO> taxAgentMap = SalaryEntityUtil.convert2Map(taxAgentPOS, TaxAgentPO::getId);
|
||||
List<DerateDeductionListDTO> listDTOS = pos.stream().map(po -> {
|
||||
DerateDeductionListDTO dtos = new DerateDeductionListDTO();
|
||||
BeanUtils.copyProperties(po, dtos);
|
||||
return dtos;
|
||||
DerateDeductionListDTO dto = new DerateDeductionListDTO();
|
||||
BeanUtils.copyProperties(po, dto);
|
||||
DataCollectionEmployee employee = employeeMap.getOrDefault(po.getEmployeeId(), new DataCollectionEmployee());
|
||||
TaxAgentPO taxAgent = taxAgentMap.getOrDefault(po.getTaxAgentId(), new TaxAgentPO());
|
||||
dto.setUsername(employee.getUsername());
|
||||
dto.setTaxAgentName(taxAgent.getName());
|
||||
dto.setDepartmentName(employee.getDepartmentName());
|
||||
dto.setMobile(employee.getMobile());
|
||||
dto.setJobNum(employee.getWorkcode());
|
||||
dto.setIdNo(employee.getIdNo());
|
||||
return dto;
|
||||
}).collect(Collectors.toList());
|
||||
return SalaryPageUtil.buildPage(param.getCurrent(), param.getPageSize(), listDTOS, DerateDeductionListDTO.class);
|
||||
}
|
||||
|
||||
@Override
|
||||
public PageInfo<EndowmentInsuranceListDTO> endowmentInsuranceListDTOList(OtherDeductionDetailQueryParam param) {
|
||||
public PageInfo<EndowmentInsuranceListDTO> endowmentInsuranceList(OtherDeductionDetailQueryParam param) {
|
||||
List<EndowmentInsurancePO> pos = getEndowmentInsuranceMapper().listSome(EndowmentInsurancePO.builder().mainId(param.getId()).build());
|
||||
List<Long> empIds = SalaryEntityUtil.properties(pos, EndowmentInsurancePO::getEmployeeId, Collectors.toList());
|
||||
List<DataCollectionEmployee> employeeList = getSalaryEmployeeService(user).listByIds(empIds);
|
||||
Map<Long, DataCollectionEmployee> employeeMap = SalaryEntityUtil.convert2Map(employeeList, DataCollectionEmployee::getEmployeeId);
|
||||
List<TaxAgentPO> taxAgentPOS = getTaxAgentService(user).listAll();
|
||||
Map<Long, TaxAgentPO> taxAgentMap = SalaryEntityUtil.convert2Map(taxAgentPOS, TaxAgentPO::getId);
|
||||
List<EndowmentInsuranceListDTO> listDTOS = pos.stream().map(po -> {
|
||||
EndowmentInsuranceListDTO dtos = new EndowmentInsuranceListDTO();
|
||||
BeanUtils.copyProperties(po, dtos);
|
||||
return dtos;
|
||||
EndowmentInsuranceListDTO dto = new EndowmentInsuranceListDTO();
|
||||
BeanUtils.copyProperties(po, dto);
|
||||
DataCollectionEmployee employee = employeeMap.getOrDefault(po.getEmployeeId(), new DataCollectionEmployee());
|
||||
TaxAgentPO taxAgent = taxAgentMap.getOrDefault(po.getTaxAgentId(), new TaxAgentPO());
|
||||
dto.setUsername(employee.getUsername());
|
||||
dto.setTaxAgentName(taxAgent.getName());
|
||||
dto.setDepartmentName(employee.getDepartmentName());
|
||||
dto.setMobile(employee.getMobile());
|
||||
dto.setJobNum(employee.getWorkcode());
|
||||
dto.setIdNo(employee.getIdNo());
|
||||
return dto;
|
||||
}).collect(Collectors.toList());
|
||||
return SalaryPageUtil.buildPage(param.getCurrent(), param.getPageSize(), listDTOS, EndowmentInsuranceListDTO.class);
|
||||
}
|
||||
|
||||
@Override
|
||||
public PageInfo<GrantDonationListDTO> grantDonationListDTOList(OtherDeductionDetailQueryParam param) {
|
||||
public PageInfo<GrantDonationListDTO> grantDonationList(OtherDeductionDetailQueryParam param) {
|
||||
List<GrantDonationPO> pos = getGrantDonationMapper().listSome(GrantDonationPO.builder().mainId(param.getId()).build());
|
||||
List<Long> empIds = SalaryEntityUtil.properties(pos, GrantDonationPO::getEmployeeId, Collectors.toList());
|
||||
List<DataCollectionEmployee> employeeList = getSalaryEmployeeService(user).listByIds(empIds);
|
||||
Map<Long, DataCollectionEmployee> employeeMap = SalaryEntityUtil.convert2Map(employeeList, DataCollectionEmployee::getEmployeeId);
|
||||
List<TaxAgentPO> taxAgentPOS = getTaxAgentService(user).listAll();
|
||||
Map<Long, TaxAgentPO> taxAgentMap = SalaryEntityUtil.convert2Map(taxAgentPOS, TaxAgentPO::getId);
|
||||
List<GrantDonationListDTO> listDTOS = pos.stream().map(po -> {
|
||||
GrantDonationListDTO dtos = new GrantDonationListDTO();
|
||||
BeanUtils.copyProperties(po, dtos);
|
||||
return dtos;
|
||||
GrantDonationListDTO dto = new GrantDonationListDTO();
|
||||
BeanUtils.copyProperties(po, dto);
|
||||
DataCollectionEmployee employee = employeeMap.getOrDefault(po.getEmployeeId(), new DataCollectionEmployee());
|
||||
TaxAgentPO taxAgent = taxAgentMap.getOrDefault(po.getTaxAgentId(), new TaxAgentPO());
|
||||
dto.setUsername(employee.getUsername());
|
||||
dto.setTaxAgentName(taxAgent.getName());
|
||||
dto.setDepartmentName(employee.getDepartmentName());
|
||||
dto.setMobile(employee.getMobile());
|
||||
dto.setJobNum(employee.getWorkcode());
|
||||
dto.setIdNo(employee.getIdNo());
|
||||
return dto;
|
||||
}).collect(Collectors.toList());
|
||||
return SalaryPageUtil.buildPage(param.getCurrent(), param.getPageSize(), listDTOS, GrantDonationListDTO.class);
|
||||
}
|
||||
|
||||
@Override
|
||||
public PageInfo<HealthInsuranceListDTO> healthInsuranceListDTOList(OtherDeductionDetailQueryParam param) {
|
||||
public PageInfo<HealthInsuranceListDTO> healthInsuranceList(OtherDeductionDetailQueryParam param) {
|
||||
List<HealthInsurancePO> pos = getHealthInsuranceMapper().listSome(HealthInsurancePO.builder().mainId(param.getId()).build());
|
||||
List<Long> empIds = SalaryEntityUtil.properties(pos, HealthInsurancePO::getEmployeeId, Collectors.toList());
|
||||
List<DataCollectionEmployee> employeeList = getSalaryEmployeeService(user).listByIds(empIds);
|
||||
Map<Long, DataCollectionEmployee> employeeMap = SalaryEntityUtil.convert2Map(employeeList, DataCollectionEmployee::getEmployeeId);
|
||||
List<TaxAgentPO> taxAgentPOS = getTaxAgentService(user).listAll();
|
||||
Map<Long, TaxAgentPO> taxAgentMap = SalaryEntityUtil.convert2Map(taxAgentPOS, TaxAgentPO::getId);
|
||||
List<HealthInsuranceListDTO> listDTOS = pos.stream().map(po -> {
|
||||
HealthInsuranceListDTO dtos = new HealthInsuranceListDTO();
|
||||
BeanUtils.copyProperties(po, dtos);
|
||||
return dtos;
|
||||
HealthInsuranceListDTO dto = new HealthInsuranceListDTO();
|
||||
BeanUtils.copyProperties(po, dto);
|
||||
DataCollectionEmployee employee = employeeMap.getOrDefault(po.getEmployeeId(), new DataCollectionEmployee());
|
||||
TaxAgentPO taxAgent = taxAgentMap.getOrDefault(po.getTaxAgentId(), new TaxAgentPO());
|
||||
dto.setUsername(employee.getUsername());
|
||||
dto.setTaxAgentName(taxAgent.getName());
|
||||
dto.setDepartmentName(employee.getDepartmentName());
|
||||
dto.setMobile(employee.getMobile());
|
||||
dto.setJobNum(employee.getWorkcode());
|
||||
dto.setIdNo(employee.getIdNo());
|
||||
return dto;
|
||||
}).collect(Collectors.toList());
|
||||
return SalaryPageUtil.buildPage(param.getCurrent(), param.getPageSize(), listDTOS, HealthInsuranceListDTO.class);
|
||||
}
|
||||
|
||||
@Override
|
||||
public PageInfo<OtherDerateDeductionListDTO> otherDerateDeductionListDTOList(OtherDeductionDetailQueryParam param) {
|
||||
public PageInfo<OtherDerateDeductionListDTO> otherDerateDeductionList(OtherDeductionDetailQueryParam param) {
|
||||
List<OtherDerateDeductionPO> pos = getOtherDerateDeductionMapper().listSome(OtherDerateDeductionPO.builder().mainId(param.getId()).build());
|
||||
List<Long> empIds = SalaryEntityUtil.properties(pos, OtherDerateDeductionPO::getEmployeeId, Collectors.toList());
|
||||
List<DataCollectionEmployee> employeeList = getSalaryEmployeeService(user).listByIds(empIds);
|
||||
Map<Long, DataCollectionEmployee> employeeMap = SalaryEntityUtil.convert2Map(employeeList, DataCollectionEmployee::getEmployeeId);
|
||||
List<TaxAgentPO> taxAgentPOS = getTaxAgentService(user).listAll();
|
||||
Map<Long, TaxAgentPO> taxAgentMap = SalaryEntityUtil.convert2Map(taxAgentPOS, TaxAgentPO::getId);
|
||||
List<OtherDerateDeductionListDTO> listDTOS = pos.stream().map(po -> {
|
||||
OtherDerateDeductionListDTO dtos = new OtherDerateDeductionListDTO();
|
||||
BeanUtils.copyProperties(po, dtos);
|
||||
return dtos;
|
||||
OtherDerateDeductionListDTO dto = new OtherDerateDeductionListDTO();
|
||||
BeanUtils.copyProperties(po, dto);
|
||||
DataCollectionEmployee employee = employeeMap.getOrDefault(po.getEmployeeId(), new DataCollectionEmployee());
|
||||
TaxAgentPO taxAgent = taxAgentMap.getOrDefault(po.getTaxAgentId(), new TaxAgentPO());
|
||||
dto.setUsername(employee.getUsername());
|
||||
dto.setTaxAgentName(taxAgent.getName());
|
||||
dto.setDepartmentName(employee.getDepartmentName());
|
||||
dto.setMobile(employee.getMobile());
|
||||
dto.setJobNum(employee.getWorkcode());
|
||||
dto.setIdNo(employee.getIdNo());
|
||||
return dto;
|
||||
}).collect(Collectors.toList());
|
||||
return SalaryPageUtil.buildPage(param.getCurrent(), param.getPageSize(), listDTOS, OtherDerateDeductionListDTO.class);
|
||||
}
|
||||
|
||||
@Override
|
||||
public PageInfo<PersonalPensionListDTO> personalPensionListDTOList(OtherDeductionDetailQueryParam param) {
|
||||
List<FreeIncomePO> pos = getFreeIncomeMapper().listSome(FreeIncomePO.builder().mainId(param.getId()).build());
|
||||
public PageInfo<PersonalPensionListDTO> personalPensionList(OtherDeductionDetailQueryParam param) {
|
||||
List<PersonalPensionPO> pos = getPersonalPensionMapper().listSome(PersonalPensionPO.builder().mainId(param.getId()).build());
|
||||
List<Long> empIds = SalaryEntityUtil.properties(pos, PersonalPensionPO::getEmployeeId, Collectors.toList());
|
||||
List<DataCollectionEmployee> employeeList = getSalaryEmployeeService(user).listByIds(empIds);
|
||||
Map<Long, DataCollectionEmployee> employeeMap = SalaryEntityUtil.convert2Map(employeeList, DataCollectionEmployee::getEmployeeId);
|
||||
List<TaxAgentPO> taxAgentPOS = getTaxAgentService(user).listAll();
|
||||
Map<Long, TaxAgentPO> taxAgentMap = SalaryEntityUtil.convert2Map(taxAgentPOS, TaxAgentPO::getId);
|
||||
List<PersonalPensionListDTO> listDTOS = pos.stream().map(po -> {
|
||||
PersonalPensionListDTO dtos = new PersonalPensionListDTO();
|
||||
BeanUtils.copyProperties(po, dtos);
|
||||
return dtos;
|
||||
PersonalPensionListDTO dto = new PersonalPensionListDTO();
|
||||
BeanUtils.copyProperties(po, dto);
|
||||
DataCollectionEmployee employee = employeeMap.getOrDefault(po.getEmployeeId(), new DataCollectionEmployee());
|
||||
TaxAgentPO taxAgent = taxAgentMap.getOrDefault(po.getTaxAgentId(), new TaxAgentPO());
|
||||
dto.setUsername(employee.getUsername());
|
||||
dto.setTaxAgentName(taxAgent.getName());
|
||||
dto.setDepartmentName(employee.getDepartmentName());
|
||||
dto.setMobile(employee.getMobile());
|
||||
dto.setJobNum(employee.getWorkcode());
|
||||
dto.setIdNo(employee.getIdNo());
|
||||
return dto;
|
||||
}).collect(Collectors.toList());
|
||||
return SalaryPageUtil.buildPage(param.getCurrent(), param.getPageSize(), listDTOS, PersonalPensionListDTO.class);
|
||||
}
|
||||
|
|
@ -2270,7 +2362,7 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
|||
Long id = param.getId();
|
||||
if (id == null) {
|
||||
FreeIncomePO po = FreeIncomePO.builder()
|
||||
.id(id)
|
||||
.id(IdGenerator.generate())
|
||||
.mainId(mainId)
|
||||
.taxYearMonth(deductionPO.getDeclareMonth())
|
||||
.employeeId(deductionPO.getEmployeeId())
|
||||
|
|
@ -2289,7 +2381,7 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
|||
getFreeIncomeMapper().insertIgnoreNull(po);
|
||||
} else {
|
||||
FreeIncomePO po = getFreeIncomeMapper().getById(id);
|
||||
if (po == null){
|
||||
if (po == null) {
|
||||
throw new SalaryRunTimeException("记录不存在!");
|
||||
}
|
||||
|
||||
|
|
@ -2315,7 +2407,7 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
|||
Long id = param.getId();
|
||||
if (id == null) {
|
||||
EndowmentInsurancePO po = EndowmentInsurancePO.builder()
|
||||
.id(id)
|
||||
.id(IdGenerator.generate())
|
||||
.mainId(mainId)
|
||||
.taxYearMonth(deductionPO.getDeclareMonth())
|
||||
.employeeId(deductionPO.getEmployeeId())
|
||||
|
|
@ -2336,7 +2428,7 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
|||
getEndowmentInsuranceMapper().insertIgnoreNull(po);
|
||||
} else {
|
||||
EndowmentInsurancePO po = getEndowmentInsuranceMapper().getById(id);
|
||||
if (po == null){
|
||||
if (po == null) {
|
||||
throw new SalaryRunTimeException("记录不存在!");
|
||||
}
|
||||
|
||||
|
|
@ -2364,7 +2456,7 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
|||
Long id = param.getId();
|
||||
if (id == null) {
|
||||
GrantDonationPO po = GrantDonationPO.builder()
|
||||
.id(id)
|
||||
.id(IdGenerator.generate())
|
||||
.mainId(mainId)
|
||||
.taxYearMonth(deductionPO.getDeclareMonth())
|
||||
.employeeId(deductionPO.getEmployeeId())
|
||||
|
|
@ -2387,7 +2479,7 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
|||
getGrantDonationMapper().insertIgnoreNull(po);
|
||||
} else {
|
||||
GrantDonationPO po = getGrantDonationMapper().getById(id);
|
||||
if (po == null){
|
||||
if (po == null) {
|
||||
throw new SalaryRunTimeException("记录不存在!");
|
||||
}
|
||||
|
||||
|
|
@ -2417,7 +2509,7 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
|||
Long id = param.getId();
|
||||
if (id == null) {
|
||||
HealthInsurancePO po = HealthInsurancePO.builder()
|
||||
.id(id)
|
||||
.id(IdGenerator.generate())
|
||||
.mainId(mainId)
|
||||
.taxYearMonth(deductionPO.getDeclareMonth())
|
||||
.employeeId(deductionPO.getEmployeeId())
|
||||
|
|
@ -2438,7 +2530,7 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
|||
getHealthInsuranceMapper().insertIgnoreNull(po);
|
||||
} else {
|
||||
HealthInsurancePO po = getHealthInsuranceMapper().getById(id);
|
||||
if (po == null){
|
||||
if (po == null) {
|
||||
throw new SalaryRunTimeException("记录不存在!");
|
||||
}
|
||||
|
||||
|
|
@ -2466,7 +2558,7 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
|||
Long id = param.getId();
|
||||
if (id == null) {
|
||||
OtherDerateDeductionPO po = OtherDerateDeductionPO.builder()
|
||||
.id(id)
|
||||
.id(IdGenerator.generate())
|
||||
.mainId(mainId)
|
||||
.taxYearMonth(deductionPO.getDeclareMonth())
|
||||
.employeeId(deductionPO.getEmployeeId())
|
||||
|
|
@ -2484,7 +2576,7 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
|||
getOtherDerateDeductionMapper().insertIgnoreNull(po);
|
||||
} else {
|
||||
OtherDerateDeductionPO po = getOtherDerateDeductionMapper().getById(id);
|
||||
if (po == null){
|
||||
if (po == null) {
|
||||
throw new SalaryRunTimeException("记录不存在!");
|
||||
}
|
||||
|
||||
|
|
@ -2509,7 +2601,7 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
|||
Long id = param.getId();
|
||||
if (id == null) {
|
||||
DerateDeductionPO po = DerateDeductionPO.builder()
|
||||
.id(id)
|
||||
.id(IdGenerator.generate())
|
||||
.mainId(mainId)
|
||||
.taxYearMonth(deductionPO.getDeclareMonth())
|
||||
.employeeId(deductionPO.getEmployeeId())
|
||||
|
|
@ -2528,7 +2620,7 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
|||
getDerateDeductionMapper().insertIgnoreNull(po);
|
||||
} else {
|
||||
DerateDeductionPO po = getDerateDeductionMapper().getById(id);
|
||||
if (po == null){
|
||||
if (po == null) {
|
||||
throw new SalaryRunTimeException("记录不存在!");
|
||||
}
|
||||
|
||||
|
|
@ -2554,7 +2646,7 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
|||
Long id = param.getId();
|
||||
if (id == null) {
|
||||
PersonalPensionPO po = PersonalPensionPO.builder()
|
||||
.id(id)
|
||||
.id(IdGenerator.generate())
|
||||
.mainId(mainId)
|
||||
.taxYearMonth(deductionPO.getDeclareMonth())
|
||||
.employeeId(deductionPO.getEmployeeId())
|
||||
|
|
@ -2573,7 +2665,7 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
|||
getPersonalPensionMapper().insertIgnoreNull(po);
|
||||
} else {
|
||||
PersonalPensionPO po = getPersonalPensionMapper().getById(id);
|
||||
if (po == null){
|
||||
if (po == null) {
|
||||
throw new SalaryRunTimeException("记录不存在!");
|
||||
}
|
||||
|
||||
|
|
@ -2586,4 +2678,39 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
|||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void deleteFreeIncome(OtherDeductionDetailDeleteParam param) {
|
||||
getFreeIncomeMapper().deleteByIds(param.getIds());
|
||||
}
|
||||
|
||||
@Override
|
||||
public void deleteEndowmentInsurance(OtherDeductionDetailDeleteParam param) {
|
||||
getEndowmentInsuranceMapper().deleteByIds(param.getIds());
|
||||
}
|
||||
|
||||
@Override
|
||||
public void deleteGrantDonation(OtherDeductionDetailDeleteParam param) {
|
||||
getGrantDonationMapper().deleteByIds(param.getIds());
|
||||
}
|
||||
|
||||
@Override
|
||||
public void deleteHealthInsurance(OtherDeductionDetailDeleteParam param) {
|
||||
getHealthInsuranceMapper().deleteByIds(param.getIds());
|
||||
}
|
||||
|
||||
@Override
|
||||
public void deleteOtherDerateDeduction(OtherDeductionDetailDeleteParam param) {
|
||||
getOtherDerateDeductionMapper().deleteByIds(param.getIds());
|
||||
}
|
||||
|
||||
@Override
|
||||
public void deleteDerateDeduction(OtherDeductionDetailDeleteParam param) {
|
||||
getDerateDeductionMapper().deleteByIds(param.getIds());
|
||||
}
|
||||
|
||||
@Override
|
||||
public void deletePersonalPension(OtherDeductionDetailDeleteParam param) {
|
||||
getPersonalPensionMapper().deleteByIds(param.getIds());
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,9 +1,7 @@
|
|||
package com.engine.salary.web;
|
||||
|
||||
import com.engine.common.util.ServiceUtil;
|
||||
import com.engine.salary.entity.datacollection.dto.FreeIncomeListDTO;
|
||||
import com.engine.salary.entity.datacollection.dto.OtherDeductionListDTO;
|
||||
import com.engine.salary.entity.datacollection.dto.OtherDeductionRecordDTO;
|
||||
import com.engine.salary.entity.datacollection.dto.*;
|
||||
import com.engine.salary.entity.datacollection.param.*;
|
||||
import com.engine.salary.util.ResponseResult;
|
||||
import com.engine.salary.util.SalaryDateUtil;
|
||||
|
|
@ -361,11 +359,64 @@ public class OtherDeductionController {
|
|||
@POST
|
||||
@Path("/freeIncomeList")
|
||||
@Produces(MediaType.APPLICATION_JSON)
|
||||
public String detailList(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody OtherDeductionDetailQueryParam param) {
|
||||
public String freeIncomeList(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody OtherDeductionDetailQueryParam param) {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
return new ResponseResult<OtherDeductionDetailQueryParam, PageInfo<FreeIncomeListDTO>>(user).run(getOtherDeductionWrapper(user)::freeIncomeList, param);
|
||||
}
|
||||
|
||||
|
||||
@POST
|
||||
@Path("/healthInsuranceList")
|
||||
@Produces(MediaType.APPLICATION_JSON)
|
||||
public String healthInsuranceList(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody OtherDeductionDetailQueryParam param) {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
return new ResponseResult<OtherDeductionDetailQueryParam, PageInfo<HealthInsuranceListDTO>>(user).run(getOtherDeductionWrapper(user)::healthInsuranceList, param);
|
||||
}
|
||||
|
||||
|
||||
@POST
|
||||
@Path("/endowmentInsuranceList")
|
||||
@Produces(MediaType.APPLICATION_JSON)
|
||||
public String endowmentInsuranceList(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody OtherDeductionDetailQueryParam param) {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
return new ResponseResult<OtherDeductionDetailQueryParam, PageInfo<EndowmentInsuranceListDTO>>(user).run(getOtherDeductionWrapper(user)::endowmentInsuranceList, param);
|
||||
}
|
||||
|
||||
@POST
|
||||
@Path("/grantDonationList")
|
||||
@Produces(MediaType.APPLICATION_JSON)
|
||||
public String grantDonationList(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody OtherDeductionDetailQueryParam param) {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
return new ResponseResult<OtherDeductionDetailQueryParam, PageInfo<GrantDonationListDTO>>(user).run(getOtherDeductionWrapper(user)::grantDonationList, param);
|
||||
}
|
||||
|
||||
|
||||
@POST
|
||||
@Path("/derateDeductionList")
|
||||
@Produces(MediaType.APPLICATION_JSON)
|
||||
public String derateDeductionList(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody OtherDeductionDetailQueryParam param) {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
return new ResponseResult<OtherDeductionDetailQueryParam, PageInfo<DerateDeductionListDTO>>(user).run(getOtherDeductionWrapper(user)::derateDeductionList, param);
|
||||
}
|
||||
|
||||
|
||||
@POST
|
||||
@Path("/otherDerateDeductionList")
|
||||
@Produces(MediaType.APPLICATION_JSON)
|
||||
public String otherDerateDeductionList(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody OtherDeductionDetailQueryParam param) {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
return new ResponseResult<OtherDeductionDetailQueryParam, PageInfo<OtherDerateDeductionListDTO>>(user).run(getOtherDeductionWrapper(user)::otherDerateDeductionList, param);
|
||||
}
|
||||
|
||||
@POST
|
||||
@Path("/personalPensionList")
|
||||
@Produces(MediaType.APPLICATION_JSON)
|
||||
public String personalPensionList(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody OtherDeductionDetailQueryParam param) {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
return new ResponseResult<OtherDeductionDetailQueryParam, PageInfo<PersonalPensionListDTO>>(user).run(getOtherDeductionWrapper(user)::personalPensionList, param);
|
||||
}
|
||||
|
||||
|
||||
@POST
|
||||
@Path("/saveFreeIncome")
|
||||
@Produces(MediaType.APPLICATION_JSON)
|
||||
|
|
@ -374,5 +425,116 @@ public class OtherDeductionController {
|
|||
return new ResponseResult<FreeIncomeSaveParam, String>(user).run(getOtherDeductionWrapper(user)::saveFreeIncome, param);
|
||||
}
|
||||
|
||||
@POST
|
||||
@Path("/saveHealthInsurance")
|
||||
@Produces(MediaType.APPLICATION_JSON)
|
||||
public String saveHealthInsurance(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody HealthInsuranceSaveParam param) {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
return new ResponseResult<HealthInsuranceSaveParam, String>(user).run(getOtherDeductionWrapper(user)::saveHealthInsurance, param);
|
||||
}
|
||||
|
||||
|
||||
@POST
|
||||
@Path("/saveEndowmentInsurance")
|
||||
@Produces(MediaType.APPLICATION_JSON)
|
||||
public String saveEndowmentInsurance(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody EndowmentInsuranceSaveParam param) {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
return new ResponseResult<EndowmentInsuranceSaveParam, String>(user).run(getOtherDeductionWrapper(user)::saveEndowmentInsurance, param);
|
||||
}
|
||||
|
||||
@POST
|
||||
@Path("/saveGrantDonation")
|
||||
@Produces(MediaType.APPLICATION_JSON)
|
||||
public String saveGrantDonation(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody GrantDonationSaveParam param) {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
return new ResponseResult<GrantDonationSaveParam, String>(user).run(getOtherDeductionWrapper(user)::saveGrantDonation, param);
|
||||
}
|
||||
|
||||
@POST
|
||||
@Path("/saveDerateDeduction")
|
||||
@Produces(MediaType.APPLICATION_JSON)
|
||||
public String saveDerateDeduction(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody DerateDeductionSaveParam param) {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
return new ResponseResult<DerateDeductionSaveParam, String>(user).run(getOtherDeductionWrapper(user)::saveDerateDeduction, param);
|
||||
}
|
||||
|
||||
|
||||
@POST
|
||||
@Path("/saveOtherDerateDeduction")
|
||||
@Produces(MediaType.APPLICATION_JSON)
|
||||
public String saveOtherDerateDeduction(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody OtherDerateDeductionSaveParam param) {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
return new ResponseResult<OtherDerateDeductionSaveParam, String>(user).run(getOtherDeductionWrapper(user)::saveOtherDerateDeduction, param);
|
||||
}
|
||||
|
||||
@POST
|
||||
@Path("/savePersonalPension")
|
||||
@Produces(MediaType.APPLICATION_JSON)
|
||||
public String savePersonalPension(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody PersonalPensionSaveParam param) {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
return new ResponseResult<PersonalPensionSaveParam, String>(user).run(getOtherDeductionWrapper(user)::savePersonalPension, param);
|
||||
}
|
||||
|
||||
|
||||
@POST
|
||||
@Path("/deleteFreeIncome")
|
||||
@Produces(MediaType.APPLICATION_JSON)
|
||||
public String deleteFreeIncome(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody OtherDeductionDetailDeleteParam param) {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
return new ResponseResult<OtherDeductionDetailDeleteParam, String>(user).run(getOtherDeductionWrapper(user)::deleteFreeIncome, param);
|
||||
}
|
||||
|
||||
@POST
|
||||
@Path("/deleteHealthInsurance")
|
||||
@Produces(MediaType.APPLICATION_JSON)
|
||||
public String deleteHealthInsurance(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody OtherDeductionDetailDeleteParam param) {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
return new ResponseResult<OtherDeductionDetailDeleteParam, String>(user).run(getOtherDeductionWrapper(user)::deleteHealthInsurance, param);
|
||||
}
|
||||
|
||||
|
||||
@POST
|
||||
@Path("/deleteEndowmentInsurance")
|
||||
@Produces(MediaType.APPLICATION_JSON)
|
||||
public String deleteEndowmentInsurance(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody OtherDeductionDetailDeleteParam param) {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
return new ResponseResult<OtherDeductionDetailDeleteParam, String>(user).run(getOtherDeductionWrapper(user)::deleteEndowmentInsurance, param);
|
||||
}
|
||||
|
||||
@POST
|
||||
@Path("/deleteGrantDonation")
|
||||
@Produces(MediaType.APPLICATION_JSON)
|
||||
public String deleteGrantDonation(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody OtherDeductionDetailDeleteParam param) {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
return new ResponseResult<OtherDeductionDetailDeleteParam, String>(user).run(getOtherDeductionWrapper(user)::deleteGrantDonation, param);
|
||||
}
|
||||
|
||||
@POST
|
||||
@Path("/deleteDerateDeduction")
|
||||
@Produces(MediaType.APPLICATION_JSON)
|
||||
public String deleteDerateDeduction(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody OtherDeductionDetailDeleteParam param) {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
return new ResponseResult<OtherDeductionDetailDeleteParam, String>(user).run(getOtherDeductionWrapper(user)::deleteDerateDeduction, param);
|
||||
}
|
||||
|
||||
|
||||
@POST
|
||||
@Path("/deleteOtherDerateDeduction")
|
||||
@Produces(MediaType.APPLICATION_JSON)
|
||||
public String deleteOtherDerateDeduction(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody OtherDeductionDetailDeleteParam param) {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
return new ResponseResult<OtherDeductionDetailDeleteParam, String>(user).run(getOtherDeductionWrapper(user)::deleteOtherDerateDeduction, param);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@POST
|
||||
@Path("/deletePersonalPension")
|
||||
@Produces(MediaType.APPLICATION_JSON)
|
||||
public String deletePersonalPension(@Context HttpServletRequest request, @Context HttpServletResponse response, @RequestBody OtherDeductionDetailDeleteParam param) {
|
||||
User user = HrmUserVarify.getUser(request, response);
|
||||
return new ResponseResult<OtherDeductionDetailDeleteParam, String>(user).run(getOtherDeductionWrapper(user)::deletePersonalPension, param);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -6,9 +6,7 @@ import com.api.browser.util.ConditionFactory;
|
|||
import com.api.browser.util.ConditionType;
|
||||
import com.engine.common.util.ServiceUtil;
|
||||
import com.engine.core.impl.Service;
|
||||
import com.engine.salary.entity.datacollection.dto.FreeIncomeListDTO;
|
||||
import com.engine.salary.entity.datacollection.dto.OtherDeductionListDTO;
|
||||
import com.engine.salary.entity.datacollection.dto.OtherDeductionRecordDTO;
|
||||
import com.engine.salary.entity.datacollection.dto.*;
|
||||
import com.engine.salary.entity.datacollection.param.*;
|
||||
import com.engine.salary.entity.datacollection.po.OtherDeductionPO;
|
||||
import com.engine.salary.exception.SalaryRunTimeException;
|
||||
|
|
@ -207,9 +205,9 @@ public class OtherDeductionWrapper extends Service {
|
|||
//是否开启了智能算薪
|
||||
boolean enableUse = getTaxDeclarationApiConfigService(user).enableUse();
|
||||
|
||||
if(enableUse){
|
||||
if (enableUse) {
|
||||
return getOtherDeductionService(user).downloadDetailTemplate(queryParam);
|
||||
}else {
|
||||
} else {
|
||||
return getOtherDeductionService(user).downloadTemplate(queryParam);
|
||||
}
|
||||
}
|
||||
|
|
@ -228,9 +226,9 @@ public class OtherDeductionWrapper extends Service {
|
|||
//是否开启了智能算薪
|
||||
boolean enableUse = getTaxDeclarationApiConfigService(user).enableUse();
|
||||
|
||||
if(enableUse){
|
||||
if (enableUse) {
|
||||
return getOtherDeductionService(user).importDetailData(importParam);
|
||||
}else {
|
||||
} else {
|
||||
return getOtherDeductionService(user).importData(importParam);
|
||||
}
|
||||
}
|
||||
|
|
@ -291,10 +289,87 @@ public class OtherDeductionWrapper extends Service {
|
|||
}
|
||||
|
||||
public PageInfo<FreeIncomeListDTO> freeIncomeList(OtherDeductionDetailQueryParam param) {
|
||||
return getOtherDeductionService(user).freeIncomeList(param);
|
||||
return getOtherDeductionService(user).freeIncomeList(param);
|
||||
}
|
||||
|
||||
public PageInfo<DerateDeductionListDTO> derateDeductionList(OtherDeductionDetailQueryParam param) {
|
||||
return getOtherDeductionService(user).derateDeductionList(param);
|
||||
}
|
||||
|
||||
public PageInfo<EndowmentInsuranceListDTO> endowmentInsuranceList(OtherDeductionDetailQueryParam param) {
|
||||
return getOtherDeductionService(user).endowmentInsuranceList(param);
|
||||
}
|
||||
|
||||
public PageInfo<GrantDonationListDTO> grantDonationList(OtherDeductionDetailQueryParam param) {
|
||||
return getOtherDeductionService(user).grantDonationList(param);
|
||||
}
|
||||
|
||||
public PageInfo<HealthInsuranceListDTO> healthInsuranceList(OtherDeductionDetailQueryParam param) {
|
||||
return getOtherDeductionService(user).healthInsuranceList(param);
|
||||
}
|
||||
|
||||
public PageInfo<OtherDerateDeductionListDTO> otherDerateDeductionList(OtherDeductionDetailQueryParam param) {
|
||||
return getOtherDeductionService(user).otherDerateDeductionList(param);
|
||||
}
|
||||
|
||||
public PageInfo<PersonalPensionListDTO> personalPensionList(OtherDeductionDetailQueryParam param) {
|
||||
return getOtherDeductionService(user).personalPensionList(param);
|
||||
}
|
||||
|
||||
public void saveFreeIncome(FreeIncomeSaveParam param) {
|
||||
getOtherDeductionService(user).saveFreeIncome(param);
|
||||
}
|
||||
}
|
||||
|
||||
public void saveEndowmentInsurance(EndowmentInsuranceSaveParam param) {
|
||||
getOtherDeductionService(user).saveEndowmentInsurance(param);
|
||||
}
|
||||
|
||||
public void saveGrantDonation(GrantDonationSaveParam param) {
|
||||
getOtherDeductionService(user).saveGrantDonation(param);
|
||||
}
|
||||
|
||||
public void saveHealthInsurance(HealthInsuranceSaveParam param) {
|
||||
getOtherDeductionService(user).saveHealthInsurance(param);
|
||||
}
|
||||
|
||||
public void saveOtherDerateDeduction(OtherDerateDeductionSaveParam param) {
|
||||
getOtherDeductionService(user).saveOtherDerateDeduction(param);
|
||||
}
|
||||
|
||||
public void saveDerateDeduction(DerateDeductionSaveParam param) {
|
||||
getOtherDeductionService(user).saveDerateDeduction(param);
|
||||
}
|
||||
|
||||
public void savePersonalPension(PersonalPensionSaveParam param) {
|
||||
getOtherDeductionService(user).savePersonalPension(param);
|
||||
}
|
||||
|
||||
public void deleteFreeIncome(OtherDeductionDetailDeleteParam param) {
|
||||
getOtherDeductionService(user).deleteFreeIncome(param);
|
||||
}
|
||||
|
||||
public void deleteEndowmentInsurance(OtherDeductionDetailDeleteParam param) {
|
||||
getOtherDeductionService(user).deleteEndowmentInsurance(param);
|
||||
}
|
||||
|
||||
public void deleteGrantDonation(OtherDeductionDetailDeleteParam param) {
|
||||
getOtherDeductionService(user).deleteGrantDonation(param);
|
||||
}
|
||||
|
||||
public void deleteHealthInsurance(OtherDeductionDetailDeleteParam param) {
|
||||
getOtherDeductionService(user).deleteHealthInsurance(param);
|
||||
}
|
||||
|
||||
public void deleteOtherDerateDeduction(OtherDeductionDetailDeleteParam param) {
|
||||
getOtherDeductionService(user).deleteOtherDerateDeduction(param);
|
||||
}
|
||||
|
||||
public void deleteDerateDeduction(OtherDeductionDetailDeleteParam param) {
|
||||
getOtherDeductionService(user).deleteDerateDeduction(param);
|
||||
}
|
||||
|
||||
public void deletePersonalPension(OtherDeductionDetailDeleteParam param) {
|
||||
getOtherDeductionService(user).deletePersonalPension(param);
|
||||
}
|
||||
|
||||
}
|
||||
Loading…
Reference in New Issue