123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179 |
- <?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.CmcWageMapper">
-
- <resultMap type="CmcWage" id="CmcWageResult">
- <result property="wageId" column="wage_id" />
- <result property="userId" column="user_id" />
- <result property="baseSalary" column="base_salary" />
- <result property="yearSalary" column="year_salary" />
- <result property="postSalary" column="post_salary" />
- <result property="performanceSalary" column="performance_salary" />
- <result property="certificatesSubsidy" column="certificates_subsidy" />
- <result property="festivalSubsidy" column="festival_subsidy" />
- <result property="postStableSubsidy" column="post_stable_subsidy" />
- <result property="highTemperatureSubsidy" column="high_temperature_subsidy" />
- <result property="attendanceDeduct" column="attendance_deduct" />
- <result property="payableWage" column="payable_wage" />
- <result property="houseFund" column="house_fund" />
- <result property="endowmentInsurance" column="endowment_insurance" />
- <result property="unemploymentInsurance" column="unemployment_insurance" />
- <result property="medicalInsurance" column="medical_insurance" />
- <result property="propertyFee" column="property_fee" />
- <result property="deductTotal" column="deduct_total" />
- <result property="socialSecurityUnit" column="social_security_unit" />
- <result property="individualIncomeTax" column="individual_income_tax" />
- <result property="paidWage" column="paid_wage" />
- <result property="payDay" column="pay_day" />
- <result property="payMonth" column="pay_month" />
- <result property="remark" column="remark" />
- <result property="performanceId" column="performance_id" />
- </resultMap>
-
- <sql id="selectCmcWageVo">
- select wage_id, user_id, base_salary, year_salary, post_salary, performance_salary, certificates_subsidy, festival_subsidy, post_stable_subsidy, high_temperature_subsidy, attendance_deduct, payable_wage, house_fund, endowment_insurance, unemployment_insurance, medical_insurance, property_fee, deduct_total, social_security_unit, individual_income_tax, paid_wage, pay_day, pay_month, remark, performance_id from cmc_wage
- </sql>
-
- <select id="selectCmcWageList" parameterType="CmcWage" resultMap="CmcWageResult">
- <include refid="selectCmcWageVo"/>
- <where>
- <if test="userId != null "> and user_id = #{userId}</if>
- <if test="baseSalary != null "> and base_salary = #{baseSalary}</if>
- <if test="yearSalary != null "> and year_salary = #{yearSalary}</if>
- <if test="postSalary != null "> and post_salary = #{postSalary}</if>
- <if test="performanceSalary != null "> and performance_salary = #{performanceSalary}</if>
- <if test="certificatesSubsidy != null "> and certificates_subsidy = #{certificatesSubsidy}</if>
- <if test="festivalSubsidy != null "> and festival_subsidy = #{festivalSubsidy}</if>
- <if test="postStableSubsidy != null "> and post_stable_subsidy = #{postStableSubsidy}</if>
- <if test="highTemperatureSubsidy != null "> and high_temperature_subsidy = #{highTemperatureSubsidy}</if>
- <if test="attendanceDeduct != null "> and attendance_deduct = #{attendanceDeduct}</if>
- <if test="payableWage != null "> and payable_wage = #{payableWage}</if>
- <if test="houseFund != null "> and house_fund = #{houseFund}</if>
- <if test="endowmentInsurance != null "> and endowment_insurance = #{endowmentInsurance}</if>
- <if test="unemploymentInsurance != null "> and unemployment_insurance = #{unemploymentInsurance}</if>
- <if test="medicalInsurance != null "> and medical_insurance = #{medicalInsurance}</if>
- <if test="propertyFee != null "> and property_fee = #{propertyFee}</if>
- <if test="deductTotal != null "> and deduct_total = #{deductTotal}</if>
- <if test="socialSecurityUnit != null "> and social_security_unit = #{socialSecurityUnit}</if>
- <if test="individualIncomeTax != null "> and individual_income_tax = #{individualIncomeTax}</if>
- <if test="paidWage != null "> and paid_wage = #{paidWage}</if>
- <if test="payDay != null "> and pay_day = #{payDay}</if>
- <if test="payMonth != null "> and pay_month = #{payMonth}</if>
- <if test="performanceId != null and performanceId != ''"> and performance_id = #{performanceId}</if>
- </where>
- </select>
-
- <select id="selectCmcWageByWageId" parameterType="Integer" resultMap="CmcWageResult">
- <include refid="selectCmcWageVo"/>
- where wage_id = #{wageId}
- </select>
-
- <insert id="insertCmcWage" parameterType="CmcWage">
- insert into cmc_wage
- <trim prefix="(" suffix=")" suffixOverrides=",">
- <if test="wageId != null">wage_id,</if>
- <if test="userId != null">user_id,</if>
- <if test="baseSalary != null">base_salary,</if>
- <if test="yearSalary != null">year_salary,</if>
- <if test="postSalary != null">post_salary,</if>
- <if test="performanceSalary != null">performance_salary,</if>
- <if test="certificatesSubsidy != null">certificates_subsidy,</if>
- <if test="festivalSubsidy != null">festival_subsidy,</if>
- <if test="postStableSubsidy != null">post_stable_subsidy,</if>
- <if test="highTemperatureSubsidy != null">high_temperature_subsidy,</if>
- <if test="attendanceDeduct != null">attendance_deduct,</if>
- <if test="payableWage != null">payable_wage,</if>
- <if test="houseFund != null">house_fund,</if>
- <if test="endowmentInsurance != null">endowment_insurance,</if>
- <if test="unemploymentInsurance != null">unemployment_insurance,</if>
- <if test="medicalInsurance != null">medical_insurance,</if>
- <if test="propertyFee != null">property_fee,</if>
- <if test="deductTotal != null">deduct_total,</if>
- <if test="socialSecurityUnit != null">social_security_unit,</if>
- <if test="individualIncomeTax != null">individual_income_tax,</if>
- <if test="paidWage != null">paid_wage,</if>
- <if test="payDay != null">pay_day,</if>
- <if test="payMonth != null">pay_month,</if>
- <if test="remark != null">remark,</if>
- <if test="performanceId != null">performance_id,</if>
- </trim>
- <trim prefix="values (" suffix=")" suffixOverrides=",">
- <if test="wageId != null">#{wageId},</if>
- <if test="userId != null">#{userId},</if>
- <if test="baseSalary != null">#{baseSalary},</if>
- <if test="yearSalary != null">#{yearSalary},</if>
- <if test="postSalary != null">#{postSalary},</if>
- <if test="performanceSalary != null">#{performanceSalary},</if>
- <if test="certificatesSubsidy != null">#{certificatesSubsidy},</if>
- <if test="festivalSubsidy != null">#{festivalSubsidy},</if>
- <if test="postStableSubsidy != null">#{postStableSubsidy},</if>
- <if test="highTemperatureSubsidy != null">#{highTemperatureSubsidy},</if>
- <if test="attendanceDeduct != null">#{attendanceDeduct},</if>
- <if test="payableWage != null">#{payableWage},</if>
- <if test="houseFund != null">#{houseFund},</if>
- <if test="endowmentInsurance != null">#{endowmentInsurance},</if>
- <if test="unemploymentInsurance != null">#{unemploymentInsurance},</if>
- <if test="medicalInsurance != null">#{medicalInsurance},</if>
- <if test="propertyFee != null">#{propertyFee},</if>
- <if test="deductTotal != null">#{deductTotal},</if>
- <if test="socialSecurityUnit != null">#{socialSecurityUnit},</if>
- <if test="individualIncomeTax != null">#{individualIncomeTax},</if>
- <if test="paidWage != null">#{paidWage},</if>
- <if test="payDay != null">#{payDay},</if>
- <if test="payMonth != null">#{payMonth},</if>
- <if test="remark != null">#{remark},</if>
- <if test="performanceId != null">#{performanceId},</if>
- </trim>
- </insert>
-
- <update id="updateCmcWage" parameterType="CmcWage">
- update cmc_wage
- <trim prefix="SET" suffixOverrides=",">
- <if test="userId != null">user_id = #{userId},</if>
- <if test="baseSalary != null">base_salary = #{baseSalary},</if>
- <if test="yearSalary != null">year_salary = #{yearSalary},</if>
- <if test="postSalary != null">post_salary = #{postSalary},</if>
- <if test="performanceSalary != null">performance_salary = #{performanceSalary},</if>
- <if test="certificatesSubsidy != null">certificates_subsidy = #{certificatesSubsidy},</if>
- <if test="festivalSubsidy != null">festival_subsidy = #{festivalSubsidy},</if>
- <if test="postStableSubsidy != null">post_stable_subsidy = #{postStableSubsidy},</if>
- <if test="highTemperatureSubsidy != null">high_temperature_subsidy = #{highTemperatureSubsidy},</if>
- <if test="attendanceDeduct != null">attendance_deduct = #{attendanceDeduct},</if>
- <if test="payableWage != null">payable_wage = #{payableWage},</if>
- <if test="houseFund != null">house_fund = #{houseFund},</if>
- <if test="endowmentInsurance != null">endowment_insurance = #{endowmentInsurance},</if>
- <if test="unemploymentInsurance != null">unemployment_insurance = #{unemploymentInsurance},</if>
- <if test="medicalInsurance != null">medical_insurance = #{medicalInsurance},</if>
- <if test="propertyFee != null">property_fee = #{propertyFee},</if>
- <if test="deductTotal != null">deduct_total = #{deductTotal},</if>
- <if test="socialSecurityUnit != null">social_security_unit = #{socialSecurityUnit},</if>
- <if test="individualIncomeTax != null">individual_income_tax = #{individualIncomeTax},</if>
- <if test="paidWage != null">paid_wage = #{paidWage},</if>
- <if test="payDay != null">pay_day = #{payDay},</if>
- <if test="payMonth != null">pay_month = #{payMonth},</if>
- <if test="remark != null">remark = #{remark},</if>
- <if test="performanceId != null">performance_id = #{performanceId},</if>
- </trim>
- where wage_id = #{wageId}
- </update>
-
- <delete id="deleteCmcWageByWageId" parameterType="Integer">
- delete from cmc_wage where wage_id = #{wageId}
- </delete>
-
- <delete id="deleteCmcWageByWageIds" parameterType="String">
- delete from cmc_wage where wage_id in
- <foreach item="wageId" collection="array" open="(" separator="," close=")">
- #{wageId}
- </foreach>
- </delete>
-
- <delete id="deleteCmcWageByPerformanceIds" parameterType="String">
- delete from cmc_wage where performance_id in
- <foreach item="performanceId" collection="array" open="(" separator="," close=")">
- #{performanceId}
- </foreach>
- </delete>
- </mapper>
|