累计扣除字段

This commit is contained in:
钱涛 2022-05-20 14:41:42 +08:00
parent 985af0197d
commit d77e8b0de4
25 changed files with 337 additions and 764 deletions

View File

@ -0,0 +1,25 @@
ALTER TABLE hrsa_add_up_situation
ADD COLUMN add_up_illness_medical varchar(255) NULL COMMENT '累计大病医疗' AFTER tenant_key,
ADD COLUMN add_up_tax_savings varchar(255) NULL COMMENT '累计减免税额' AFTER add_up_illness_medical,
ADD COLUMN add_up_infant_care varchar(255) NULL COMMENT '累计婴幼儿照护' AFTER add_up_tax_savings;
ALTER TABLE hrsa_add_up_situation
ADD add_up_illness_medical varchar(255) NULL ,
add_up_tax_savings varchar(255) NULL ,
add_up_infant_care varchar(255) NULL
GO
ALTER TABLE hrsa_add_up_deduction
ADD COLUMN add_up_illness_medical varchar(255) NULL COMMENT '累计大病医疗' AFTER tenant_key,
ADD COLUMN add_up_infant_care varchar(255) NULL COMMENT '累计婴幼儿照护' AFTER add_up_illness_medical;
ALTER TABLE hrsa_add_up_deduction
ADD add_up_illness_medical varchar(255) NULL,
add_up_infant_care varchar(255) NULL
GO

View File

@ -121,8 +121,6 @@ public class AddUpDeductionBiz extends BaseBean {
}
/**
* 导出
*
@ -135,7 +133,7 @@ public class AddUpDeductionBiz extends BaseBean {
List<List<String>> rowList = getExcelRowList(param);
//获取excel
return ExcelUtil.genWorkbook(rowList,"累计专项附加扣除");
return ExcelUtil.genWorkbook(rowList, "累计专项附加扣除");
}
@ -146,7 +144,7 @@ public class AddUpDeductionBiz extends BaseBean {
*/
private List<List<String>> getExcelRowList(AddUpDeductionQueryParam param) {
//excel标题
List<String> title = Arrays.asList("姓名", "个税扣缴义务人", "部门", "手机号", "工号", "证件号码", "入职日期", "累计子女教育", "累计继续教育", "累计住房贷款利息", "累计住房租金", "累计赡养老人");
List<String> title = Arrays.asList("姓名", "个税扣缴义务人", "部门", "手机号", "工号", "证件号码", "入职日期", "累计子女教育", "累计继续教育", "累计住房贷款利息", "累计住房租金", "累计赡养老人", "累计大病医疗", "累计婴幼儿照护");
SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM-dd");
List<AddUpDeductionDTO> list = list(param);
@ -160,12 +158,14 @@ public class AddUpDeductionBiz extends BaseBean {
cellList.add(Util.null2String(dto.getMobile()));
cellList.add(Util.null2String(dto.getJobNum()));
cellList.add(Util.null2String(dto.getIdNo()));
cellList.add(dto.getHiredate() == null ? "" : formatter.format(dto.getHiredate()));
cellList.add(String.valueOf(dto.getAddUpChildEducation()));
cellList.add(String.valueOf(dto.getAddUpContinuingEducation()));
cellList.add(String.valueOf(dto.getAddUpHousingLoanInterest()));
cellList.add(String.valueOf(dto.getAddUpHousingRent()));
cellList.add(String.valueOf(dto.getAddUpSupportElderly()));
cellList.add(Util.null2String(dto.getHiredate()));
cellList.add(Util.null2String(dto.getAddUpChildEducation()));
cellList.add(Util.null2String(dto.getAddUpContinuingEducation()));
cellList.add(Util.null2String(dto.getAddUpHousingLoanInterest()));
cellList.add(Util.null2String(dto.getAddUpHousingRent()));
cellList.add(Util.null2String(dto.getAddUpSupportElderly()));
cellList.add(Util.null2String(dto.getAddUpIllnessMedical()));
cellList.add(Util.null2String(dto.getAddUpInfantCare()));
return cellList;
}).collect(Collectors.toList()))
.orElse(Collections.emptyList());
@ -189,7 +189,7 @@ public class AddUpDeductionBiz extends BaseBean {
List<List<String>> rowList = getExcelRowDetailList(param);
//获取excel
return ExcelUtil.genWorkbook(rowList,"累计专项附加扣除明细");
return ExcelUtil.genWorkbook(rowList, "累计专项附加扣除明细");
}
@ -202,7 +202,7 @@ public class AddUpDeductionBiz extends BaseBean {
private List<List<String>> getExcelRowDetailList(AddUpDeductionQueryParam param) {
//excel标题
List<String> title = Arrays.asList("姓名", "申报月份", "个税扣缴义务人", "部门", "工号", "累计子女教育", "累计继续教育", "累计住房贷款利息", "累计住房租金", "累计赡养老人");
List<String> title = Arrays.asList("姓名", "申报月份", "个税扣缴义务人", "部门", "工号", "累计子女教育", "累计继续教育", "累计住房贷款利息", "累计住房租金", "累计赡养老人", "累计大病医疗", "累计婴幼儿照护");
SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM");
@ -217,11 +217,13 @@ public class AddUpDeductionBiz extends BaseBean {
cellList.add(Util.null2String(dto.getTaxAgentName()));
cellList.add(Util.null2String(dto.getDepartmentName()));
cellList.add(Util.null2String(dto.getJobNum()));
cellList.add(String.valueOf(dto.getAddUpChildEducation()));
cellList.add(String.valueOf(dto.getAddUpContinuingEducation()));
cellList.add(String.valueOf(dto.getAddUpHousingLoanInterest()));
cellList.add(String.valueOf(dto.getAddUpHousingRent()));
cellList.add(String.valueOf(dto.getAddUpSupportElderly()));
cellList.add(Util.null2String(dto.getAddUpChildEducation()));
cellList.add(Util.null2String(dto.getAddUpContinuingEducation()));
cellList.add(Util.null2String(dto.getAddUpHousingLoanInterest()));
cellList.add(Util.null2String(dto.getAddUpHousingRent()));
cellList.add(Util.null2String(dto.getAddUpSupportElderly()));
cellList.add(Util.null2String(dto.getAddUpIllnessMedical()));
cellList.add(Util.null2String(dto.getAddUpInfantCare()));
return cellList;
}).collect(Collectors.toList()))
.orElse(Collections.emptyList());

View File

