|
|
@@ -0,0 +1,48 @@ |
|
|
|
<?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.iformall.mapper.UserBasicGlodConfigMapper"> |
|
|
|
<resultMap id="BaseResultMap" type="com.iformall.domain.po.UserBasicGlodConfig"> |
|
|
|
<id column="id" jdbcType="BIGINT" property="id" /> |
|
|
|
<result column="tenant_id" jdbcType="VARCHAR" property="tenantId" /> |
|
|
|
<result column="parent_tenant_id" jdbcType="VARCHAR" property="parentTenantId"/> |
|
|
|
<result column="project_type" jdbcType="INTEGER" property="projectType" /> |
|
|
|
<result column="type" jdbcType="INTEGER" property="type" /> |
|
|
|
<result column="glod_num" jdbcType="INTEGER" property="glodNum" /> |
|
|
|
<result column="update_date" jdbcType="TIMESTAMP" property="updateDate" /> |
|
|
|
<result column="create_date" jdbcType="TIMESTAMP" property="createDate" /> |
|
|
|
</resultMap> |
|
|
|
|
|
|
|
<sql id="allColumns"> |
|
|
|
`id`,`tenant_id`,`parent_tenant_id`, |
|
|
|
`project_type`,`type`,`glod_num`, |
|
|
|
`create_date`,`update_date` |
|
|
|
</sql> |
|
|
|
|
|
|
|
<sql id="dynamicWhereConditions"> |
|
|
|
where 1 = 1 |
|
|
|
<if test=" null != id "> and `id` = #{id} </if> |
|
|
|
<if test=" null != tenantId and '' != tenantId"> |
|
|
|
and `tenant_id` = #{tenantId} |
|
|
|
</if> |
|
|
|
<if test=" null != parentTenantId and '' != parentTenantId"> |
|
|
|
and `parent_tenant_id` = #{parentTenantId} |
|
|
|
</if> |
|
|
|
<if test=" null != projectType "> and `project_type` = #{projectType} </if> |
|
|
|
<if test=" null != type "> and `type` = #{type} </if> |
|
|
|
|
|
|
|
<if test=" null != ids "> |
|
|
|
and id in |
|
|
|
<foreach collection="ids" index="index" item="idItem" open="(" separator="," close=")"> |
|
|
|
#{idItem} |
|
|
|
</foreach> |
|
|
|
</if> |
|
|
|
<if test=" null != sortColumns"> order by ${sortColumns} </if> |
|
|
|
</sql> |
|
|
|
|
|
|
|
<select id="findList" parameterType="com.iformall.domain.po.UserBasicGlodConfig" resultMap="BaseResultMap"> |
|
|
|
select <include refid="allColumns" /> |
|
|
|
from user_basic_glod_config |
|
|
|
<include refid="dynamicWhereConditions" /> |
|
|
|
</select> |
|
|
|
|
|
|
|
</mapper> |