Commit 362ebc62 authored by fangxinjiang's avatar fangxinjiang

项目档案新增字段“标签”

parent b7baccd1
......@@ -364,6 +364,13 @@ public class TEmployeeProject extends BaseEntity {
@TableField(exist = false)
private String changeStartMonth;
/**
* 标签
*/
@Schema(description ="标签")
@Size(max = 20, message = "标签不可超过20位")
private String empLabel;
/**
* 员工合同状态(字典)
* 0 无合同
......
......@@ -479,7 +479,13 @@ public class EmployeeProjectExportVO {
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="社保所在市")
private String socialCity;
/**
* 标签
*/
@ExcelAttribute(name = "标签",maxLength = 20)
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="标签")
private String empLabel;
/**
* 社保-县
*/
......
......@@ -23,10 +23,12 @@ import com.alibaba.excel.annotation.write.style.HeadFontStyle;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.ExcelAttribute;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.ExcelAttributeConstants;
import com.yifu.cloud.plus.v1.yifu.common.core.vo.RowIndex;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Past;
import javax.validation.constraints.Size;
import java.io.Serializable;
import java.util.Date;
......@@ -142,4 +144,12 @@ public class EmployeeProjectUpdateVO extends RowIndex implements Serializable {
@ExcelProperty(value ="试用期")
private String tryPeriod;
/**
* 标签
*/
@ExcelAttribute(name = "标签",maxLength = 20)
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="标签")
private String empLabel;
}
......@@ -23,10 +23,12 @@ import com.alibaba.excel.annotation.write.style.HeadFontStyle;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.ExcelAttribute;
import com.yifu.cloud.plus.v1.yifu.common.core.constant.ExcelAttributeConstants;
import com.yifu.cloud.plus.v1.yifu.common.core.vo.RowIndex;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Past;
import javax.validation.constraints.Size;
import java.io.Serializable;
import java.util.Date;
......@@ -141,5 +143,13 @@ public class EmployeeProjectVO extends RowIndex implements Serializable {
@ExcelProperty(value ="试用期")
@ExcelAttribute(name = "试用期",maxLength = 4)
private String tryPeriod;
/**
* 标签
*/
@HeadFontStyle(fontHeightInPoints = 11)
@ExcelProperty(value ="标签")
@ExcelAttribute(name = "标签",maxLength = 20)
@Schema(description ="标签")
@Size(max = 20, message = "标签不可超过20位")
private String empLabel;
}
......@@ -56,6 +56,7 @@
<result property="socialStatus" column="SOCIAL_STATUS"/>
<result property="fundStatus" column="FUND_STATUS"/>
<result property="contractStatus" column="CONTRACT_STATUS"/>
<result property="empLabel" column="EMP_LABEL"/>
</resultMap>
<resultMap id="tEmployeeProjectExportMap" type="com.yifu.cloud.plus.v1.yifu.archives.vo.EmployeeProjectExportVO">
......@@ -115,6 +116,7 @@
<result property="createName" column="CREATE_NAME"/>
<result property="createTime" column="CREATE_TIME"/>
<result property="contractStatus" column="CONTRACT_STATUS"/>
<result property="empLabel" column="EMP_LABEL"/>
</resultMap>
<sql id="Base_Column_List">
......@@ -168,7 +170,8 @@
a.SOCIAL_PROVINCE,
a.SOCIAL_CITY,
a.SOCIAL_TOWN,
a.SALARY_STATUS
a.SALARY_STATUS,
a.EMP_LABEL
</sql>
<sql id="Base_Export_List">
......@@ -231,7 +234,8 @@
a.CREATE_NAME,
a.CREATE_TIME,
b.EMP_EMAIL,
b.EMP_NATRUE AS PROEMP_NATRUE
b.EMP_NATRUE AS PROEMP_NATRUE,
a.EMP_LABEL
</sql>
<sql id="tEmployeeProject_where">
......@@ -421,6 +425,9 @@
#{idStr}
</foreach>
</if>
<if test="tEmployeeProject.empLabel != null">
AND a.EMP_LABEL = #{tEmployeeProject.empLabel}
</if>
</if>
</sql>
......@@ -581,12 +588,22 @@
#{idStr}
</foreach>
</if>
<if test="tEmployeeProject.empLabel != null">
AND a.EMP_LABEL = #{tEmployeeProject.empLabel}
</if>
</if>
</sql>
<update id="updateExcelEmpProject" parameterType="java.util.List">
update t_employee_project
<trim prefix="set" suffixOverrides=",">
<trim prefix="EMP_LABEL =case" suffix="end,">
<foreach collection="list" item="i" index="index">
<if test="i.empLabel!=null">
when ID=#{i.id} then #{i.empLabel}
</if>
</foreach>
</trim>
<trim prefix="EMP_NATRUE =case" suffix="end,">
<foreach collection="list" item="i" index="index">
<if test="i.empNatrue!=null">
......@@ -692,7 +709,7 @@
(ID,EMP_ID,EMP_NATRUE,EMP_NAME,EMP_IDCARD,STATUS,PROJECT_STATUS,EMP_CODE,DEPT_NO,CONTRACT_TYPE,POST,
DEPT_ID,DEPT_NAME,UNIT_ID,UNIT_NAME,UNIT_NO,EMP_NO,TRY_PERIOD,ENJOIN_DATE,BANK_NAME,BANK_NO,BANK_SUB_NAME,
BUSINESS_PRIMARY_TYPE,BUSINESS_SECOND_TYPE,BUSINESS_THIRD_TYPE,WORKING_HOURS,PROJECT_SOURCE,DELETE_FLAG,
CREATE_BY,CREATE_NAME,CREATE_TIME,INSURANCE_STATUS,SOCIAL_STATUS,FUND_STATUS)
CREATE_BY,CREATE_NAME,CREATE_TIME,INSURANCE_STATUS,SOCIAL_STATUS,FUND_STATUS,EMP_LABEL)
VALUES
<foreach collection="list" item="item" index="index" separator=",">
(
......@@ -729,13 +746,19 @@
now(),
0,
0,
0
0,
#{item.empLabel,jdbcType=VARCHAR}
)
</foreach>
</insert>
<update id="updateReduceEmpProject" parameterType="java.util.List">
update t_employee_project
<trim prefix="set" suffixOverrides=",">
<trim prefix="EMP_LABEL =case" suffix="end,">
<foreach collection="list" item="i" index="index">
when ID=#{i.id} then #{i.empLabel}
</foreach>
</trim>
<trim prefix="LEAVE_TIME =case" suffix="end,">
<foreach collection="list" item="i" index="index">
when ID=#{i.id} then now()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment