You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
weaver-hrm-organization/src/com/engine/organization/mapper/extend/ExtendTitleMapper.xml

57 lines
1.8 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.engine.organization.mapper.extend.ExtendTitleMapper">
<resultMap id="BaseResultMap" type="com.engine.organization.entity.extend.po.ExtendTitlePO">
<result column="id" property="id"/>
<result column="group_id" property="groupid"/>
<result column="title" property="title"/>
<result column="show_order" property="showOrder"/>
<result column="is_show" property="isShow"/>
<result column="creator" property="creator"/>
<result column="delete_type" property="deleteType"/>
<result column="create_time" property="createTime"/>
<result column="update_time" property="updateTime"/>
</resultMap>
<!-- 表字段 -->
<sql id="baseColumns">
t
.
id
, t.group_id
, t.title
, show_order
, is_show
, t.creator
, t.delete_type
, t.create_time
, t.update_time
</sql>
<select id="getTitlesByGroupID" resultMap="BaseResultMap">
SELECT
<include refid="baseColumns"/>
FROM
jcl_field_extendtitle t
WHERE t.delete_type = 0
<if test=" groupId != null and groupId != '' ">
and group_id = #{groupId}
</if>
order by show_order
</select>
<select id="getTitlesByIds" resultMap="BaseResultMap">
SELECT
<include refid="baseColumns"/>
FROM
jcl_field_extendtitle t
WHERE t.delete_type = 0
AND id IN
<foreach collection="ids" open="(" item="id" separator="," close=")">
#{id}
</foreach>
order by show_order
</select>
</mapper>