| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251 |
- <?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">
- <!-- namespace必须指向DAO接口 -->
- <mapper namespace="com.jpsoft.employment.modules.job.dao.RecruitmentDAO">
- <resultMap id="RecruitmentMap" type="com.jpsoft.employment.modules.job.entity.Recruitment">
- <id property="id" column="id_" />
- <result property="companyId" column="company_id" />
- <result property="title" column="title_" />
- <result property="area" column="area_" />
- <result property="address" column="address_" />
- <result property="position" column="position_" />
- <result property="positionMessage" column="position_message" />
- <result property="requirements" column="requirements_" />
- <result property="positionNumber" column="position_number" />
- <result property="workYear" column="work_year" />
- <result property="education" column="education_" />
- <result property="positionSex" column="position_sex" />
- <result property="readTimes" column="read_times" />
- <result property="wageType" column="wage_type" />
- <result property="isDiscussPersonally" column="is_discuss_personally" />
- <result property="contactPerson" column="contact_person" />
- <result property="tel" column="tel_" />
- <result property="status" column="status_" />
- <result property="approveStatus" column="approve_status" />
- <result property="readingTimes" column="reading_times" />
- <result property="collectionTimes" column="collection_times" />
- <result property="deliveryTimes" column="delivery_times" />
- <result property="createBy" column="create_by" />
- <result property="createTime" column="create_time" />
- <result property="updateBy" column="update_by" />
- <result property="updateTime" column="update_time" />
- <result property="delFlag" column="del_flag" />
- </resultMap>
- <insert id="insert" parameterType="com.jpsoft.employment.modules.job.entity.Recruitment">
- <!--
- <selectKey resultType="java.lang.String" order="BEFORE" keyProperty="id">
- select sys_guid() from dual
- </selectKey>
- -->
- <![CDATA[
- insert into job_recruitment
- (id_,company_id,title_,area_,address_,position_,position_message,requirements_,position_number,work_year,education_,position_sex,read_times,wage_type,is_discuss_personally,contact_person,tel_,status_,approve_status,reading_times,collection_times,delivery_times,create_by,create_time,update_by,update_time,del_flag)
- values
- (
- #{id,jdbcType=VARCHAR}
- ,#{companyId,jdbcType=VARCHAR}
- ,#{title,jdbcType=VARCHAR}
- ,#{area,jdbcType=VARCHAR}
- ,#{address,jdbcType=VARCHAR}
- ,#{position,jdbcType=VARCHAR}
- ,#{positionMessage,jdbcType=VARCHAR}
- ,#{requirements,jdbcType=VARCHAR}
- ,#{positionNumber,jdbcType= NUMERIC }
- ,#{workYear,jdbcType=VARCHAR}
- ,#{education,jdbcType=VARCHAR}
- ,#{positionSex,jdbcType=VARCHAR}
- ,#{readTimes,jdbcType= NUMERIC }
- ,#{wageType,jdbcType=VARCHAR}
- ,#{isDiscussPersonally,jdbcType= NUMERIC }
- ,#{contactPerson,jdbcType=VARCHAR}
- ,#{tel,jdbcType=VARCHAR}
- ,#{status,jdbcType=VARCHAR}
- ,#{approveStatus,jdbcType=VARCHAR}
- ,#{readingTimes,jdbcType= NUMERIC }
- ,#{collectionTimes,jdbcType= NUMERIC }
- ,#{deliveryTimes,jdbcType= NUMERIC }
- ,#{createBy,jdbcType=VARCHAR}
- ,#{createTime,jdbcType= TIMESTAMP }
- ,#{updateBy,jdbcType=VARCHAR}
- ,#{updateTime,jdbcType= TIMESTAMP }
- ,#{delFlag,jdbcType= NUMERIC }
- )
- ]]>
- </insert>
- <delete id="delete" parameterType="string">
- delete from job_recruitment where id_=#{id,jdbcType=VARCHAR}
- </delete>
- <update id="update" parameterType="com.jpsoft.employment.modules.job.entity.Recruitment">
- update job_recruitment
- <set>
- <if test="companyId!=null">
- company_id=#{companyId,jdbcType=VARCHAR},
- </if>
- <if test="title!=null">
- title_=#{title,jdbcType=VARCHAR},
- </if>
- <if test="area!=null">
- area_=#{area,jdbcType=VARCHAR},
- </if>
- <if test="address!=null">
- address_=#{address,jdbcType=VARCHAR},
- </if>
- <if test="position!=null">
- position_=#{position,jdbcType=VARCHAR},
- </if>
- <if test="positionMessage!=null">
- position_message=#{positionMessage,jdbcType=VARCHAR},
- </if>
- <if test="requirements!=null">
- requirements_=#{requirements,jdbcType=VARCHAR},
- </if>
- <if test="positionNumber!=null">
- position_number=#{positionNumber,jdbcType= NUMERIC },
- </if>
- <if test="workYear!=null">
- work_year=#{workYear,jdbcType=VARCHAR},
- </if>
- <if test="education!=null">
- education_=#{education,jdbcType=VARCHAR},
- </if>
- <if test="positionSex!=null">
- position_sex=#{positionSex,jdbcType=VARCHAR},
- </if>
- <if test="readTimes!=null">
- read_times=#{readTimes,jdbcType= NUMERIC },
- </if>
- <if test="wageType!=null">
- wage_type=#{wageType,jdbcType=VARCHAR},
- </if>
- <if test="isDiscussPersonally!=null">
- is_discuss_personally=#{isDiscussPersonally,jdbcType= NUMERIC },
- </if>
- <if test="contactPerson!=null">
- contact_person=#{contactPerson,jdbcType=VARCHAR},
- </if>
- <if test="tel!=null">
- tel_=#{tel,jdbcType=VARCHAR},
- </if>
- <if test="status!=null">
- status_=#{status,jdbcType=VARCHAR},
- </if>
- <if test="approveStatus!=null">
- approve_status=#{approveStatus,jdbcType=VARCHAR},
- </if>
- <if test="readingTimes!=null">
- reading_times=#{readingTimes,jdbcType= NUMERIC },
- </if>
- <if test="collectionTimes!=null">
- collection_times=#{collectionTimes,jdbcType= NUMERIC },
- </if>
- <if test="deliveryTimes!=null">
- delivery_times=#{deliveryTimes,jdbcType= NUMERIC },
- </if>
- <if test="createBy!=null">
- create_by=#{createBy,jdbcType=VARCHAR},
- </if>
- <if test="createTime!=null">
- create_time=#{createTime,jdbcType= TIMESTAMP },
- </if>
- <if test="updateBy!=null">
- update_by=#{updateBy,jdbcType=VARCHAR},
- </if>
- <if test="updateTime!=null">
- update_time=#{updateTime,jdbcType= TIMESTAMP },
- </if>
- <if test="delFlag!=null">
- del_flag=#{delFlag,jdbcType= NUMERIC },
- </if>
- </set>
- where id_=#{id}
- </update>
- <select id="get" parameterType="string" resultMap="RecruitmentMap">
- select * from job_recruitment where id_=#{0}
- </select>
- <select id="exist" parameterType="string" resultType="int">
- select count(*) from job_recruitment where id_=#{0}
- </select>
- <select id="list" resultMap="RecruitmentMap">
- select * from job_recruitment
- </select>
- <select id="search" parameterType="hashmap" resultMap="RecruitmentMap">
- <![CDATA[
- select * from job_recruitment
- ]]>
- <where>
- del_flag = 0
- <if test="searchParams.id != null">
- and ID_ like #{searchParams.id}
- </if>
- <if test="searchParams.status != null">
- and status_ = #{searchParams.status}
- </if>
- <if test="searchParams.approveStatus != null">
- and approve_status = #{searchParams.approveStatus}
- </if>
- </where>
- <foreach item="sort" collection="sortList" open="order by" separator=",">
- ${sort.name} ${sort.order}
- </foreach>
- </select>
- <select id="foundPageList" parameterType="hashmap" resultType="map">
- <![CDATA[
- SELECT
- jr.id_ AS id,
- jr.title_ AS title,
- jr.is_discuss_personally AS isDiscussPersonally,
- jr.requirements_ AS requirements,
- jr.address_ AS address,
- bc.logo_ AS logo,
- bc.name_ AS name,
- sdd.name_ AS scaleName,
- bci.city_name AS cityName,
- jwc.name_ AS code
- FROM
- job_recruitment AS jr
- INNER JOIN base_company AS bc
- INNER JOIN sys_data_dictionary AS sdd
- INNER JOIN base_city AS bci
- INNER JOIN job_work_category AS jwc ON jr.company_id = bc.id_
- AND bc.scale_ = sdd.id_
- AND jr.area_ = bci.id_
- AND jr.position_ = jwc.id_
- ]]>
- <where>
- <if test="searchParams.id != null">
- and bc.id_ like #{searchParams.id}
- </if>
- <if test="searchParams.title != null">
- and jr.title_ like #{searchParams.title}
- </if>
- <if test="searchParams.monthlySalary != null">
- and jr.wage_type like #{searchParams.monthlySalary}
- </if>
- <if test="searchParams.workExperience != null">
- and jr.requirements_ like #{searchParams.workExperience}
- </if>
- <if test="searchParams.education != null">
- and jr.education_ like #{searchParams.education}
- </if>
- <if test="searchParams.recruitmentPosition != null">
- and jr.position_ like #{searchParams.recruitmentPosition}
- </if>
- <if test="searchParams.relevantTitle != null">
- and jr.title_ like #{searchParams.relevantTitle}
- </if>
- <if test="searchParams.notrelevantId != null">
- and jr.id_ != #{searchParams.notrelevantId}
- </if>
- <if test="searchParams.status != null">
- and jr.status_ = #{searchParams.status}
- </if>
- <if test="searchParams.approveStatus != null">
- and jr.approve_status = #{searchParams.approveStatus}
- </if>
- </where>
- <foreach item="sort" collection="sortList" open="order by" separator=",">
- ${sort.name} ${sort.order}
- </foreach>
- </select>
- </mapper>
|