41 lines
2.1 KiB
XML
41 lines
2.1 KiB
XML
<?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">
|
|
<mapper namespace="com.ruoyi.oa.mapper.OaEmployeeTemplateBindingMapper">
|
|
|
|
<resultMap type="com.ruoyi.oa.domain.OaEmployeeTemplateBinding" id="OaEmployeeTemplateBindingResult">
|
|
<result property="bindingId" column="binding_id"/>
|
|
<result property="employeeId" column="employee_id"/>
|
|
<result property="personalInsuranceTemplateId" column="personal_insurance_template_id"/>
|
|
<result property="companyInsuranceTemplateId" column="company_insurance_template_id"/>
|
|
<result property="salaryTemplateId" column="salary_template_id"/>
|
|
<result property="payYear" column="pay_year"/>
|
|
<result property="payMonth" column="pay_month"/>
|
|
<result property="netSalary" column="net_salary"/>
|
|
<result property="totalCompanyCost" column="total_company_cost"/>
|
|
<result property="status" column="status"/>
|
|
<result property="delFlag" column="del_flag"/>
|
|
<result property="remark" column="remark"/>
|
|
<result property="createBy" column="create_by"/>
|
|
<result property="createTime" column="create_time"/>
|
|
<result property="updateBy" column="update_by"/>
|
|
<result property="updateTime" column="update_time"/>
|
|
</resultMap>
|
|
<insert id="insertBinding">
|
|
INSERT INTO oa_employee_template_binding
|
|
(employee_id,personal_insurance_template_id,company_insurance_template_id, salary_template_id, pay_year, pay_month, net_salary, total_company_cost, status)
|
|
VALUES (#{employeeId}, #{personalInsuranceTemplateId},#{companyInsuranceTemplateId}, #{salaryTemplateId}, #{payYear}, #{payMonth}, #{netSalary}, #{totalCompanyCost}, #{status})
|
|
</insert>
|
|
<select id="findByEmployeeAndMonth" resultType="com.ruoyi.oa.domain.OaEmployeeTemplateBinding">
|
|
SELECT * FROM oa_employee_template_binding
|
|
WHERE employee_id = #{employeeId}
|
|
AND pay_year = #{payYear}
|
|
AND pay_month = #{payMonth}
|
|
AND del_flag = '0'
|
|
LIMIT 1
|
|
</select>
|
|
|
|
|
|
</mapper>
|