@ -133,7 +133,7 @@ public class AddUpSituationBiz extends BaseBean {
List<List<String>> rowList = getExcelRowList(param);
//获取excel
return ExcelUtil.genWorkbook(rowList,"累计情况");
return ExcelUtil.genWorkbook(rowList, "累计情况");
}
@ -144,7 +144,9 @@ public class AddUpSituationBiz extends BaseBean {
*/
private List<List<String>> getExcelRowList(AddUpSituationQueryParam param) {
// excel标题
final List<String> title = Arrays.asList("姓名", "个税扣缴义务人", "部门", "手机号", "工号", "证件号码", "入职日期", "累计收入额", "累计减除费用", "累计社保个人合计", "累计公积金个人合计", "累计子女教育", "累计继续教育", "累计住房贷款利息", "累计住房租金", "累计赡养老人", "累计企业(职业)年金及其他福利", "累计其他扣除", "累计免税收入", "累计准予扣除的捐赠额", "累计已预扣预缴税额");
final List<String> title = Arrays.asList("姓名", "个税扣缴义务人", "部门", "手机号", "工号", "证件号码", "入职日期", "累计收入额", "累计减除费用",
"累计社保个人合计", "累计公积金个人合计", "累计子女教育", "累计继续教育", "累计住房贷款利息", "累计住房租金", "累计赡养老人",
"累计大病医疗", "累计企业(职业)年金及其他福利", "累计其他扣除", "累计免税收入", "累计准予扣除的捐赠额", "累计减免税额", "累计已预扣预缴税额", "累计婴幼儿照护");
SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM-dd");
List<AddUpSituationDTO> list = list(param);
@ -168,11 +170,14 @@ public class AddUpSituationBiz extends BaseBean {
cellList.add(String.valueOf(dto.getAddUpHousingLoanInterest()));
cellList.add(String.valueOf(dto.getAddUpHousingRent()));
cellList.add(String.valueOf(dto.getAddUpSupportElderly()));
cellList.add(String.valueOf(dto.getAddUpIllnessMedical()));
cellList.add(String.valueOf(dto.getAddUpEnterpriseAndOther()));
cellList.add(String.valueOf(dto.getAddUpOtherDeduction()));
cellList.add(String.valueOf(dto.getAddUpTaxExemptIncome()));
cellList.add(String.valueOf(dto.getAddUpAllowedDonation()));
cellList.add(String.valueOf(dto.getAddUpTaxSavings()));
cellList.add(String.valueOf(dto.getAddUpAdvanceTax()));
cellList.add(String.valueOf(dto.getAddUpInfantCare()));
return cellList;
}).collect(Collectors.toList()))
.orElse(Collections.emptyList());
@ -196,7 +201,7 @@ public class AddUpSituationBiz extends BaseBean {
List<List<String>> rowList = getExcelRowDetailList(param);
//获取excel
return ExcelUtil.genWorkbook(rowList,"累计情况明细");
return ExcelUtil.genWorkbook(rowList, "累计情况明细");
}
@ -209,7 +214,9 @@ public class AddUpSituationBiz extends BaseBean {
private List<List<String>> getExcelRowDetailList(AddUpSituationQueryParam param) {
//excel标题
List<String> title = Arrays.asList("姓名", "税款所属期", "个税扣缴义务人", "部门", "手机号", "工号", "累计收入额", "累计减除费用", "累计社保个人合计", "累计公积金个人合计", "累计子女教育", "累计继续教育", "累计住房贷款利息", "累计住房租金", "累计赡养老人", "累计企业(职业)年金及其他福利", "累计其他扣除", "累计免税收入", "累计准予扣除的捐赠额", "累计已预扣预缴税额");
List<String> title = Arrays.asList("姓名", "税款所属期", "个税扣缴义务人", "部门", "手机号", "工号", "累计收入额", "累计减除费用", "累计社保个人合计",
"累计公积金个人合计", "累计子女教育", "累计继续教育", "累计住房贷款利息", "累计住房租金", "累计赡养老人", "累计大病医疗", "累计企业(职业)年金及其他福利",
"累计其他扣除", "累计免税收入", "累计准予扣除的捐赠额", "累计减免税额", "累计已预扣预缴税额", "累计婴幼儿照护");
SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM");
//查询详细信息
@ -218,15 +225,29 @@ public class AddUpSituationBiz extends BaseBean {
.map(List::stream)
.map(operatorStream -> operatorStream.map(dto -> {
List<String> cellList = new ArrayList<>();
cellList.add(Util.null2String(dto.getUsername()));
cellList.add(Util.null2String(dto.getTaxYearMonth() == null ? "" : formatter.format(dto.getTaxYearMonth())));
cellList.add(Util.null2String(dto.getTaxAgentName()));
cellList.add(Util.null2String(dto.getDepartmentName()));
cellList.add(Util.null2String(dto.getMobile()));
cellList.add(Util.null2String(dto.getJobNum()));
cellList.add(String.valueOf(dto.getAddUpChildEducation()));
cellList.add(String.valueOf(dto.getAddUpContinuingEducation()));
cellList.add(String.valueOf(dto.getAddUpHousingLoanInterest()));
cellList.add(String.valueOf(dto.getAddUpHousingRent()));
cellList.add(String.valueOf(dto.getAddUpSupportElderly()));
cellList.add(Util.null2String(dto.getAddUpIncome()));
cellList.add(Util.null2String(dto.getAddUpSubtraction()));
cellList.add(Util.null2String(dto.getAddUpSocialSecurityTotal()));
cellList.add(Util.null2String(dto.getAddUpAccumulationFundTotal()));
cellList.add(Util.null2String(dto.getAddUpChildEducation()));
cellList.add(Util.null2String(dto.getAddUpContinuingEducation()));
cellList.add(Util.null2String(dto.getAddUpHousingLoanInterest()));
cellList.add(Util.null2String(dto.getAddUpHousingRent()));
cellList.add(Util.null2String(dto.getAddUpSupportElderly()));
cellList.add(Util.null2String(dto.getAddUpIllnessMedical()));
cellList.add(Util.null2String(dto.getAddUpEnterpriseAndOther()));
cellList.add(Util.null2String(dto.getAddUpOtherDeduction()));
cellList.add(Util.null2String(dto.getAddUpTaxExemptIncome()));
cellList.add(Util.null2String(dto.getAddUpAllowedDonation()));
cellList.add(Util.null2String(dto.getAddUpTaxSavings()));
cellList.add(Util.null2String(dto.getAddUpAdvanceTax()));
cellList.add(Util.null2String(dto.getAddUpInfantCare()));
return cellList;
}).collect(Collectors.toList()))
.orElse(Collections.emptyList());

View File

@ -158,7 +158,7 @@ public class OtherDeductionBiz extends BaseBean {
cellList.add(Util.null2String(dto.getMobile()));
cellList.add(Util.null2String(dto.getJobNum()));
cellList.add(Util.null2String(dto.getIdNo()));
cellList.add(dto.getHiredate() == null ? "" : formatter.format(dto.getHiredate()));
cellList.add(Util.null2String(dto.getHiredate()));
cellList.add(Util.null2String(dto.getBusinessHealthyInsurance()));
cellList.add(Util.null2String(dto.getTaxDelayEndowmentInsurance()));
cellList.add(Util.null2String(dto.getOtherDeduction()));

View File

@ -80,7 +80,9 @@ public class AddUpDeductionGetDetailListCmd extends AbstractCommonCommand<Map<St
" t1.add_up_continuing_education as addUpContinuingEducation," +
" t1.add_up_housing_loan_interest as addUpHousingLoanInterest," +
" t1.add_up_housing_rent as addUpHousingRent," +
" t1.add_up_support_elderly as addUpSupportElderly";
" t1.add_up_support_elderly as addUpSupportElderly," +
" t1.add_up_illness_medical as addUpIllnessMedical," +
" t1.add_up_infant_care as addUpInfantCare";
String fromSql = " FROM" +
" hrsa_add_up_deduction t1" +
@ -137,7 +139,7 @@ public class AddUpDeductionGetDetailListCmd extends AbstractCommonCommand<Map<St
//姓名
String username = queryParam.getUsername();
if (StringUtils.isNotBlank(username)) {
sqlWhere += " AND e.lastname "+ dbType.like(username);
sqlWhere += " AND e.lastname " + dbType.like(username);
}
//个税扣缴义务人
Long taxAgentId = queryParam.getTaxAgentId();
@ -153,7 +155,7 @@ public class AddUpDeductionGetDetailListCmd extends AbstractCommonCommand<Map<St
//工号
String jobNum = queryParam.getJobNum();
if (StringUtils.isNotBlank(jobNum)) {
sqlWhere += " AND e.workcode "+ dbType.like(jobNum);
sqlWhere += " AND e.workcode " + dbType.like(jobNum);
}
//入职日期
List<Date> hiredate = queryParam.getHiredate();
@ -163,7 +165,7 @@ public class AddUpDeductionGetDetailListCmd extends AbstractCommonCommand<Map<St
//手机号
String mobile = queryParam.getMobile();
if (StringUtils.isNotBlank(mobile)) {
sqlWhere += " AND e.mobile "+ dbType.like(mobile);
sqlWhere += " AND e.mobile " + dbType.like(mobile);
}
return sqlWhere;

View File

@ -69,7 +69,7 @@ public class AddUpDeductionImportCmd extends AbstractCommonCommand<Map<String, O
InputStream fileInputStream = null;
try {
fileInputStream = ImageFileManager.getInputStreamById(Integer.valueOf(imageId));
List<AddUpDeductionDTO> addUpDeductions = ExcelParseHelper.parse2Map(fileInputStream, AddUpDeductionDTO.class, 0, 1, 13, "addUpDeductionTemplate.xlsx");
List<AddUpDeductionDTO> addUpDeductions = ExcelParseHelper.parse2Map(fileInputStream, AddUpDeductionDTO.class, 0, 1, 14, "addUpDeductionTemplate.xlsx");
int total = addUpDeductions.size();
int index = 0;
@ -188,6 +188,10 @@ public class AddUpDeductionImportCmd extends AbstractCommonCommand<Map<String, O
BigDecimal addUpSupportElderly = dto.getAddUpSupportElderly();
addUpDeduction.setAddUpSupportElderly(Util.null2String(addUpSupportElderly));
addUpDeduction.setAddUpIllnessMedical(Util.null2String(dto.getAddUpIllnessMedical()));
addUpDeduction.setAddUpInfantCare(Util.null2String(dto.getAddUpInfantCare()));
if (errorSum == 0) {
successCount += 1;
// 合格数据

View File

@ -45,7 +45,9 @@ public class AddUpDeductionListCmd extends AbstractCommonCommand<Map<String, Obj
" t1.add_up_continuing_education as addUpContinuingEducation," +
" t1.add_up_housing_loan_interest as addUpHousingLoanInterest," +
" t1.add_up_housing_rent as addUpHousingRent," +
" t1.add_up_support_elderly as addUpSupportElderly";
" t1.add_up_support_elderly as addUpSupportElderly,"+
" t1.add_up_illness_medical as addUpIllnessMedical,"+
" t1.add_up_infant_care as addUpInfantCare";
String fromSql = " FROM" +
" hrsa_add_up_deduction t1" +

View File

@ -48,7 +48,7 @@ public class AddUpDeductionPreviewCmd extends AbstractCommonCommand<Map<String,
InputStream fileInputStream = null;
try {
fileInputStream = ImageFileManager.getInputStreamById(Integer.valueOf(imageId));
List<AddUpDeductionDTO> addUpDeductions = ExcelParseHelper.parse2Map(fileInputStream, AddUpDeductionDTO.class, 0, 1, 13, "addUpDeductionTemplate.xlsx");
List<AddUpDeductionDTO> addUpDeductions = ExcelParseHelper.parse2Map(fileInputStream, AddUpDeductionDTO.class, 0, 1, 14, "addUpDeductionTemplate.xlsx");
apidatas.put("preview", addUpDeductions);
} finally {
IOUtils.closeQuietly(fileInputStream);

View File

@ -88,6 +88,9 @@ public class AddUpSituationGetDetailListCmd extends AbstractCommonCommand<Map<St
" t1.add_up_other_deduction as addUpOtherDeduction," +
" t1.add_up_tax_exempt_income as addUpTaxExemptIncome," +
" t1.add_up_allowed_donation as addUpAllowedDonation," +
" t1.add_up_infant_care as addUpInfantCare," +
" t1.add_up_tax_savings as addUpTaxSavings," +
" t1.add_up_illness_medical as addUpIllnessMedical," +
" t1.add_up_advance_tax as addUpAdvanceTax";
String fromSql = " FROM " +

View File

@ -67,7 +67,7 @@ public class AddUpSituationImportCmd extends AbstractCommonCommand<Map<String, O
try {
fileInputStream = ImageFileManager.getInputStreamById(Integer.valueOf(imageId));
List<AddUpSituationDTO> excelDates = ExcelParseHelper.parse2Map(fileInputStream, AddUpSituationDTO.class, 0, 1, 23, "template.xlsx");
List<AddUpSituationDTO> excelDates = ExcelParseHelper.parse2Map(fileInputStream, AddUpSituationDTO.class, 0, 1, 24, "template.xlsx");
int total = excelDates.size();
int index = 0;
@ -205,6 +205,10 @@ public class AddUpSituationImportCmd extends AbstractCommonCommand<Map<String, O
String addUpAdvanceTax = dto.getAddUpAdvanceTax();
po.setAddUpAdvanceTax(addUpAdvanceTax);
po.setAddUpIllnessMedical(dto.getAddUpIllnessMedical());
po.setAddUpTaxSavings(dto.getAddUpTaxSavings());
po.setAddUpInfantCare(dto.getAddUpInfantCare());
if (errorSum == 0) {
successCount += 1;
// 合格数据

View File

@ -54,6 +54,9 @@ public class AddUpSituationListCmd extends AbstractCommonCommand<Map<String, Obj
" t1.add_up_other_deduction as addUpOtherDeduction," +
" t1.add_up_tax_exempt_income as addUpTaxExemptIncome," +
" t1.add_up_allowed_donation as addUpAllowedDonation," +
" t1.add_up_infant_care as addUpInfantCare," +
" t1.add_up_tax_savings as addUpTaxSavings," +
" t1.add_up_illness_medical as addUpIllnessMedical," +
" t1.add_up_advance_tax as addUpAdvanceTax";
String fromSql = " FROM " +

View File

@ -51,7 +51,7 @@ public class AddUpSituationPreviewCmd extends AbstractCommonCommand<Map<String,
InputStream fileInputStream = null;
try {
fileInputStream = ImageFileManager.getInputStreamById(Integer.valueOf(imageId));
List<AddUpSituationDTO> excelDates = ExcelParseHelper.parse2Map(fileInputStream, AddUpSituationDTO.class, 0, 1, 23, "template.xlsx");
List<AddUpSituationDTO> excelDates = ExcelParseHelper.parse2Map(fileInputStream, AddUpSituationDTO.class, 0, 1, 24, "template.xlsx");
apidatas.put("preview", excelDates);
} finally {
IOUtils.closeQuietly(fileInputStream);

View File

@ -74,6 +74,12 @@ public class AddUpDeduction {
@SalaryFormulaVar(defaultLabel = "累计大病医疗", labelId = 105142, dataType = "number")
private String addUpIllnessMedical;
/**
* 累计婴幼儿照护
*/
@SalaryFormulaVar(defaultLabel = "累计婴幼儿照护", labelId = 117732, dataType = "number")
private String addUpInfantCare;
/**
* 创建时间
*/

View File

@ -19,6 +19,7 @@ import java.util.Date;
@NoArgsConstructor
@AllArgsConstructor
@SalaryTable(pageId = "a4f83287-e3f9-4275-9527-7d06e54y6238", fields = "id,addUpSubtraction", operates = {@SalaryTableOperate(text = "删除",index = "0")})
//hrsa_add_up_situation
public class AddUpSituation {
/**
* 主键id
@ -105,6 +106,12 @@ public class AddUpSituation {
@SalaryFormulaVar(defaultLabel = "累计大病医疗", labelId = 105142, dataType = "number")
private String addUpIllnessMedical;
/**
* 累计婴幼儿照护
*/
@SalaryFormulaVar(defaultLabel = "累计婴幼儿照护", labelId = 117732, dataType = "number")
private String addUpInfantCare;
/**
* 累计企业职业年金及其他福利
*/

View File

@ -133,6 +133,10 @@ public class AddUpDeductionDTO {
@SalaryTableColumn(text = "累计大病医疗", width = "10%", column = "addUpIllnessMedical")
private BigDecimal addUpIllnessMedical;
@ExcelProperty(index = 13)
@SalaryTableColumn(text = "累计婴幼儿照护", width = "10%", column = "addUpInfantCare")
private BigDecimal addUpInfantCare;
@SalaryTableColumn(text = "操作", width = "20%", column = "operate")
private String operate;
}

View File

@ -93,4 +93,12 @@ public class AddUpDeductionRecordDTO {
@SalaryTableColumn(text = "累计赡养老人", width = "10%", column = "addUpSupportElderly")
private BigDecimal addUpSupportElderly;
@ExcelProperty(index = 10)
@SalaryTableColumn(text = "累计大病医疗", width = "10%", column = "addUpIllnessMedical")
private BigDecimal addUpIllnessMedical;
@ExcelProperty(index = 11)
@SalaryTableColumn(text = "累计婴幼儿照护", width = "10%", column = "addUpInfantCare")
private String addUpInfantCare;
}

View File

@ -12,8 +12,6 @@ import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import java.math.BigDecimal;
/**
* 数据采集-累计情况表
*/
@ -43,6 +41,9 @@ public class AddUpSituationDTO {
@SalaryTableColumn(text = "姓名", width = "10%", column = "username")
@ExcelProperty(index = 0)
private String username;
//
// @SalaryTableColumn(text = "申报月份", width = "10%", column = "username")
// private String taxYearMonth;
//个税扣缴义务人
@SalaryTableColumn(text = "个税扣缴义务人", width = "10%", column = "taxAgentName")
@ -122,7 +123,7 @@ public class AddUpSituationDTO {
//累计大病医疗
@SalaryTableColumn(text = "累计大病医疗", width = "10%", column = "addUpIllnessMedical")
@ExcelProperty(index = 16)
private BigDecimal addUpIllnessMedical;
private String addUpIllnessMedical;
//累计企业职业年金及其他福利
@SalaryTableColumn(text = "累计企业(职业)年金及其他福利", width = "10%", column = "addUpEnterpriseAndOther")
@ -154,6 +155,11 @@ public class AddUpSituationDTO {
@ExcelProperty(index = 22)
private String addUpAdvanceTax;
//累计婴幼儿照护
@ExcelProperty(index = 23)
@SalaryTableColumn(text = "累计婴幼儿照护", width = "10%", column = "addUpInfantCare")
private String addUpInfantCare;
@SalaryTableColumn(text = "操作", width = "20%", column = "operate")
private String operate;
}

View File

@ -94,22 +94,34 @@ public class AddUpSituationRecordDTO {
private String addUpSupportElderly;
@ExcelProperty(index = 15)
@SalaryTableColumn(text = "累计大病医疗", width = "10%", column = "addUpIllnessMedical")
private String addUpIllnessMedical;
@ExcelProperty(index = 16)
@SalaryTableColumn(text = "累计企业(职业)年金及其他福利", width = "10%", column = "addUpEnterpriseAndOther")
private String addUpEnterpriseAndOther;
@ExcelProperty(index = 16)
@ExcelProperty(index = 17)
@SalaryTableColumn(text = "累计其他扣除", width = "10%", column = "addUpOtherDeduction")
private String addUpOtherDeduction;
@ExcelProperty(index = 17)
@ExcelProperty(index = 18)
@SalaryTableColumn(text = "累计免税收入", width = "10%", column = "addUpTaxExemptIncome")
private String addUpTaxExemptIncome;
@ExcelProperty(index = 18)
@ExcelProperty(index = 19)
@SalaryTableColumn(text = "累计准予扣除的捐赠额", width = "10%", column = "addUpAllowedDonation")
private String addUpAllowedDonation;
@ExcelProperty(index = 19)
@ExcelProperty(index = 20)
@SalaryTableColumn(text = "累计减免税额", width = "10%", column = "addUpTaxSavings")
private String addUpTaxSavings;
@ExcelProperty(index = 21)
@SalaryTableColumn(text = "累计已预扣预缴税额", width = "10%", column = "addUpAdvanceTax")
private String addUpAdvanceTax;
@ExcelProperty(index = 22)
@SalaryTableColumn(text = "累计婴幼儿照护", width = "10%", column = "addUpInfantCare")
private String addUpInfantCare;
}

View File

@ -28,46 +28,6 @@ public interface AddUpDeductionMapper {
* @return 返回记录没有返回null
*/
AddUpDeduction getById(Long id);
/**
* 新增插入所有字段
*
* @param addUpDeduction 新增的记录
* @return 返回影响行数
*/
int insert(AddUpDeduction addUpDeduction);
/**
* 新增忽略null字段
*
* @param addUpDeduction 新增的记录
* @return 返回影响行数
*/
int insertIgnoreNull(AddUpDeduction addUpDeduction);
/**
* 修改修改所有字段
*
* @param addUpDeduction 修改的记录
* @return 返回影响行数
*/
int update(AddUpDeduction addUpDeduction);
/**
* 修改忽略null字段
*
* @param addUpDeduction 修改的记录
* @return 返回影响行数
*/
int updateIgnoreNull(AddUpDeduction addUpDeduction);
/**
* 删除记录
*
* @param addUpDeduction 待删除的记录
* @return 返回影响行数
*/
int delete(AddUpDeduction addUpDeduction);
/**

View File

@ -16,6 +16,8 @@
<result column="tax_agent_id" property="taxAgentId"/>
<result column="tenant_key" property="tenantKey"/>
<result column="update_time" property="updateTime"/>
<result column="add_up_illness_medical" property="addUpIllnessMedical"/>
<result column="add_up_infant_care" property="addUpInfantCare"/>
</resultMap>
<!-- 表字段 -->
@ -36,6 +38,8 @@
, t.tax_agent_id
, t.tenant_key
, t.update_time
, t.add_up_illness_medical
, t.add_up_infant_care
</sql>
<!-- 查询全部 -->
@ -54,218 +58,6 @@
WHERE id = #{id} AND delete_type = 0
</select>
<!-- 插入全部字段 -->
<insert id="insert" parameterType="com.engine.salary.entity.datacollection.AddUpDeduction"
keyProperty="id" keyColumn="id" useGeneratedKeys="true"
>
INSERT INTO hrsa_add_up_deduction
<trim prefix="(" suffix=")" suffixOverrides=",">
add_up_child_education,
add_up_continuing_education,
add_up_housing_loan_interest,
add_up_housing_rent,
add_up_support_elderly,
create_time,
creator,
declare_month,
delete_type,
employee_id,
id,
tax_agent_id,
tenant_key,
update_time,
</trim>
<trim prefix="VALUES (" suffix=")" suffixOverrides=",">
#{addUpChildEducation},
#{addUpContinuingEducation},
#{addUpHousingLoanInterest},
#{addUpHousingRent},
#{addUpSupportElderly},
#{createTime},
#{creator},
#{declareMonth},
#{deleteType},
#{employeeId},
#{id},
#{taxAgentId},
#{tenantKey},
#{updateTime},
</trim>
</insert>
<!-- 插入不为NULL的字段 -->
<insert id="insertIgnoreNull" parameterType="com.engine.salary.entity.datacollection.AddUpDeduction"
keyProperty="id" keyColumn="id" useGeneratedKeys="true"
>
INSERT INTO hrsa_add_up_deduction
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="addUpChildEducation != null">
add_up_child_education,
</if>
<if test="addUpContinuingEducation != null">
add_up_continuing_education,
</if>
<if test="addUpHousingLoanInterest != null">
add_up_housing_loan_interest,
</if>
<if test="addUpHousingRent != null">
add_up_housing_rent,
</if>
<if test="addUpSupportElderly != null">
add_up_support_elderly,
</if>
<if test="createTime != null">
create_time,
</if>
<if test="creator != null">
creator,
</if>
<if test="declareMonth != null">
declare_month,
</if>
<if test="deleteType != null">
delete_type,
</if>
<if test="employeeId != null">
employee_id,
</if>
<if test="id != null">
id,
</if>
<if test="taxAgentId != null">
tax_agent_id,
</if>
<if test="tenantKey != null">
tenant_key,
</if>
<if test="updateTime != null">
update_time,
</if>
</trim>
<trim prefix="VALUES (" suffix=")" suffixOverrides=",">
<if test="addUpChildEducation != null">
#{addUpChildEducation},
</if>
<if test="addUpContinuingEducation != null">
#{addUpContinuingEducation},
</if>
<if test="addUpHousingLoanInterest != null">
#{addUpHousingLoanInterest},
</if>
<if test="addUpHousingRent != null">
#{addUpHousingRent},
</if>
<if test="addUpSupportElderly != null">
#{addUpSupportElderly},
</if>
<if test="createTime != null">
#{createTime},
</if>
<if test="creator != null">
#{creator},
</if>
<if test="declareMonth != null">
#{declareMonth},
</if>
<if test="deleteType != null">
#{deleteType},
</if>
<if test="employeeId != null">
#{employeeId},
</if>
<if test="id != null">
#{id},
</if>
<if test="taxAgentId != null">
#{taxAgentId},
</if>
<if test="tenantKey != null">
#{tenantKey},
</if>
<if test="updateTime != null">
#{updateTime},
</if>
</trim>
</insert>
<!-- 更新,更新全部字段 -->
<update id="update" parameterType="com.engine.salary.entity.datacollection.AddUpDeduction">
UPDATE hrsa_add_up_deduction
<set>
add_up_child_education=#{addUpChildEducation},
add_up_continuing_education=#{addUpContinuingEducation},
add_up_housing_loan_interest=#{addUpHousingLoanInterest},
add_up_housing_rent=#{addUpHousingRent},
add_up_support_elderly=#{addUpSupportElderly},
create_time=#{createTime},
creator=#{creator},
declare_month=#{declareMonth},
delete_type=#{deleteType},
employee_id=#{employeeId},
tax_agent_id=#{taxAgentId},
tenant_key=#{tenantKey},
update_time=#{updateTime},
</set>
WHERE id = #{id} AND delete_type = 0
</update>
<!-- 更新不为NULL的字段 -->
<update id="updateIgnoreNull" parameterType="com.engine.salary.entity.datacollection.AddUpDeduction">
UPDATE hrsa_add_up_deduction
<set>
<if test="addUpChildEducation != null">
add_up_child_education=#{addUpChildEducation},
</if>
<if test="addUpContinuingEducation != null">
add_up_continuing_education=#{addUpContinuingEducation},
</if>
<if test="addUpHousingLoanInterest != null">
add_up_housing_loan_interest=#{addUpHousingLoanInterest},
</if>
<if test="addUpHousingRent != null">
add_up_housing_rent=#{addUpHousingRent},
</if>
<if test="addUpSupportElderly != null">
add_up_support_elderly=#{addUpSupportElderly},
</if>
<if test="createTime != null">
create_time=#{createTime},
</if>
<if test="creator != null">
creator=#{creator},
</if>
<if test="declareMonth != null">
declare_month=#{declareMonth},
</if>
<if test="deleteType != null">
delete_type=#{deleteType},
</if>
<if test="employeeId != null">
employee_id=#{employeeId},
</if>
<if test="taxAgentId != null">
tax_agent_id=#{taxAgentId},
</if>
<if test="tenantKey != null">
tenant_key=#{tenantKey},
</if>
<if test="updateTime != null">
update_time=#{updateTime},
</if>
</set>
WHERE id = #{id} AND delete_type = 0
</update>
<!-- 根据主键删除记录 -->
<delete id="delete" parameterType="com.engine.salary.entity.datacollection.AddUpDeduction">
UPDATE hrsa_add_up_deduction
SET delete_type=1
WHERE id = #{id}
AND delete_type = 0
</delete>
<!-- 员工基本信息 -->
<select id="listEmployee" resultType="com.engine.salary.entity.datacollection.DataCollectionEmployee">
@ -298,7 +90,9 @@
t1.add_up_continuing_education,
t1.add_up_housing_loan_interest,
t1.add_up_housing_rent,
t1.add_up_support_elderly
t1.add_up_support_elderly,
t1.add_up_illness_medical,
t1.add_up_infant_care
</sql>
<sql id="paramSql">
@ -550,6 +344,8 @@
add_up_housing_loan_interest,
add_up_housing_rent,
add_up_support_elderly,
add_up_illness_medical,
add_up_infant_care,
create_time,
update_time,
creator,
@ -566,6 +362,8 @@
#{item.addUpHousingLoanInterest},
#{item.addUpHousingRent},
#{item.addUpSupportElderly},
#{item.addUpIllnessMedical},
#{item.addUpInfantCare},
#{item.createTime},
#{item.updateTime},
#{item.creator},
@ -583,6 +381,8 @@
add_up_housing_loan_interest,
add_up_housing_rent,
add_up_support_elderly,
add_up_illness_medical,
add_up_infant_care,
create_time,
update_time,
creator,
@ -599,6 +399,8 @@
#{item.addUpHousingLoanInterest},
#{item.addUpHousingRent},
#{item.addUpSupportElderly},
#{item.addUpIllnessMedical},
#{item.addUpInfantCare},
#{item.createTime},
#{item.updateTime},
#{item.creator},
@ -608,21 +410,23 @@
</insert>
<insert id="insertData" databaseId="sqlserver">
<foreach collection="collection" item="item" separator=";">
INSERT INTO hrsa_add_up_deduction(
employee_id,
tax_agent_id,
declare_month,
add_up_child_education,
add_up_continuing_education,
add_up_housing_loan_interest,
add_up_housing_rent,
add_up_support_elderly,
create_time,
update_time,
creator,
tenant_key
)
VALUES
INSERT INTO hrsa_add_up_deduction(
employee_id,
tax_agent_id,
declare_month,
add_up_child_education,
add_up_continuing_education,
add_up_housing_loan_interest,
add_up_housing_rent,
add_up_support_elderly,
add_up_illness_medical,
add_up_infant_care,
create_time,
update_time,
creator,
tenant_key
)
VALUES
(
#{item.employeeId},
#{item.taxAgentId},
@ -632,6 +436,8 @@
#{item.addUpHousingLoanInterest},
#{item.addUpHousingRent},
#{item.addUpSupportElderly},
#{item.addUpIllnessMedical},
#{item.addUpInfantCare},
#{item.createTime},
#{item.updateTime},
#{item.creator},
@ -678,6 +484,20 @@
</if>
</foreach>
</trim>
<trim prefix="add_up_illness_medical =case" suffix="end,">
<foreach collection="collection" item="item" index="index">
<if test="item.addUpIllnessMedical!=null">
when id=#{item.id} then #{item.addUpIllnessMedical}
</if>
</foreach>
</trim>
<trim prefix="add_up_infant_care =case" suffix="end,">
<foreach collection="collection" item="item" index="index">
<if test="item.addUpInfantCare!=null">
when id=#{item.id} then #{item.addUpInfantCare}
</if>
</foreach>
</trim>
</trim>
where
id in

View File

@ -27,47 +27,6 @@ public interface AddUpSituationMapper {
* @return 返回记录没有返回null
*/
AddUpSituation getById(Long id);
/**
* 新增插入所有字段
*
* @param addUpSituation 新增的记录
* @return 返回影响行数
*/
int insert(AddUpSituation addUpSituation);
/**
* 新增忽略null字段
*
* @param addUpSituation 新增的记录
* @return 返回影响行数
*/
int insertIgnoreNull(AddUpSituation addUpSituation);
/**
* 修改修改所有字段
*
* @param addUpSituation 修改的记录
* @return 返回影响行数
*/
int update(AddUpSituation addUpSituation);
/**
* 修改忽略null字段
*
* @param addUpSituation 修改的记录
* @return 返回影响行数
*/
int updateIgnoreNull(AddUpSituation addUpSituation);
/**
* 删除记录
*
* @param addUpSituation 待删除的记录
* @return 返回影响行数
*/
int delete(AddUpSituation addUpSituation);
/**
* 查询数据采集-累计专项附加扣除列表

View File

@ -16,6 +16,9 @@
<result column="add_up_subtraction" property="addUpSubtraction"/>
<result column="add_up_support_elderly" property="addUpSupportElderly"/>
<result column="add_up_tax_exempt_income" property="addUpTaxExemptIncome"/>
<result column="add_up_illness_medical" property="addUpIllnessMedical"/>
<result column="add_up_tax_savings" property="addUpTaxSavings"/>
<result column="add_up_infant_care" property="addUpInfantCare"/>
<result column="create_time" property="createTime"/>
<result column="creator" property="creator"/>
<result column="delete_type" property="deleteType"/>
@ -56,6 +59,9 @@
, t.tenant_key
, t.update_time
, t.year
, t.add_up_illness_medical
, t.add_up_tax_savings
, t.add_up_infant_care
</sql>
<!-- 查询全部 -->
@ -74,338 +80,6 @@
WHERE id = #{id} AND delete_type = 0
</select>
<!-- 插入全部字段 -->
<insert id="insert" parameterType="com.engine.salary.entity.datacollection.AddUpSituation"
keyProperty="id" keyColumn="id" useGeneratedKeys="true"
>
INSERT INTO hrsa_add_up_situation
<trim prefix="(" suffix=")" suffixOverrides=",">
add_up_accumulation_fund_total,
add_up_advance_tax,
add_up_allowed_donation,
add_up_child_education,
add_up_continuing_education,
add_up_enterprise_and_other,
add_up_housing_loan_interest,
add_up_housing_rent,
add_up_income,
add_up_other_deduction,
add_up_social_security_total,
add_up_subtraction,
add_up_support_elderly,
add_up_tax_exempt_income,
create_time,
creator,
delete_type,
employee_id,
id,
tax_agent_id,
tax_year_month,
tenant_key,
update_time,
year,
</trim>
<trim prefix="VALUES (" suffix=")" suffixOverrides=",">
#{addUpAccumulationFundTotal},
#{addUpAdvanceTax},
#{addUpAllowedDonation},
#{addUpChildEducation},
#{addUpContinuingEducation},
#{addUpEnterpriseAndOther},
#{addUpHousingLoanInterest},
#{addUpHousingRent},
#{addUpIncome},
#{addUpOtherDeduction},
#{addUpSocialSecurityTotal},
#{addUpSubtraction},
#{addUpSupportElderly},
#{addUpTaxExemptIncome},
#{createTime},
#{creator},
#{deleteType},
#{employeeId},
#{id},
#{taxAgentId},
#{taxYearMonth},
#{tenantKey},
#{updateTime},
#{year},
</trim>
</insert>
<!-- 插入不为NULL的字段 -->
<insert id="insertIgnoreNull" parameterType="com.engine.salary.entity.datacollection.AddUpSituation"
keyProperty="id" keyColumn="id" useGeneratedKeys="true"
>
INSERT INTO hrsa_add_up_situation
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="addUpAccumulationFundTotal != null">
add_up_accumulation_fund_total,
</if>
<if test="addUpAdvanceTax != null">
add_up_advance_tax,
</if>
<if test="addUpAllowedDonation != null">
add_up_allowed_donation,
</if>
<if test="addUpChildEducation != null">
add_up_child_education,
</if>
<if test="addUpContinuingEducation != null">
add_up_continuing_education,
</if>
<if test="addUpEnterpriseAndOther != null">
add_up_enterprise_and_other,
</if>
<if test="addUpHousingLoanInterest != null">
add_up_housing_loan_interest,
</if>
<if test="addUpHousingRent != null">
add_up_housing_rent,
</if>
<if test="addUpIncome != null">
add_up_income,
</if>
<if test="addUpOtherDeduction != null">
add_up_other_deduction,
</if>
<if test="addUpSocialSecurityTotal != null">
add_up_social_security_total,
</if>
<if test="addUpSubtraction != null">
add_up_subtraction,
</if>
<if test="addUpSupportElderly != null">
add_up_support_elderly,
</if>
<if test="addUpTaxExemptIncome != null">
add_up_tax_exempt_income,
</if>
<if test="createTime != null">
create_time,
</if>
<if test="creator != null">
creator,
</if>
<if test="deleteType != null">
delete_type,
</if>
<if test="employeeId != null">
employee_id,
</if>
<if test="id != null">
id,
</if>
<if test="taxAgentId != null">
tax_agent_id,
</if>
<if test="taxYearMonth != null">
tax_year_month,
</if>
<if test="tenantKey != null">
tenant_key,
</if>
<if test="updateTime != null">
update_time,
</if>
<if test="year != null">
year,
</if>
</trim>
<trim prefix="VALUES (" suffix=")" suffixOverrides=",">
<if test="addUpAccumulationFundTotal != null">
#{addUpAccumulationFundTotal},
</if>
<if test="addUpAdvanceTax != null">
#{addUpAdvanceTax},
</if>
<if test="addUpAllowedDonation != null">
#{addUpAllowedDonation},
</if>
<if test="addUpChildEducation != null">
#{addUpChildEducation},
</if>
<if test="addUpContinuingEducation != null">
#{addUpContinuingEducation},
</if>
<if test="addUpEnterpriseAndOther != null">
#{addUpEnterpriseAndOther},
</if>
<if test="addUpHousingLoanInterest != null">
#{addUpHousingLoanInterest},
</if>
<if test="addUpHousingRent != null">
#{addUpHousingRent},
</if>
<if test="addUpIncome != null">
#{addUpIncome},
</if>
<if test="addUpOtherDeduction != null">
#{addUpOtherDeduction},
</if>
<if test="addUpSocialSecurityTotal != null">
#{addUpSocialSecurityTotal},
</if>
<if test="addUpSubtraction != null">
#{addUpSubtraction},
</if>
<if test="addUpSupportElderly != null">
#{addUpSupportElderly},
</if>
<if test="addUpTaxExemptIncome != null">
#{addUpTaxExemptIncome},
</if>
<if test="createTime != null">
#{createTime},
</if>
<if test="creator != null">
#{creator},
</if>
<if test="deleteType != null">
#{deleteType},
</if>
<if test="employeeId != null">
#{employeeId},
</if>
<if test="id != null">
#{id},
</if>
<if test="taxAgentId != null">
#{taxAgentId},
</if>
<if test="taxYearMonth != null">
#{taxYearMonth},
</if>
<if test="tenantKey != null">
#{tenantKey},
</if>
<if test="updateTime != null">
#{updateTime},
</if>
<if test="year != null">
#{year},
</if>
</trim>
</insert>
<!-- 更新,更新全部字段 -->
<update id="update" parameterType="com.engine.salary.entity.datacollection.AddUpSituation">
UPDATE hrsa_add_up_situation
<set>
add_up_accumulation_fund_total=#{addUpAccumulationFundTotal},
add_up_advance_tax=#{addUpAdvanceTax},
add_up_allowed_donation=#{addUpAllowedDonation},
add_up_child_education=#{addUpChildEducation},
add_up_continuing_education=#{addUpContinuingEducation},
add_up_enterprise_and_other=#{addUpEnterpriseAndOther},
add_up_housing_loan_interest=#{addUpHousingLoanInterest},
add_up_housing_rent=#{addUpHousingRent},
add_up_income=#{addUpIncome},
add_up_other_deduction=#{addUpOtherDeduction},
add_up_social_security_total=#{addUpSocialSecurityTotal},
add_up_subtraction=#{addUpSubtraction},
add_up_support_elderly=#{addUpSupportElderly},
add_up_tax_exempt_income=#{addUpTaxExemptIncome},
create_time=#{createTime},
creator=#{creator},
delete_type=#{deleteType},
employee_id=#{employeeId},
tax_agent_id=#{taxAgentId},
tax_year_month=#{taxYearMonth},
tenant_key=#{tenantKey},
update_time=#{updateTime},
year=#{year},
</set>
WHERE id = #{id} AND delete_type = 0
</update>
<!-- 更新不为NULL的字段 -->
<update id="updateIgnoreNull" parameterType="com.engine.salary.entity.datacollection.AddUpSituation">
UPDATE hrsa_add_up_situation
<set>
<if test="addUpAccumulationFundTotal != null">
add_up_accumulation_fund_total=#{addUpAccumulationFundTotal},
</if>
<if test="addUpAdvanceTax != null">
add_up_advance_tax=#{addUpAdvanceTax},
</if>
<if test="addUpAllowedDonation != null">
add_up_allowed_donation=#{addUpAllowedDonation},
</if>
<if test="addUpChildEducation != null">
add_up_child_education=#{addUpChildEducation},
</if>
<if test="addUpContinuingEducation != null">
add_up_continuing_education=#{addUpContinuingEducation},
</if>
<if test="addUpEnterpriseAndOther != null">
add_up_enterprise_and_other=#{addUpEnterpriseAndOther},
</if>
<if test="addUpHousingLoanInterest != null">
add_up_housing_loan_interest=#{addUpHousingLoanInterest},
</if>
<if test="addUpHousingRent != null">
add_up_housing_rent=#{addUpHousingRent},
</if>
<if test="addUpIncome != null">
add_up_income=#{addUpIncome},
</if>
<if test="addUpOtherDeduction != null">
add_up_other_deduction=#{addUpOtherDeduction},
</if>
<if test="addUpSocialSecurityTotal != null">
add_up_social_security_total=#{addUpSocialSecurityTotal},
</if>
<if test="addUpSubtraction != null">
add_up_subtraction=#{addUpSubtraction},
</if>
<if test="addUpSupportElderly != null">
add_up_support_elderly=#{addUpSupportElderly},
</if>
<if test="addUpTaxExemptIncome != null">
add_up_tax_exempt_income=#{addUpTaxExemptIncome},
</if>
<if test="createTime != null">
create_time=#{createTime},
</if>
<if test="creator != null">
creator=#{creator},
</if>
<if test="deleteType != null">
delete_type=#{deleteType},
</if>
<if test="employeeId != null">
employee_id=#{employeeId},
</if>
<if test="taxAgentId != null">
tax_agent_id=#{taxAgentId},
</if>
<if test="taxYearMonth != null">
tax_year_month=#{taxYearMonth},
</if>
<if test="tenantKey != null">
tenant_key=#{tenantKey},
</if>
<if test="updateTime != null">
update_time=#{updateTime},
</if>
<if test="year != null">
year=#{year},
</if>
</set>
WHERE id = #{id} AND delete_type = 0
</update>
<!-- 根据主键删除记录 -->
<delete id="delete" parameterType="com.engine.salary.entity.datacollection.AddUpSituation">
UPDATE hrsa_add_up_situation
SET delete_type=1
WHERE id = #{id}
AND delete_type = 0
</delete>
<sql id="addUpSituationColumn">
t1
@ -429,10 +103,13 @@
t1.add_up_housing_loan_interest,
t1.add_up_housing_rent,
t1.add_up_support_elderly,
t1.add_up_illness_medical,
t1.add_up_infant_care,
t1.add_up_enterprise_and_other,
t1.add_up_other_deduction,
t1.add_up_tax_exempt_income,
t1.add_up_allowed_donation,
t1.add_up_tax_savings,
t1.add_up_advance_tax
</sql>
@ -709,7 +386,10 @@
create_time,
update_time,
creator,
tenant_key
tenant_key,
add_up_tax_savings,
add_up_illness_medical,
add_up_infant_care
)
VALUES
<foreach collection="collection" item="item" separator=",">
@ -735,7 +415,10 @@
#{item.createTime},
#{item.updateTime},
#{item.creator},
#{item.tenantKey}
#{item.tenantKey},
#{item.addUpTaxSavings},
#{item.addUpIllnessMedical},
#{item.addUpInfantCare}
)
</foreach>
</insert>
@ -762,7 +445,10 @@
create_time,
update_time,
creator,
tenant_key
tenant_key,
add_up_tax_savings,
add_up_illness_medical,
add_up_infant_care
)
<foreach collection="collection" item="item" separator="union all">
@ -788,37 +474,43 @@
#{item.createTime},
#{item.updateTime},
#{item.creator},
#{item.tenantKey}
#{item.tenantKey},
#{item.addUpTaxSavings},
#{item.addUpIllnessMedical},
#{item.addUpInfantCare}
from dual
</foreach>
</insert>
<insert id="insertData" databaseId="sqlserver">
<foreach collection="collection" item="item" separator=";">
INSERT INTO hrsa_add_up_situation(
employee_id,
tax_agent_id,
tax_year_month,
year,
add_up_income,
add_up_subtraction,
add_up_social_security_total,
add_up_accumulation_fund_total,
add_up_child_education,
add_up_continuing_education,
add_up_housing_loan_interest,
add_up_housing_rent,
add_up_support_elderly,
add_up_enterprise_and_other,
add_up_other_deduction,
add_up_tax_exempt_income,
add_up_allowed_donation,
add_up_advance_tax,
create_time,
update_time,
creator,
tenant_key
)
VALUES
INSERT INTO hrsa_add_up_situation(
employee_id,
tax_agent_id,
tax_year_month,
year,
add_up_income,
add_up_subtraction,
add_up_social_security_total,
add_up_accumulation_fund_total,
add_up_child_education,
add_up_continuing_education,
add_up_housing_loan_interest,
add_up_housing_rent,
add_up_support_elderly,
add_up_enterprise_and_other,
add_up_other_deduction,
add_up_tax_exempt_income,
add_up_allowed_donation,
add_up_advance_tax,
create_time,
update_time,
creator,
tenant_key,
add_up_tax_savings,
add_up_illness_medical,
add_up_infant_care
)
VALUES
(
#{item.employeeId},
#{item.taxAgentId},
@ -841,7 +533,10 @@
#{item.createTime},
#{item.updateTime},
#{item.creator},
#{item.tenantKey}
#{item.tenantKey},
#{item.addUpTaxSavings},
#{item.addUpIllnessMedical},
#{item.addUpInfantCare}
)
</foreach>
</insert>
@ -947,6 +642,27 @@
</if>
</foreach>
</trim>
<trim prefix="add_up_tax_savings =case" suffix="end,">
<foreach collection="collection" item="item" index="index">
<if test="item.addUpTaxSavings!=null">
when id=#{item.id} then #{item.addUpTaxSavings}
</if>
</foreach>
</trim>
<trim prefix="add_up_illness_medical =case" suffix="end,">
<foreach collection="collection" item="item" index="index">
<if test="item.addUpIllnessMedical!=null">
when id=#{item.id} then #{item.addUpIllnessMedical}
</if>
</foreach>
</trim>
<trim prefix="add_up_infant_care =case" suffix="end,">
<foreach collection="collection" item="item" index="index">
<if test="item.addUpInfantCare!=null">
when id=#{item.id} then #{item.addUpInfantCare}
</if>
</foreach>
</trim>
</trim>
where
id in
@ -961,7 +677,7 @@
FROM hrsa_add_up_situation t
WHERE delete_type = 0
<if test="param.taxYearMonth != null">
and tax_year_month = #{param.taxYearMonth}
and tax_year_month = #{param.taxYearMonth}
</if>
<if test="param.employeeIds != null and param.employeeIds.size()>0">
AND employee_id IN

View File

@ -19,6 +19,7 @@ import com.engine.salary.util.excel.ExcelUtil;
import com.google.common.collect.Lists;
import org.apache.commons.collections4.CollectionUtils;
import org.apache.poi.xssf.usermodel.XSSFWorkbook;
import weaver.general.Util;
import java.time.YearMonth;
import java.util.*;
@ -127,7 +128,8 @@ public class AddUpDeductionServiceImpl extends Service implements AddUpDeduction
SalaryI18nUtil.getI18nLabel(86324, "累计住房贷款利息"),
SalaryI18nUtil.getI18nLabel(86325, "累计住房租金"),
SalaryI18nUtil.getI18nLabel(86326, "累计赡养老人"),
SalaryI18nUtil.getI18nLabel(105142, "累计大病医疗")
SalaryI18nUtil.getI18nLabel(105142, "累计大病医疗"),
SalaryI18nUtil.getI18nLabel(105142, "累计婴幼儿照护")
};
List<Object> headerList = Arrays.asList(header);
// 2.表头
@ -146,19 +148,20 @@ public class AddUpDeductionServiceImpl extends Service implements AddUpDeduction
rows.add(headerList);
for (AddUpDeductionDTO dto : list) {
List<Object> row = new ArrayList<>();
row.add(dto.getUsername());
row.add(dto.getTaxAgentName());
row.add(dto.getDepartmentName());
row.add(dto.getMobile());
row.add(dto.getJobNum());
row.add(dto.getIdNo());
row.add(dto.getHiredate());
row.add(dto.getAddUpChildEducation());
row.add(dto.getAddUpContinuingEducation());
row.add(dto.getAddUpHousingLoanInterest());
row.add(dto.getAddUpHousingRent());
row.add(dto.getAddUpSupportElderly());
row.add(dto.getAddUpIllnessMedical());
row.add(Util.null2String(dto.getUsername()));
row.add(Util.null2String(dto.getTaxAgentName()));
row.add(Util.null2String(dto.getDepartmentName()));
row.add(Util.null2String(dto.getMobile()));
row.add(Util.null2String(dto.getJobNum()));
row.add(Util.null2String(dto.getIdNo()));
row.add(Util.null2String(dto.getHiredate()));
row.add(Util.null2String(dto.getAddUpChildEducation()));
row.add(Util.null2String(dto.getAddUpContinuingEducation()));
row.add(Util.null2String(dto.getAddUpHousingLoanInterest()));
row.add(Util.null2String(dto.getAddUpHousingRent()));
row.add(Util.null2String(dto.getAddUpSupportElderly()));
row.add(Util.null2String(dto.getAddUpIllnessMedical()));
row.add(Util.null2String(dto.getAddUpInfantCare()));
rows.add(row);
}
@ -172,6 +175,7 @@ public class AddUpDeductionServiceImpl extends Service implements AddUpDeduction
excelComments.add(new ExcelComment(10, 0, 13, 2, SalaryI18nUtil.getI18nLabel(100344, "输入数字")));
excelComments.add(new ExcelComment(11, 0, 14, 2, SalaryI18nUtil.getI18nLabel(100344, "输入数字")));
excelComments.add(new ExcelComment(12, 0, 15, 2, SalaryI18nUtil.getI18nLabel(100344, "输入数字")));
excelComments.add(new ExcelComment(13, 0, 16, 2, SalaryI18nUtil.getI18nLabel(100344, "输入数字")));
XSSFWorkbook book = ExcelUtil.genWorkbookV2(rows, sheetName, excelComments);

View File

@ -19,6 +19,7 @@ import com.engine.salary.util.excel.ExcelUtil;
import com.google.common.collect.Lists;
import org.apache.commons.collections4.CollectionUtils;
import org.apache.poi.xssf.usermodel.XSSFWorkbook;
import weaver.general.Util;
import java.time.YearMonth;
import java.util.*;
@ -143,7 +144,8 @@ public class AddUpSituationServiceImpl extends Service implements AddUpSituation
SalaryI18nUtil.getI18nLabel(86704, "累计免税收入"),
SalaryI18nUtil.getI18nLabel(86703, "累计准予扣除的捐赠额"),
SalaryI18nUtil.getI18nLabel(105478, "累计减免税额"),
SalaryI18nUtil.getI18nLabel(86702, "累计已预扣预缴税额")
SalaryI18nUtil.getI18nLabel(86702, "累计已预扣预缴税额"),
SalaryI18nUtil.getI18nLabel(86702, "累计婴幼儿照护")
};
// 2.表头
List<Object> headerList = Arrays.asList(header);
@ -160,29 +162,30 @@ public class AddUpSituationServiceImpl extends Service implements AddUpSituation
rows.add(headerList);
for (AddUpSituationDTO dto : list) {
List<Object> row = new ArrayList<>();
row.add(dto.getUsername());
row.add(dto.getTaxAgentName());
row.add(dto.getDepartmentName());
row.add(dto.getMobile());
row.add(dto.getJobNum());
row.add(dto.getIdNo());
row.add(dto.getHiredate() + "");
row.add(dto.getAddUpIncome());
row.add(dto.getAddUpSubtraction());
row.add(dto.getAddUpSocialSecurityTotal());
row.add(dto.getAddUpAccumulationFundTotal());
row.add(dto.getAddUpChildEducation());
row.add(dto.getAddUpContinuingEducation());
row.add(dto.getAddUpHousingLoanInterest());
row.add(dto.getAddUpHousingRent());
row.add(dto.getAddUpSupportElderly());
row.add(dto.getAddUpIllnessMedical());
row.add(dto.getAddUpEnterpriseAndOther());
row.add(dto.getAddUpOtherDeduction());
row.add(dto.getAddUpTaxExemptIncome());
row.add(dto.getAddUpAllowedDonation());
row.add(dto.getAddUpTaxSavings());
row.add(dto.getAddUpAdvanceTax());
row.add(Util.null2String(dto.getUsername()));
row.add(Util.null2String(dto.getTaxAgentName()));
row.add(Util.null2String(dto.getDepartmentName()));
row.add(Util.null2String(dto.getMobile()));
row.add(Util.null2String(dto.getJobNum()));
row.add(Util.null2String(dto.getIdNo()));
row.add(Util.null2String(dto.getHiredate()));
row.add(Util.null2String(dto.getAddUpIncome()));
row.add(Util.null2String(dto.getAddUpSubtraction()));
row.add(Util.null2String(dto.getAddUpSocialSecurityTotal()));
row.add(Util.null2String(dto.getAddUpAccumulationFundTotal()));
row.add(Util.null2String(dto.getAddUpChildEducation()));
row.add(Util.null2String(dto.getAddUpContinuingEducation()));
row.add(Util.null2String(dto.getAddUpHousingLoanInterest()));
row.add(Util.null2String(dto.getAddUpHousingRent()));
row.add(Util.null2String(dto.getAddUpSupportElderly()));
row.add(Util.null2String(dto.getAddUpIllnessMedical()));
row.add(Util.null2String(dto.getAddUpEnterpriseAndOther()));
row.add(Util.null2String(dto.getAddUpOtherDeduction()));
row.add(Util.null2String(dto.getAddUpTaxExemptIncome()));
row.add(Util.null2String(dto.getAddUpAllowedDonation()));
row.add(Util.null2String(dto.getAddUpTaxSavings()));
row.add(Util.null2String(dto.getAddUpAdvanceTax()));
row.add(Util.null2String(dto.getAddUpInfantCare()));
rows.add(row);
}
// 4.注释
@ -205,6 +208,7 @@ public class AddUpSituationServiceImpl extends Service implements AddUpSituation
excelComments.add(new ExcelComment(20, 0, 25, 2, SalaryI18nUtil.getI18nLabel(100344, "输入数字")));
excelComments.add(new ExcelComment(21, 0, 26, 2, SalaryI18nUtil.getI18nLabel(100344, "输入数字")));
excelComments.add(new ExcelComment(22, 0, 27, 2, SalaryI18nUtil.getI18nLabel(100344, "输入数字")));
excelComments.add(new ExcelComment(23, 0, 28, 2, SalaryI18nUtil.getI18nLabel(100344, "输入数字")));
XSSFWorkbook book = ExcelUtil.genWorkbookV2(rows, sheetName, excelComments);

View File

@ -19,6 +19,7 @@ import com.engine.salary.util.excel.ExcelUtil;
import com.google.common.collect.Lists;
import org.apache.commons.collections4.CollectionUtils;
import org.apache.poi.xssf.usermodel.XSSFWorkbook;
import weaver.general.Util;
import java.time.YearMonth;
import java.util.*;
@ -146,17 +147,17 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
rows.add(headerList);
for (OtherDeductionListDTO dto : list) {
List<Object> row = new ArrayList<>();
row.add(dto.getUsername());
row.add(dto.getTaxAgentName());
row.add(dto.getDepartmentName());
row.add(dto.getMobile());
row.add(dto.getJobNum());
row.add(dto.getIdNo());
row.add(dto.getHiredate()+"");
row.add(dto.getBusinessHealthyInsurance());
row.add(dto.getTaxDelayEndowmentInsurance());
row.add(dto.getOtherDeduction());
row.add(dto.getDeductionAllowedDonation());
row.add(Util.null2String(dto.getUsername()));
row.add(Util.null2String(dto.getTaxAgentName()));
row.add(Util.null2String(dto.getDepartmentName()));
row.add(Util.null2String(dto.getMobile()));
row.add(Util.null2String(dto.getJobNum()));
row.add(Util.null2String(dto.getIdNo()));
row.add(Util.null2String(dto.getHiredate()));
row.add(Util.null2String(dto.getBusinessHealthyInsurance()));
row.add(Util.null2String(dto.getTaxDelayEndowmentInsurance()));
row.add(Util.null2String(dto.getOtherDeduction()));
row.add(Util.null2String(dto.getDeductionAllowedDonation()));
rows.add(row);
}
// 3.表数据