免税收入附表
This commit is contained in:
parent
8c83e8ed6c
commit
d14ac4bda3
|
|
@ -82,35 +82,51 @@ public class OtherDeductionListDTO {
|
||||||
@TableTitle(title = "入职日期", dataIndex = "hiredate", key = "hiredate")
|
@TableTitle(title = "入职日期", dataIndex = "hiredate", key = "hiredate")
|
||||||
private String hiredate;
|
private String hiredate;
|
||||||
|
|
||||||
//商业健康保险
|
/**
|
||||||
|
* 免税收入
|
||||||
|
*/
|
||||||
@ExcelProperty(index = 7)
|
@ExcelProperty(index = 7)
|
||||||
|
@SalaryTableColumn(text = "免税收入", width = "10%", column = "freeIncome")
|
||||||
|
@TableTitle(title = "免税收入", dataIndex = "freeIncome", key = "freeIncome")
|
||||||
|
private String freeIncome;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 减免税额
|
||||||
|
*/
|
||||||
|
@ExcelProperty(index = 8)
|
||||||
|
@SalaryTableColumn(text = "入职日期", width = "10%", column = "derateDeduction")
|
||||||
|
@TableTitle(title = "减免税额", dataIndex = "derateDeduction", key = "derateDeduction")
|
||||||
|
private String derateDeduction;
|
||||||
|
|
||||||
|
//商业健康保险
|
||||||
|
@ExcelProperty(index = 9)
|
||||||
@SalaryTableColumn(text = "商业健康保险", width = "10%", column = "businessHealthyInsurance")
|
@SalaryTableColumn(text = "商业健康保险", width = "10%", column = "businessHealthyInsurance")
|
||||||
@TableTitle(title = "商业健康保险", dataIndex = "businessHealthyInsurance", key = "businessHealthyInsurance")
|
@TableTitle(title = "商业健康保险", dataIndex = "businessHealthyInsurance", key = "businessHealthyInsurance")
|
||||||
@Encrypt
|
@Encrypt
|
||||||
private String businessHealthyInsurance;
|
private String businessHealthyInsurance;
|
||||||
|
|
||||||
//税延养老保险
|
//税延养老保险
|
||||||
@ExcelProperty(index = 8)
|
@ExcelProperty(index = 10)
|
||||||
@SalaryTableColumn(text = "税延养老保险", width = "10%", column = "taxDelayEndowmentInsurance")
|
@SalaryTableColumn(text = "税延养老保险", width = "10%", column = "taxDelayEndowmentInsurance")
|
||||||
@TableTitle(title = "税延养老保险", dataIndex = "taxDelayEndowmentInsurance", key = "taxDelayEndowmentInsurance")
|
@TableTitle(title = "税延养老保险", dataIndex = "taxDelayEndowmentInsurance", key = "taxDelayEndowmentInsurance")
|
||||||
@Encrypt
|
@Encrypt
|
||||||
private String taxDelayEndowmentInsurance;
|
private String taxDelayEndowmentInsurance;
|
||||||
|
|
||||||
//其他
|
//其他
|
||||||
@ExcelProperty(index = 9)
|
@ExcelProperty(index = 11)
|
||||||
@SalaryTableColumn(text = "其他", width = "10%", column = "otherDeduction")
|
@SalaryTableColumn(text = "其他", width = "10%", column = "otherDeduction")
|
||||||
@TableTitle(title = "其他", dataIndex = "otherDeduction", key = "otherDeduction")
|
@TableTitle(title = "其他", dataIndex = "otherDeduction", key = "otherDeduction")
|
||||||
@Encrypt
|
@Encrypt
|
||||||
private String otherDeduction;
|
private String otherDeduction;
|
||||||
|
|
||||||
//准予扣除的捐赠额
|
//准予扣除的捐赠额
|
||||||
@ExcelProperty(index = 10)
|
@ExcelProperty(index = 12)
|
||||||
@SalaryTableColumn(text = "准予扣除的捐赠额", width = "10%", column = "deductionAllowedDonation")
|
@SalaryTableColumn(text = "准予扣除的捐赠额", width = "10%", column = "deductionAllowedDonation")
|
||||||
@TableTitle(title = "准予扣除的捐赠额", dataIndex = "deductionAllowedDonation", key = "deductionAllowedDonation")
|
@TableTitle(title = "准予扣除的捐赠额", dataIndex = "deductionAllowedDonation", key = "deductionAllowedDonation")
|
||||||
@Encrypt
|
@Encrypt
|
||||||
private String deductionAllowedDonation;
|
private String deductionAllowedDonation;
|
||||||
|
|
||||||
@ExcelProperty(index = 11)
|
@ExcelProperty(index = 13)
|
||||||
@SalaryTableColumn(text = "个人养老金", width = "10%", column = "privatePension")
|
@SalaryTableColumn(text = "个人养老金", width = "10%", column = "privatePension")
|
||||||
@TableTitle(title = "个人养老金", dataIndex = "privatePension", key = "privatePension")
|
@TableTitle(title = "个人养老金", dataIndex = "privatePension", key = "privatePension")
|
||||||
@Encrypt
|
@Encrypt
|
||||||
|
|
|
||||||
|
|
@ -71,6 +71,18 @@ public class OtherDeductionRecordDTO {
|
||||||
@TableTitle(title = "工号", dataIndex = "jobNum", key = "jobNum")
|
@TableTitle(title = "工号", dataIndex = "jobNum", key = "jobNum")
|
||||||
private String jobNum;
|
private String jobNum;
|
||||||
|
|
||||||
|
//免税收入
|
||||||
|
@SalaryTableColumn(text = "免税收入", width = "10%", column = "freeIncome")
|
||||||
|
@TableTitle(title = "免税收入", dataIndex = "freeIncome", key = "freeIncome")
|
||||||
|
@Encrypt
|
||||||
|
private String freeIncome;
|
||||||
|
|
||||||
|
//减免税额
|
||||||
|
@SalaryTableColumn(text = "减免税额", width = "10%", column = "derateDeduction")
|
||||||
|
@TableTitle(title = "减免税额", dataIndex = "derateDeduction", key = "derateDeduction")
|
||||||
|
@Encrypt
|
||||||
|
private String derateDeduction;
|
||||||
|
|
||||||
//商业健康保险
|
//商业健康保险
|
||||||
@SalaryTableColumn(text = "商业健康保险", width = "10%", column = "businessHealthyInsurance")
|
@SalaryTableColumn(text = "商业健康保险", width = "10%", column = "businessHealthyInsurance")
|
||||||
@TableTitle(title = "商业健康保险", dataIndex = "businessHealthyInsurance", key = "businessHealthyInsurance")
|
@TableTitle(title = "商业健康保险", dataIndex = "businessHealthyInsurance", key = "businessHealthyInsurance")
|
||||||
|
|
|
||||||
|
|
@ -44,6 +44,16 @@ public class OtherDeductionParam {
|
||||||
// 工号
|
// 工号
|
||||||
private String jobNum;
|
private String jobNum;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 免税收入
|
||||||
|
*/
|
||||||
|
private String freeIncome;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 减免税额
|
||||||
|
*/
|
||||||
|
private String derateDeduction;
|
||||||
|
|
||||||
// 商业健康保险
|
// 商业健康保险
|
||||||
private String businessHealthyInsurance;
|
private String businessHealthyInsurance;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -54,6 +54,13 @@ public class OtherDeductionPO {
|
||||||
@Encrypt
|
@Encrypt
|
||||||
private String freeIncome;
|
private String freeIncome;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 减免税额
|
||||||
|
*/
|
||||||
|
@ElogTransform(name = "减免税额")
|
||||||
|
@SalaryFormulaVar(defaultLabel = "减免税额", labelId = 102810, dataType = "number")
|
||||||
|
@Encrypt
|
||||||
|
private String derateDeduction;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 商业健康保险
|
* 商业健康保险
|
||||||
|
|
@ -71,13 +78,6 @@ public class OtherDeductionPO {
|
||||||
@Encrypt
|
@Encrypt
|
||||||
private String taxDelayEndowmentInsurance;
|
private String taxDelayEndowmentInsurance;
|
||||||
|
|
||||||
/**
|
|
||||||
* 减免税额
|
|
||||||
*/
|
|
||||||
@ElogTransform(name = "减免税额")
|
|
||||||
@SalaryFormulaVar(defaultLabel = "减免税额", labelId = 102810, dataType = "number")
|
|
||||||
@Encrypt
|
|
||||||
private String derateDeduction;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 其他
|
* 其他
|
||||||
|
|
|
||||||
|
|
@ -7,7 +7,6 @@ import lombok.Builder;
|
||||||
import lombok.Data;
|
import lombok.Data;
|
||||||
import lombok.NoArgsConstructor;
|
import lombok.NoArgsConstructor;
|
||||||
|
|
||||||
import java.time.LocalDateTime;
|
|
||||||
import java.util.Date;
|
import java.util.Date;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -58,10 +57,10 @@ public class OtherDerateDeductionPO {
|
||||||
private Integer employeeType;
|
private Integer employeeType;
|
||||||
|
|
||||||
@ElogTransform(name = "创建时间", ignore = true)
|
@ElogTransform(name = "创建时间", ignore = true)
|
||||||
private LocalDateTime createTime;
|
private Date createTime;
|
||||||
|
|
||||||
@ElogTransform(name = "更新时间", ignore = true)
|
@ElogTransform(name = "更新时间", ignore = true)
|
||||||
private LocalDateTime updateTime;
|
private Date updateTime;
|
||||||
|
|
||||||
@ElogTransform(name = "创建人", ignore = true)
|
@ElogTransform(name = "创建人", ignore = true)
|
||||||
private Long creator;
|
private Long creator;
|
||||||
|
|
|
||||||
|
|
@ -16,6 +16,8 @@
|
||||||
<result column="delete_type" property="deleteType"/>
|
<result column="delete_type" property="deleteType"/>
|
||||||
<result column="tenant_key" property="tenantKey"/>
|
<result column="tenant_key" property="tenantKey"/>
|
||||||
<result column="private_pension" property="privatePension"/>
|
<result column="private_pension" property="privatePension"/>
|
||||||
|
<result column="free_income" property="freeIncome"/>
|
||||||
|
<result column="derate_deduction" property="derateDeduction"/>
|
||||||
</resultMap>
|
</resultMap>
|
||||||
|
|
||||||
<!-- 表字段 -->
|
<!-- 表字段 -->
|
||||||
|
|
@ -36,6 +38,8 @@
|
||||||
, t.delete_type
|
, t.delete_type
|
||||||
, t.tenant_key
|
, t.tenant_key
|
||||||
, t.private_pension
|
, t.private_pension
|
||||||
|
, t.free_income
|
||||||
|
, t.derate_deduction
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<!--批量删除-->
|
<!--批量删除-->
|
||||||
|
|
@ -59,8 +63,6 @@
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<sql id="otherDeductionColumn">
|
<sql id="otherDeductionColumn">
|
||||||
t1
|
t1
|
||||||
.
|
.
|
||||||
|
|
@ -80,7 +82,9 @@
|
||||||
t1.tax_delay_endowment_insurance,
|
t1.tax_delay_endowment_insurance,
|
||||||
t1.other_deduction,
|
t1.other_deduction,
|
||||||
t1.deduction_allowed_donation,
|
t1.deduction_allowed_donation,
|
||||||
t1.private_pension
|
t1.private_pension,
|
||||||
|
t1.free_income,
|
||||||
|
t1.derate_deduction
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<sql id="paramSql">
|
<sql id="paramSql">
|
||||||
|
|
@ -284,7 +288,7 @@
|
||||||
<include refid="paramSql"/>
|
<include refid="paramSql"/>
|
||||||
<!-- 排序 -->
|
<!-- 排序 -->
|
||||||
<if test="param.orderRule != null">
|
<if test="param.orderRule != null">
|
||||||
ORDER BY ${param.orderRule.orderRule} ${param.orderRule.ascOrDesc}
|
ORDER BY ${param.orderRule.orderRule} ${param.orderRule.ascOrDesc}
|
||||||
</if>
|
</if>
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
|
@ -310,7 +314,7 @@
|
||||||
FROM hrsa_other_deduction t
|
FROM hrsa_other_deduction t
|
||||||
WHERE delete_type = 0
|
WHERE delete_type = 0
|
||||||
<if test="param.declareMonth != null">
|
<if test="param.declareMonth != null">
|
||||||
and declare_month = #{param.declareMonth}
|
and declare_month = #{param.declareMonth}
|
||||||
</if>
|
</if>
|
||||||
<if test="param.employeeIds != null and param.employeeIds.size()>0">
|
<if test="param.employeeIds != null and param.employeeIds.size()>0">
|
||||||
AND t.employee_id IN
|
AND t.employee_id IN
|
||||||
|
|
@ -336,6 +340,8 @@
|
||||||
other_deduction,
|
other_deduction,
|
||||||
deduction_allowed_donation,
|
deduction_allowed_donation,
|
||||||
private_pension,
|
private_pension,
|
||||||
|
free_income,
|
||||||
|
derate_deduction,
|
||||||
create_time,
|
create_time,
|
||||||
update_time,
|
update_time,
|
||||||
creator,
|
creator,
|
||||||
|
|
@ -352,6 +358,8 @@
|
||||||
#{item.otherDeduction},
|
#{item.otherDeduction},
|
||||||
#{item.deductionAllowedDonation},
|
#{item.deductionAllowedDonation},
|
||||||
#{item.privatePension},
|
#{item.privatePension},
|
||||||
|
#{item.freeIncome},
|
||||||
|
#{item.derateDeduction},
|
||||||
#{item.createTime},
|
#{item.createTime},
|
||||||
#{item.updateTime},
|
#{item.updateTime},
|
||||||
#{item.creator},
|
#{item.creator},
|
||||||
|
|
@ -369,6 +377,8 @@
|
||||||
other_deduction,
|
other_deduction,
|
||||||
deduction_allowed_donation,
|
deduction_allowed_donation,
|
||||||
private_pension,
|
private_pension,
|
||||||
|
free_income,
|
||||||
|
derate_deduction,
|
||||||
create_time,
|
create_time,
|
||||||
update_time,
|
update_time,
|
||||||
creator,
|
creator,
|
||||||
|
|
@ -385,6 +395,8 @@
|
||||||
#{item.otherDeduction,jdbcType=VARCHAR},
|
#{item.otherDeduction,jdbcType=VARCHAR},
|
||||||
#{item.deductionAllowedDonation,jdbcType=VARCHAR},
|
#{item.deductionAllowedDonation,jdbcType=VARCHAR},
|
||||||
#{item.privatePension,jdbcType=VARCHAR},
|
#{item.privatePension,jdbcType=VARCHAR},
|
||||||
|
#{item.freeIncome,jdbcType=VARCHAR},
|
||||||
|
#{item.derateDeduction,jdbcType=VARCHAR},
|
||||||
#{item.createTime,jdbcType=DATE},
|
#{item.createTime,jdbcType=DATE},
|
||||||
#{item.updateTime,jdbcType=DATE},
|
#{item.updateTime,jdbcType=DATE},
|
||||||
#{item.creator,jdbcType=DOUBLE},
|
#{item.creator,jdbcType=DOUBLE},
|
||||||
|
|
@ -394,21 +406,23 @@
|
||||||
</insert>
|
</insert>
|
||||||
<insert id="insertData" databaseId="sqlserver">
|
<insert id="insertData" databaseId="sqlserver">
|
||||||
<foreach collection="collection" item="item" separator=";">
|
<foreach collection="collection" item="item" separator=";">
|
||||||
INSERT INTO hrsa_other_deduction(
|
INSERT INTO hrsa_other_deduction(
|
||||||
employee_id,
|
employee_id,
|
||||||
tax_agent_id,
|
tax_agent_id,
|
||||||
declare_month,
|
declare_month,
|
||||||
business_healthy_insurance,
|
business_healthy_insurance,
|
||||||
tax_delay_endowment_insurance,
|
tax_delay_endowment_insurance,
|
||||||
other_deduction,
|
other_deduction,
|
||||||
deduction_allowed_donation,
|
deduction_allowed_donation,
|
||||||
private_pension,
|
private_pension,
|
||||||
create_time,
|
free_income,
|
||||||
update_time,
|
derate_deduction,
|
||||||
creator,
|
create_time,
|
||||||
tenant_key
|
update_time,
|
||||||
)
|
creator,
|
||||||
VALUES
|
tenant_key
|
||||||
|
)
|
||||||
|
VALUES
|
||||||
(
|
(
|
||||||
#{item.employeeId},
|
#{item.employeeId},
|
||||||
#{item.taxAgentId},
|
#{item.taxAgentId},
|
||||||
|
|
@ -418,6 +432,8 @@
|
||||||
#{item.otherDeduction},
|
#{item.otherDeduction},
|
||||||
#{item.deductionAllowedDonation},
|
#{item.deductionAllowedDonation},
|
||||||
#{item.privatePension},
|
#{item.privatePension},
|
||||||
|
#{item.freeIncome},
|
||||||
|
#{item.derateDeduction},
|
||||||
#{item.createTime},
|
#{item.createTime},
|
||||||
#{item.updateTime},
|
#{item.updateTime},
|
||||||
#{item.creator},
|
#{item.creator},
|
||||||
|
|
@ -464,6 +480,20 @@
|
||||||
</if>
|
</if>
|
||||||
</foreach>
|
</foreach>
|
||||||
</trim>
|
</trim>
|
||||||
|
<trim prefix="free_income =case" suffix="end,">
|
||||||
|
<foreach collection="collection" item="item" index="index">
|
||||||
|
<if test="item.freeIncome!=null">
|
||||||
|
when id=#{item.id} then #{item.freeIncome}
|
||||||
|
</if>
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="free_income =case" suffix="end,">
|
||||||
|
<foreach collection="collection" item="item" index="index">
|
||||||
|
<if test="item.derateDeduction!=null">
|
||||||
|
when id=#{item.id} then #{item.derateDeduction}
|
||||||
|
</if>
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
<trim prefix="update_time =case" suffix="end,">
|
<trim prefix="update_time =case" suffix="end,">
|
||||||
<foreach collection="collection" item="item" index="index">
|
<foreach collection="collection" item="item" index="index">
|
||||||
<if test="item.updateTime!=null">
|
<if test="item.updateTime!=null">
|
||||||
|
|
|
||||||
|
|
@ -1,26 +1,28 @@
|
||||||
<?xml version="1.0" encoding="UTF-8" ?>
|
<?xml version="1.0" encoding="UTF-8" ?>
|
||||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
|
||||||
<mapper namespace="com.engine.salary.mapper.OtherDerateDeductionMapper">
|
<mapper namespace="com.engine.salary.mapper.datacollection.OtherDerateDeductionMapper">
|
||||||
<resultMap id="BaseResultMap" type="com.engine.salary.entity.OtherDerateDeduction">
|
<resultMap id="BaseResultMap" type="com.engine.salary.entity.datacollection.po.OtherDerateDeductionPO">
|
||||||
<result column="create_time" property="createTime" />
|
<result column="create_time" property="createTime"/>
|
||||||
<result column="creator" property="creator" />
|
<result column="creator" property="creator"/>
|
||||||
<result column="delete_type" property="deleteType" />
|
<result column="delete_type" property="deleteType"/>
|
||||||
<result column="employee_id" property="employeeId" />
|
<result column="employee_id" property="employeeId"/>
|
||||||
<result column="employee_type" property="employeeType" />
|
<result column="employee_type" property="employeeType"/>
|
||||||
<result column="file_status" property="fileStatus" />
|
<result column="file_status" property="fileStatus"/>
|
||||||
<result column="id" property="id" />
|
<result column="id" property="id"/>
|
||||||
<result column="main_id" property="mainId" />
|
<result column="main_id" property="mainId"/>
|
||||||
<result column="other_deduction" property="otherDeduction" />
|
<result column="other_deduction" property="otherDeduction"/>
|
||||||
<result column="remark" property="remark" />
|
<result column="remark" property="remark"/>
|
||||||
<result column="tax_agent_id" property="taxAgentId" />
|
<result column="tax_agent_id" property="taxAgentId"/>
|
||||||
<result column="tax_year_month" property="taxYearMonth" />
|
<result column="tax_year_month" property="taxYearMonth"/>
|
||||||
<result column="tenant_key" property="tenantKey" />
|
<result column="tenant_key" property="tenantKey"/>
|
||||||
<result column="update_time" property="updateTime" />
|
<result column="update_time" property="updateTime"/>
|
||||||
</resultMap>
|
</resultMap>
|
||||||
|
|
||||||
<!-- 表字段 -->
|
<!-- 表字段 -->
|
||||||
<sql id="baseColumns">
|
<sql id="baseColumns">
|
||||||
t.create_time
|
t
|
||||||
|
.
|
||||||
|
create_time
|
||||||
, t.creator
|
, t.creator
|
||||||
, t.delete_type
|
, t.delete_type
|
||||||
, t.employee_id
|
, t.employee_id
|
||||||
|
|
@ -34,378 +36,260 @@
|
||||||
, t.tax_year_month
|
, t.tax_year_month
|
||||||
, t.tenant_key
|
, t.tenant_key
|
||||||
, t.update_time
|
, t.update_time
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<!-- 查询全部 -->
|
<!-- 查询全部 -->
|
||||||
<select id="listAll" resultMap="BaseResultMap">
|
<select id="listAll" resultMap="BaseResultMap">
|
||||||
SELECT
|
SELECT
|
||||||
<include refid="baseColumns" />
|
<include refid="baseColumns"/>
|
||||||
FROM hrsa_other_derate_deduction t
|
FROM hrsa_other_derate_deduction t
|
||||||
WHERE delete_type = 0
|
WHERE delete_type = 0
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<!-- 根据主键获取单条记录 -->
|
<!-- 根据主键获取单条记录 -->
|
||||||
<select id="getById" resultMap="BaseResultMap" parameterType="Long">
|
<select id="getById" resultMap="BaseResultMap" parameterType="Long">
|
||||||
SELECT
|
SELECT
|
||||||
<include refid="baseColumns" />
|
<include refid="baseColumns"/>
|
||||||
FROM hrsa_other_derate_deduction t
|
FROM hrsa_other_derate_deduction t
|
||||||
WHERE id = #{id} AND delete_type = 0
|
WHERE id = #{id} AND delete_type = 0
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<!-- 条件查询 -->
|
<!-- 条件查询 -->
|
||||||
<select id="listSome" resultMap="BaseResultMap" parameterType="com.engine.salary.entity.OtherDerateDeduction">
|
<select id="listSome" resultMap="BaseResultMap"
|
||||||
SELECT
|
parameterType="com.engine.salary.entity.datacollection.po.OtherDerateDeductionPO">
|
||||||
<include refid="baseColumns" />
|
SELECT
|
||||||
FROM hrsa_other_derate_deduction t
|
<include refid="baseColumns"/>
|
||||||
WHERE delete_type = 0
|
FROM hrsa_other_derate_deduction t
|
||||||
<if test="createTime != null">
|
WHERE delete_type = 0
|
||||||
AND create_time = #{createTime}
|
<if test="createTime != null">
|
||||||
</if>
|
AND create_time = #{createTime}
|
||||||
<if test="creator != null">
|
</if>
|
||||||
AND creator = #{creator}
|
<if test="creator != null">
|
||||||
</if>
|
AND creator = #{creator}
|
||||||
<if test="deleteType != null">
|
</if>
|
||||||
AND delete_type = #{deleteType}
|
<if test="deleteType != null">
|
||||||
</if>
|
AND delete_type = #{deleteType}
|
||||||
<if test="employeeId != null">
|
</if>
|
||||||
AND employee_id = #{employeeId}
|
<if test="employeeId != null">
|
||||||
</if>
|
AND employee_id = #{employeeId}
|
||||||
<if test="employeeType != null">
|
</if>
|
||||||
AND employee_type = #{employeeType}
|
<if test="employeeType != null">
|
||||||
</if>
|
AND employee_type = #{employeeType}
|
||||||
<if test="fileStatus != null">
|
</if>
|
||||||
AND file_status = #{fileStatus}
|
<if test="fileStatus != null">
|
||||||
</if>
|
AND file_status = #{fileStatus}
|
||||||
<if test="id != null">
|
</if>
|
||||||
AND id = #{id}
|
<if test="id != null">
|
||||||
</if>
|
AND id = #{id}
|
||||||
<if test="mainId != null">
|
</if>
|
||||||
AND main_id = #{mainId}
|
<if test="mainId != null">
|
||||||
</if>
|
AND main_id = #{mainId}
|
||||||
<if test="otherDeduction != null">
|
</if>
|
||||||
AND other_deduction = #{otherDeduction}
|
<if test="otherDeduction != null">
|
||||||
</if>
|
AND other_deduction = #{otherDeduction}
|
||||||
<if test="remark != null">
|
</if>
|
||||||
AND remark = #{remark}
|
<if test="remark != null">
|
||||||
</if>
|
AND remark = #{remark}
|
||||||
<if test="taxAgentId != null">
|
</if>
|
||||||
AND tax_agent_id = #{taxAgentId}
|
<if test="taxAgentId != null">
|
||||||
</if>
|
AND tax_agent_id = #{taxAgentId}
|
||||||
<if test="taxYearMonth != null">
|
</if>
|
||||||
AND tax_year_month = #{taxYearMonth}
|
<if test="taxYearMonth != null">
|
||||||
</if>
|
AND tax_year_month = #{taxYearMonth}
|
||||||
<if test="tenantKey != null">
|
</if>
|
||||||
AND tenant_key = #{tenantKey}
|
<if test="tenantKey != null">
|
||||||
</if>
|
AND tenant_key = #{tenantKey}
|
||||||
<if test="updateTime != null">
|
</if>
|
||||||
AND update_time = #{updateTime}
|
<if test="updateTime != null">
|
||||||
</if>
|
AND update_time = #{updateTime}
|
||||||
<if test="ids != null and ids.size()>0">
|
</if>
|
||||||
|
<if test="ids != null and ids.size()>0">
|
||||||
AND id IN
|
AND id IN
|
||||||
<foreach collection="ids" open="(" item="id" separator="," close=")">
|
<foreach collection="ids" open="(" item="id" separator="," close=")">
|
||||||
#{id}
|
#{id}
|
||||||
</foreach>
|
</foreach>
|
||||||
</if>
|
</if>
|
||||||
ORDER BY id DESC
|
ORDER BY id DESC
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
|
||||||
<!-- 插入不为NULL的字段 -->
|
<!-- 插入不为NULL的字段 -->
|
||||||
<insert id="insertIgnoreNull" parameterType="com.engine.salary.entity.OtherDerateDeduction">
|
<insert id="insertIgnoreNull" parameterType="com.engine.salary.entity.datacollection.po.OtherDerateDeductionPO">
|
||||||
INSERT INTO hrsa_other_derate_deduction
|
|
||||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
||||||
|
|
||||||
<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="employeeType != null">
|
|
||||||
employee_type,
|
|
||||||
</if>
|
|
||||||
<if test="fileStatus != null">
|
|
||||||
file_status,
|
|
||||||
</if>
|
|
||||||
<if test="id != null">
|
|
||||||
id,
|
|
||||||
</if>
|
|
||||||
<if test="mainId != null">
|
|
||||||
main_id,
|
|
||||||
</if>
|
|
||||||
<if test="otherDeduction != null">
|
|
||||||
other_deduction,
|
|
||||||
</if>
|
|
||||||
<if test="remark != null">
|
|
||||||
remark,
|
|
||||||
</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>
|
|
||||||
</trim>
|
|
||||||
<trim prefix="VALUES (" suffix=")" suffixOverrides=",">
|
|
||||||
<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="employeeType != null" >
|
|
||||||
#{employeeType},
|
|
||||||
</if>
|
|
||||||
<if test="fileStatus != null" >
|
|
||||||
#{fileStatus},
|
|
||||||
</if>
|
|
||||||
<if test="id != null" >
|
|
||||||
#{id},
|
|
||||||
</if>
|
|
||||||
<if test="mainId != null" >
|
|
||||||
#{mainId},
|
|
||||||
</if>
|
|
||||||
<if test="otherDeduction != null" >
|
|
||||||
#{otherDeduction},
|
|
||||||
</if>
|
|
||||||
<if test="remark != null" >
|
|
||||||
#{remark},
|
|
||||||
</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>
|
|
||||||
</trim>
|
|
||||||
</insert>
|
|
||||||
|
|
||||||
|
|
||||||
<insert id="batchInsert">
|
|
||||||
|
|
||||||
INSERT INTO hrsa_other_derate_deduction
|
INSERT INTO hrsa_other_derate_deduction
|
||||||
(
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
create_time,
|
|
||||||
creator,
|
|
||||||
delete_type,
|
|
||||||
employee_id,
|
|
||||||
employee_type,
|
|
||||||
file_status,
|
|
||||||
id,
|
|
||||||
main_id,
|
|
||||||
other_deduction,
|
|
||||||
remark,
|
|
||||||
tax_agent_id,
|
|
||||||
tax_year_month,
|
|
||||||
tenant_key,
|
|
||||||
update_time,
|
|
||||||
)
|
|
||||||
VALUES
|
|
||||||
|
|
||||||
<foreach collection="collection" item="item" separator=",">
|
|
||||||
(
|
|
||||||
#{item.createTime},
|
|
||||||
#{item.creator},
|
|
||||||
#{item.deleteType},
|
|
||||||
#{item.employeeId},
|
|
||||||
#{item.employeeType},
|
|
||||||
#{item.fileStatus},
|
|
||||||
#{item.id},
|
|
||||||
#{item.mainId},
|
|
||||||
#{item.otherDeduction},
|
|
||||||
#{item.remark},
|
|
||||||
#{item.taxAgentId},
|
|
||||||
#{item.taxYearMonth},
|
|
||||||
#{item.tenantKey},
|
|
||||||
#{item.updateTime},
|
|
||||||
)
|
|
||||||
</foreach>
|
|
||||||
|
|
||||||
</insert>
|
|
||||||
|
|
||||||
|
|
||||||
<insert id="batchInsert" databaseId="oracle">
|
|
||||||
INSERT INTO hrsa_other_derate_deduction (
|
|
||||||
create_time,
|
|
||||||
creator,
|
|
||||||
delete_type,
|
|
||||||
employee_id,
|
|
||||||
employee_type,
|
|
||||||
file_status,
|
|
||||||
id,
|
|
||||||
main_id,
|
|
||||||
other_deduction,
|
|
||||||
remark,
|
|
||||||
tax_agent_id,
|
|
||||||
tax_year_month,
|
|
||||||
tenant_key,
|
|
||||||
update_time,
|
|
||||||
)
|
|
||||||
|
|
||||||
<foreach collection="collection" item="item" separator="union all">
|
<if test="createTime != null">
|
||||||
select
|
create_time,
|
||||||
#{item.createTime,jdbcType=DOUBLE、DATE、VARCHAR、INTEGER},
|
</if>
|
||||||
#{item.creator,jdbcType=DOUBLE、DATE、VARCHAR、INTEGER},
|
<if test="creator != null">
|
||||||
#{item.deleteType,jdbcType=DOUBLE、DATE、VARCHAR、INTEGER},
|
creator,
|
||||||
#{item.employeeId,jdbcType=DOUBLE、DATE、VARCHAR、INTEGER},
|
</if>
|
||||||
#{item.employeeType,jdbcType=DOUBLE、DATE、VARCHAR、INTEGER},
|
<if test="deleteType != null">
|
||||||
#{item.fileStatus,jdbcType=DOUBLE、DATE、VARCHAR、INTEGER},
|
delete_type,
|
||||||
#{item.id,jdbcType=DOUBLE、DATE、VARCHAR、INTEGER},
|
</if>
|
||||||
#{item.mainId,jdbcType=DOUBLE、DATE、VARCHAR、INTEGER},
|
<if test="employeeId != null">
|
||||||
#{item.otherDeduction,jdbcType=DOUBLE、DATE、VARCHAR、INTEGER},
|
employee_id,
|
||||||
#{item.remark,jdbcType=DOUBLE、DATE、VARCHAR、INTEGER},
|
</if>
|
||||||
#{item.taxAgentId,jdbcType=DOUBLE、DATE、VARCHAR、INTEGER},
|
<if test="employeeType != null">
|
||||||
#{item.taxYearMonth,jdbcType=DOUBLE、DATE、VARCHAR、INTEGER},
|
employee_type,
|
||||||
#{item.tenantKey,jdbcType=DOUBLE、DATE、VARCHAR、INTEGER},
|
</if>
|
||||||
#{item.updateTime,jdbcType=DOUBLE、DATE、VARCHAR、INTEGER},
|
<if test="fileStatus != null">
|
||||||
from dual
|
file_status,
|
||||||
</foreach>
|
</if>
|
||||||
</insert>
|
<if test="id != null">
|
||||||
|
id,
|
||||||
|
</if>
|
||||||
<insert id="batchInsert" databaseId="sqlserver">
|
<if test="mainId != null">
|
||||||
<foreach collection="collection" item="item" separator=";">
|
main_id,
|
||||||
INSERT INTO hrsa_other_derate_deduction (
|
</if>
|
||||||
create_time,
|
<if test="otherDeduction != null">
|
||||||
creator,
|
other_deduction,
|
||||||
delete_type,
|
</if>
|
||||||
employee_id,
|
<if test="remark != null">
|
||||||
employee_type,
|
remark,
|
||||||
file_status,
|
</if>
|
||||||
id,
|
<if test="taxAgentId != null">
|
||||||
main_id,
|
tax_agent_id,
|
||||||
other_deduction,
|
</if>
|
||||||
remark,
|
<if test="taxYearMonth != null">
|
||||||
tax_agent_id,
|
tax_year_month,
|
||||||
tax_year_month,
|
</if>
|
||||||
tenant_key,
|
<if test="tenantKey != null">
|
||||||
update_time,
|
tenant_key,
|
||||||
)
|
</if>
|
||||||
VALUES
|
<if test="updateTime != null">
|
||||||
(
|
update_time,
|
||||||
#{item.createTime},
|
</if>
|
||||||
#{item.creator},
|
</trim>
|
||||||
#{item.deleteType},
|
<trim prefix="VALUES (" suffix=")" suffixOverrides=",">
|
||||||
#{item.employeeId},
|
<if test="createTime != null">
|
||||||
#{item.employeeType},
|
#{createTime},
|
||||||
#{item.fileStatus},
|
</if>
|
||||||
#{item.id},
|
<if test="creator != null">
|
||||||
#{item.mainId},
|
#{creator},
|
||||||
#{item.otherDeduction},
|
</if>
|
||||||
#{item.remark},
|
<if test="deleteType != null">
|
||||||
#{item.taxAgentId},
|
#{deleteType},
|
||||||
#{item.taxYearMonth},
|
</if>
|
||||||
#{item.tenantKey},
|
<if test="employeeId != null">
|
||||||
#{item.updateTime},
|
#{employeeId},
|
||||||
)
|
</if>
|
||||||
</foreach>
|
<if test="employeeType != null">
|
||||||
|
#{employeeType},
|
||||||
|
</if>
|
||||||
|
<if test="fileStatus != null">
|
||||||
|
#{fileStatus},
|
||||||
|
</if>
|
||||||
|
<if test="id != null">
|
||||||
|
#{id},
|
||||||
|
</if>
|
||||||
|
<if test="mainId != null">
|
||||||
|
#{mainId},
|
||||||
|
</if>
|
||||||
|
<if test="otherDeduction != null">
|
||||||
|
#{otherDeduction},
|
||||||
|
</if>
|
||||||
|
<if test="remark != null">
|
||||||
|
#{remark},
|
||||||
|
</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>
|
||||||
|
</trim>
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
<!-- 更新,更新全部字段 -->
|
|
||||||
<update id="update" parameterType="com.engine.salary.entity.OtherDerateDeduction">
|
<!-- 更新,更新全部字段 -->
|
||||||
UPDATE hrsa_other_derate_deduction
|
<update id="update" parameterType="com.engine.salary.entity.datacollection.po.OtherDerateDeductionPO">
|
||||||
<set>
|
UPDATE hrsa_other_derate_deduction
|
||||||
create_time=#{createTime},
|
<set>
|
||||||
creator=#{creator},
|
create_time=#{createTime},
|
||||||
delete_type=#{deleteType},
|
creator=#{creator},
|
||||||
employee_id=#{employeeId},
|
delete_type=#{deleteType},
|
||||||
employee_type=#{employeeType},
|
employee_id=#{employeeId},
|
||||||
file_status=#{fileStatus},
|
employee_type=#{employeeType},
|
||||||
main_id=#{mainId},
|
file_status=#{fileStatus},
|
||||||
other_deduction=#{otherDeduction},
|
main_id=#{mainId},
|
||||||
remark=#{remark},
|
other_deduction=#{otherDeduction},
|
||||||
tax_agent_id=#{taxAgentId},
|
remark=#{remark},
|
||||||
tax_year_month=#{taxYearMonth},
|
tax_agent_id=#{taxAgentId},
|
||||||
tenant_key=#{tenantKey},
|
tax_year_month=#{taxYearMonth},
|
||||||
update_time=#{updateTime},
|
tenant_key=#{tenantKey},
|
||||||
</set>
|
update_time=#{updateTime},
|
||||||
WHERE id = #{id} AND delete_type = 0
|
</set>
|
||||||
</update>
|
WHERE id = #{id} AND delete_type = 0
|
||||||
|
|
||||||
|
|
||||||
<!-- 更新不为NULL的字段 -->
|
|
||||||
<update id="updateIgnoreNull" parameterType="com.engine.salary.entity.OtherDerateDeduction">
|
|
||||||
UPDATE hrsa_other_derate_deduction
|
|
||||||
<set>
|
|
||||||
<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="employeeType != null" >
|
|
||||||
employee_type=#{employeeType},
|
|
||||||
</if>
|
|
||||||
<if test="fileStatus != null" >
|
|
||||||
file_status=#{fileStatus},
|
|
||||||
</if>
|
|
||||||
<if test="mainId != null" >
|
|
||||||
main_id=#{mainId},
|
|
||||||
</if>
|
|
||||||
<if test="otherDeduction != null" >
|
|
||||||
other_deduction=#{otherDeduction},
|
|
||||||
</if>
|
|
||||||
<if test="remark != null" >
|
|
||||||
remark=#{remark},
|
|
||||||
</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>
|
|
||||||
</set>
|
|
||||||
WHERE id = #{id} AND delete_type = 0
|
|
||||||
</update>
|
</update>
|
||||||
|
|
||||||
|
|
||||||
<!-- 根据主键删除记录 -->
|
<!-- 更新不为NULL的字段 -->
|
||||||
<delete id="delete">
|
<update id="updateIgnoreNull" parameterType="com.engine.salary.entity.datacollection.po.OtherDerateDeductionPO">
|
||||||
UPDATE hrsa_other_derate_deduction
|
UPDATE hrsa_other_derate_deduction
|
||||||
SET delete_type=1
|
<set>
|
||||||
WHERE id = #{id} AND delete_type = 0
|
<if test="createTime != null">
|
||||||
</delete>
|
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="employeeType != null">
|
||||||
|
employee_type=#{employeeType},
|
||||||
|
</if>
|
||||||
|
<if test="fileStatus != null">
|
||||||
|
file_status=#{fileStatus},
|
||||||
|
</if>
|
||||||
|
<if test="mainId != null">
|
||||||
|
main_id=#{mainId},
|
||||||
|
</if>
|
||||||
|
<if test="otherDeduction != null">
|
||||||
|
other_deduction=#{otherDeduction},
|
||||||
|
</if>
|
||||||
|
<if test="remark != null">
|
||||||
|
remark=#{remark},
|
||||||
|
</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>
|
||||||
|
</set>
|
||||||
|
WHERE id = #{id} AND delete_type = 0
|
||||||
|
</update>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- 根据主键删除记录 -->
|
||||||
|
<delete id="delete">
|
||||||
|
UPDATE hrsa_other_derate_deduction
|
||||||
|
SET delete_type=1
|
||||||
|
WHERE id = #{id}
|
||||||
|
AND delete_type = 0
|
||||||
|
</delete>
|
||||||
|
|
||||||
<delete id="deleteByIds">
|
<delete id="deleteByIds">
|
||||||
UPDATE hrsa_other_derate_deduction
|
UPDATE hrsa_other_derate_deduction
|
||||||
SET delete_type = 1
|
SET delete_type = 1
|
||||||
WHERE delete_type = 0
|
WHERE delete_type = 0
|
||||||
AND id IN
|
AND id IN
|
||||||
<foreach collection="ids" open="(" item="id" separator="," close=")">
|
<foreach collection="ids" open="(" item="id" separator="," close=")">
|
||||||
#{id}
|
#{id}
|
||||||
|
|
@ -413,5 +297,4 @@
|
||||||
</delete>
|
</delete>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</mapper>
|
</mapper>
|
||||||
|
|
@ -257,7 +257,7 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
||||||
List<Long> employeeSameIds = new ArrayList<>();
|
List<Long> employeeSameIds = new ArrayList<>();
|
||||||
|
|
||||||
//筛选导入人员信息可以在人力资源池中匹配到的人员信息
|
//筛选导入人员信息可以在人力资源池中匹配到的人员信息
|
||||||
List<DataCollectionEmployee> emps = getSalaryEmployeeService(user).matchImportEmployee(confValue, employees, userName, deparmentName, mobile, workcode, idNo,null);
|
List<DataCollectionEmployee> emps = getSalaryEmployeeService(user).matchImportEmployee(confValue, employees, userName, deparmentName, mobile, workcode, idNo, null);
|
||||||
//含在职和离职,选在职数据
|
//含在职和离职,选在职数据
|
||||||
if (CollectionUtils.isNotEmpty(emps) && emps.size() > 1) {
|
if (CollectionUtils.isNotEmpty(emps) && emps.size() > 1) {
|
||||||
employeeSameIds = emps.stream()
|
employeeSameIds = emps.stream()
|
||||||
|
|
@ -327,6 +327,12 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//免税收入
|
||||||
|
String freeIncome = dto.getFreeIncome();
|
||||||
|
po.setFreeIncome(freeIncome);
|
||||||
|
//减免税额
|
||||||
|
String derateDeduction = dto.getDerateDeduction();
|
||||||
|
po.setDerateDeduction(derateDeduction);
|
||||||
//商业健康保险
|
//商业健康保险
|
||||||
String businessHealthyInsurance = dto.getBusinessHealthyInsurance();
|
String businessHealthyInsurance = dto.getBusinessHealthyInsurance();
|
||||||
po.setBusinessHealthyInsurance(businessHealthyInsurance);
|
po.setBusinessHealthyInsurance(businessHealthyInsurance);
|
||||||
|
|
@ -504,7 +510,7 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
||||||
private List<List<Object>> getExcelRowList(OtherDeductionQueryParam param, boolean hasData) {
|
private List<List<Object>> getExcelRowList(OtherDeductionQueryParam param, boolean hasData) {
|
||||||
long employeeId = user.getUID();
|
long employeeId = user.getUID();
|
||||||
//excel标题
|
//excel标题
|
||||||
List<Object> title = Arrays.asList("姓名", "个税扣缴义务人", "部门", "手机号", "工号", "证件号码", "入职日期", "商业健康保险", "税延养老保险", "其他", "准予扣除的捐赠额", "个人养老金");
|
List<Object> title = Arrays.asList("姓名", "个税扣缴义务人", "部门", "手机号", "工号", "证件号码", "入职日期", "免税收入", "减免税额", "商业健康保险", "税延养老保险", "其他", "准予扣除的捐赠额", "个人养老金");
|
||||||
List<List<Object>> rowList = new ArrayList<>();
|
List<List<Object>> rowList = new ArrayList<>();
|
||||||
rowList.add(title);
|
rowList.add(title);
|
||||||
|
|
||||||
|
|
@ -536,6 +542,8 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
||||||
cellList.add(Util.null2String(dto.getJobNum()));
|
cellList.add(Util.null2String(dto.getJobNum()));
|
||||||
cellList.add(Util.null2String(dto.getIdNo()));
|
cellList.add(Util.null2String(dto.getIdNo()));
|
||||||
cellList.add(Util.null2String(dto.getHiredate()));
|
cellList.add(Util.null2String(dto.getHiredate()));
|
||||||
|
cellList.add(NumberUtil.isNumber(dto.getFreeIncome()) ? new BigDecimal(dto.getFreeIncome()) : Util.null2String(dto.getFreeIncome()));
|
||||||
|
cellList.add(NumberUtil.isNumber(dto.getDerateDeduction()) ? new BigDecimal(dto.getDerateDeduction()) : Util.null2String(dto.getDerateDeduction()));
|
||||||
cellList.add(NumberUtil.isNumber(dto.getBusinessHealthyInsurance()) ? new BigDecimal(dto.getBusinessHealthyInsurance()) : Util.null2String(dto.getBusinessHealthyInsurance()));
|
cellList.add(NumberUtil.isNumber(dto.getBusinessHealthyInsurance()) ? new BigDecimal(dto.getBusinessHealthyInsurance()) : Util.null2String(dto.getBusinessHealthyInsurance()));
|
||||||
cellList.add(NumberUtil.isNumber(dto.getTaxDelayEndowmentInsurance()) ? new BigDecimal(dto.getTaxDelayEndowmentInsurance()) : Util.null2String(dto.getTaxDelayEndowmentInsurance()));
|
cellList.add(NumberUtil.isNumber(dto.getTaxDelayEndowmentInsurance()) ? new BigDecimal(dto.getTaxDelayEndowmentInsurance()) : Util.null2String(dto.getTaxDelayEndowmentInsurance()));
|
||||||
cellList.add(NumberUtil.isNumber(dto.getOtherDeduction()) ? new BigDecimal(dto.getOtherDeduction()) : Util.null2String(dto.getOtherDeduction()));
|
cellList.add(NumberUtil.isNumber(dto.getOtherDeduction()) ? new BigDecimal(dto.getOtherDeduction()) : Util.null2String(dto.getOtherDeduction()));
|
||||||
|
|
@ -603,7 +611,7 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
||||||
*/
|
*/
|
||||||
private List<List<Object>> getExcelRowDetailList(OtherDeductionQueryParam param) {
|
private List<List<Object>> getExcelRowDetailList(OtherDeductionQueryParam param) {
|
||||||
//excel标题
|
//excel标题
|
||||||
List<Object> title = Arrays.asList("姓名", "申报月份", "个税扣缴义务人", "部门", "手机号", "工号", "商业健康保险", "税延养老保险", "其他", "准予扣除的捐赠额", "个人养老金");
|
List<Object> title = Arrays.asList("姓名", "申报月份", "个税扣缴义务人", "部门", "手机号", "工号", "免税收入", "减免税额", "商业健康保险", "税延养老保险", "其他", "准予扣除的捐赠额", "个人养老金");
|
||||||
|
|
||||||
SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM");
|
SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM");
|
||||||
//查询详细信息
|
//查询详细信息
|
||||||
|
|
@ -619,6 +627,8 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
||||||
cellList.add(Util.null2String(dto.getDepartmentName()));
|
cellList.add(Util.null2String(dto.getDepartmentName()));
|
||||||
cellList.add(Util.null2String(dto.getMobile()));
|
cellList.add(Util.null2String(dto.getMobile()));
|
||||||
cellList.add(Util.null2String(dto.getJobNum()));
|
cellList.add(Util.null2String(dto.getJobNum()));
|
||||||
|
cellList.add(NumberUtil.isNumber(dto.getFreeIncome()) ? new BigDecimal(dto.getFreeIncome()) : Util.null2String(dto.getFreeIncome()));
|
||||||
|
cellList.add(NumberUtil.isNumber(dto.getDerateDeduction()) ? new BigDecimal(dto.getDerateDeduction()) : Util.null2String(dto.getDerateDeduction()));
|
||||||
cellList.add(NumberUtil.isNumber(dto.getBusinessHealthyInsurance()) ? new BigDecimal(dto.getBusinessHealthyInsurance()) : Util.null2String(dto.getBusinessHealthyInsurance()));
|
cellList.add(NumberUtil.isNumber(dto.getBusinessHealthyInsurance()) ? new BigDecimal(dto.getBusinessHealthyInsurance()) : Util.null2String(dto.getBusinessHealthyInsurance()));
|
||||||
cellList.add(NumberUtil.isNumber(dto.getTaxDelayEndowmentInsurance()) ? new BigDecimal(dto.getTaxDelayEndowmentInsurance()) : Util.null2String(dto.getTaxDelayEndowmentInsurance()));
|
cellList.add(NumberUtil.isNumber(dto.getTaxDelayEndowmentInsurance()) ? new BigDecimal(dto.getTaxDelayEndowmentInsurance()) : Util.null2String(dto.getTaxDelayEndowmentInsurance()));
|
||||||
cellList.add(NumberUtil.isNumber(dto.getOtherDeduction()) ? new BigDecimal(dto.getOtherDeduction()) : Util.null2String(dto.getOtherDeduction()));
|
cellList.add(NumberUtil.isNumber(dto.getOtherDeduction()) ? new BigDecimal(dto.getOtherDeduction()) : Util.null2String(dto.getOtherDeduction()));
|
||||||
|
|
@ -674,6 +684,8 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
||||||
ArrayList<OtherDeductionPO> updateList = new ArrayList<>();
|
ArrayList<OtherDeductionPO> updateList = new ArrayList<>();
|
||||||
OtherDeductionPO build = OtherDeductionPO.builder()
|
OtherDeductionPO build = OtherDeductionPO.builder()
|
||||||
.id(otherDeductionParam.getId())
|
.id(otherDeductionParam.getId())
|
||||||
|
.freeIncome(otherDeductionParam.getFreeIncome())
|
||||||
|
.derateDeduction(otherDeductionParam.getDerateDeduction())
|
||||||
.businessHealthyInsurance(otherDeductionParam.getBusinessHealthyInsurance())
|
.businessHealthyInsurance(otherDeductionParam.getBusinessHealthyInsurance())
|
||||||
.taxDelayEndowmentInsurance(otherDeductionParam.getTaxDelayEndowmentInsurance())
|
.taxDelayEndowmentInsurance(otherDeductionParam.getTaxDelayEndowmentInsurance())
|
||||||
.otherDeduction(otherDeductionParam.getOtherDeduction())
|
.otherDeduction(otherDeductionParam.getOtherDeduction())
|
||||||
|
|
@ -753,7 +765,12 @@ public class OtherDeductionServiceImpl extends Service implements OtherDeduction
|
||||||
throw new SalaryRunTimeException("个税扣缴义务人不存在或不在权限范围内");
|
throw new SalaryRunTimeException("个税扣缴义务人不存在或不在权限范围内");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
//免税收入
|
||||||
|
String freeIncome = otherDeductionParam.getFreeIncome();
|
||||||
|
po.setFreeIncome(freeIncome);
|
||||||
|
//减免税额
|
||||||
|
String derateDeduction = otherDeductionParam.getDerateDeduction();
|
||||||
|
po.setDerateDeduction(derateDeduction);
|
||||||
//商业健康保险
|
//商业健康保险
|
||||||
String businessHealthyInsurance = otherDeductionParam.getBusinessHealthyInsurance();
|
String businessHealthyInsurance = otherDeductionParam.getBusinessHealthyInsurance();
|
||||||
po.setBusinessHealthyInsurance(businessHealthyInsurance);
|
po.setBusinessHealthyInsurance(businessHealthyInsurance);
|
||||||
|
|
|
||||||
|
|
@ -1060,12 +1060,16 @@ public class SalarySysConfServiceImpl extends Service implements SalarySysConfSe
|
||||||
if (CollectionUtils.isNotEmpty(otherDeductionPos)) {
|
if (CollectionUtils.isNotEmpty(otherDeductionPos)) {
|
||||||
otherDeductionPos.forEach(po -> {
|
otherDeductionPos.forEach(po -> {
|
||||||
if (OpenEnum.OFF.getValue().equals(isOpenEncrypt)) {
|
if (OpenEnum.OFF.getValue().equals(isOpenEncrypt)) {
|
||||||
|
po.setFreeIncome(AESEncryptUtil.closeEncryptSetting(po.getFreeIncome(), sysConfPo));
|
||||||
|
po.setDerateDeduction(AESEncryptUtil.closeEncryptSetting(po.getDerateDeduction(), sysConfPo));
|
||||||
po.setBusinessHealthyInsurance(AESEncryptUtil.closeEncryptSetting(po.getBusinessHealthyInsurance(), sysConfPo));
|
po.setBusinessHealthyInsurance(AESEncryptUtil.closeEncryptSetting(po.getBusinessHealthyInsurance(), sysConfPo));
|
||||||
po.setTaxDelayEndowmentInsurance(AESEncryptUtil.closeEncryptSetting(po.getTaxDelayEndowmentInsurance(), sysConfPo));
|
po.setTaxDelayEndowmentInsurance(AESEncryptUtil.closeEncryptSetting(po.getTaxDelayEndowmentInsurance(), sysConfPo));
|
||||||
po.setOtherDeduction(AESEncryptUtil.closeEncryptSetting(po.getOtherDeduction(), sysConfPo));
|
po.setOtherDeduction(AESEncryptUtil.closeEncryptSetting(po.getOtherDeduction(), sysConfPo));
|
||||||
po.setDeductionAllowedDonation(AESEncryptUtil.closeEncryptSetting(po.getDeductionAllowedDonation(), sysConfPo));
|
po.setDeductionAllowedDonation(AESEncryptUtil.closeEncryptSetting(po.getDeductionAllowedDonation(), sysConfPo));
|
||||||
po.setPrivatePension(AESEncryptUtil.closeEncryptSetting(po.getPrivatePension(), sysConfPo));
|
po.setPrivatePension(AESEncryptUtil.closeEncryptSetting(po.getPrivatePension(), sysConfPo));
|
||||||
} else {
|
} else {
|
||||||
|
po.setFreeIncome(AESEncryptUtil.encrypt(po.getFreeIncome()));
|
||||||
|
po.setDerateDeduction(AESEncryptUtil.encrypt(po.getDerateDeduction()));
|
||||||
po.setBusinessHealthyInsurance(AESEncryptUtil.encrypt(po.getBusinessHealthyInsurance()));
|
po.setBusinessHealthyInsurance(AESEncryptUtil.encrypt(po.getBusinessHealthyInsurance()));
|
||||||
po.setTaxDelayEndowmentInsurance(AESEncryptUtil.encrypt(po.getTaxDelayEndowmentInsurance()));
|
po.setTaxDelayEndowmentInsurance(AESEncryptUtil.encrypt(po.getTaxDelayEndowmentInsurance()));
|
||||||
po.setOtherDeduction(AESEncryptUtil.encrypt(po.getOtherDeduction()));
|
po.setOtherDeduction(AESEncryptUtil.encrypt(po.getOtherDeduction()));
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue