296 lines
11 KiB
XML
296 lines
11 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="io.dataease.base.mapper.VAuthModelMapper">
|
|
<resultMap id="BaseResultMap" type="io.dataease.base.domain.VAuthModel">
|
|
<result column="id" jdbcType="VARCHAR" property="id" />
|
|
<result column="pid" jdbcType="VARCHAR" property="pid" />
|
|
<result column="node_type" jdbcType="VARCHAR" property="nodeType" />
|
|
<result column="model_type" jdbcType="VARCHAR" property="modelType" />
|
|
<result column="model_inner_type" jdbcType="VARCHAR" property="modelInnerType" />
|
|
<result column="auth_type" jdbcType="VARCHAR" property="authType" />
|
|
<result column="create_by" jdbcType="VARCHAR" property="createBy" />
|
|
<result column="level" jdbcType="BIGINT" property="level" />
|
|
<result column="mode" jdbcType="BIGINT" property="mode" />
|
|
<result column="data_source_id" jdbcType="VARCHAR" property="dataSourceId" />
|
|
</resultMap>
|
|
<resultMap extends="BaseResultMap" id="ResultMapWithBLOBs" type="io.dataease.base.domain.VAuthModelWithBLOBs">
|
|
<result column="name" jdbcType="LONGVARCHAR" property="name" />
|
|
<result column="label" jdbcType="LONGVARCHAR" property="label" />
|
|
</resultMap>
|
|
<sql id="Example_Where_Clause">
|
|
<where>
|
|
<foreach collection="oredCriteria" item="criteria" separator="or">
|
|
<if test="criteria.valid">
|
|
<trim prefix="(" prefixOverrides="and" suffix=")">
|
|
<foreach collection="criteria.criteria" item="criterion">
|
|
<choose>
|
|
<when test="criterion.noValue">
|
|
and ${criterion.condition}
|
|
</when>
|
|
<when test="criterion.singleValue">
|
|
and ${criterion.condition} #{criterion.value}
|
|
</when>
|
|
<when test="criterion.betweenValue">
|
|
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
|
|
</when>
|
|
<when test="criterion.listValue">
|
|
and ${criterion.condition}
|
|
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
|
|
#{listItem}
|
|
</foreach>
|
|
</when>
|
|
</choose>
|
|
</foreach>
|
|
</trim>
|
|
</if>
|
|
</foreach>
|
|
</where>
|
|
</sql>
|
|
<sql id="Update_By_Example_Where_Clause">
|
|
<where>
|
|
<foreach collection="example.oredCriteria" item="criteria" separator="or">
|
|
<if test="criteria.valid">
|
|
<trim prefix="(" prefixOverrides="and" suffix=")">
|
|
<foreach collection="criteria.criteria" item="criterion">
|
|
<choose>
|
|
<when test="criterion.noValue">
|
|
and ${criterion.condition}
|
|
</when>
|
|
<when test="criterion.singleValue">
|
|
and ${criterion.condition} #{criterion.value}
|
|
</when>
|
|
<when test="criterion.betweenValue">
|
|
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
|
|
</when>
|
|
<when test="criterion.listValue">
|
|
and ${criterion.condition}
|
|
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
|
|
#{listItem}
|
|
</foreach>
|
|
</when>
|
|
</choose>
|
|
</foreach>
|
|
</trim>
|
|
</if>
|
|
</foreach>
|
|
</where>
|
|
</sql>
|
|
<sql id="Base_Column_List">
|
|
id, pid, node_type, model_type, model_inner_type, auth_type, create_by, `level`,
|
|
`mode`, data_source_id
|
|
</sql>
|
|
<sql id="Blob_Column_List">
|
|
`name`, `label`
|
|
</sql>
|
|
<select id="selectByExampleWithBLOBs" parameterType="io.dataease.base.domain.VAuthModelExample" resultMap="ResultMapWithBLOBs">
|
|
select
|
|
<if test="distinct">
|
|
distinct
|
|
</if>
|
|
<include refid="Base_Column_List" />
|
|
,
|
|
<include refid="Blob_Column_List" />
|
|
from v_auth_model
|
|
<if test="_parameter != null">
|
|
<include refid="Example_Where_Clause" />
|
|
</if>
|
|
<if test="orderByClause != null">
|
|
order by ${orderByClause}
|
|
</if>
|
|
</select>
|
|
<select id="selectByExample" parameterType="io.dataease.base.domain.VAuthModelExample" resultMap="BaseResultMap">
|
|
select
|
|
<if test="distinct">
|
|
distinct
|
|
</if>
|
|
<include refid="Base_Column_List" />
|
|
from v_auth_model
|
|
<if test="_parameter != null">
|
|
<include refid="Example_Where_Clause" />
|
|
</if>
|
|
<if test="orderByClause != null">
|
|
order by ${orderByClause}
|
|
</if>
|
|
</select>
|
|
<delete id="deleteByExample" parameterType="io.dataease.base.domain.VAuthModelExample">
|
|
delete from v_auth_model
|
|
<if test="_parameter != null">
|
|
<include refid="Example_Where_Clause" />
|
|
</if>
|
|
</delete>
|
|
<insert id="insert" parameterType="io.dataease.base.domain.VAuthModelWithBLOBs">
|
|
insert into v_auth_model (id, pid, node_type,
|
|
model_type, model_inner_type, auth_type,
|
|
create_by, `level`, `mode`,
|
|
data_source_id, `name`, `label`
|
|
)
|
|
values (#{id,jdbcType=VARCHAR}, #{pid,jdbcType=VARCHAR}, #{nodeType,jdbcType=VARCHAR},
|
|
#{modelType,jdbcType=VARCHAR}, #{modelInnerType,jdbcType=VARCHAR}, #{authType,jdbcType=VARCHAR},
|
|
#{createBy,jdbcType=VARCHAR}, #{level,jdbcType=BIGINT}, #{mode,jdbcType=BIGINT},
|
|
#{dataSourceId,jdbcType=VARCHAR}, #{name,jdbcType=LONGVARCHAR}, #{label,jdbcType=LONGVARCHAR}
|
|
)
|
|
</insert>
|
|
<insert id="insertSelective" parameterType="io.dataease.base.domain.VAuthModelWithBLOBs">
|
|
insert into v_auth_model
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
<if test="id != null">
|
|
id,
|
|
</if>
|
|
<if test="pid != null">
|
|
pid,
|
|
</if>
|
|
<if test="nodeType != null">
|
|
node_type,
|
|
</if>
|
|
<if test="modelType != null">
|
|
model_type,
|
|
</if>
|
|
<if test="modelInnerType != null">
|
|
model_inner_type,
|
|
</if>
|
|
<if test="authType != null">
|
|
auth_type,
|
|
</if>
|
|
<if test="createBy != null">
|
|
create_by,
|
|
</if>
|
|
<if test="level != null">
|
|
`level`,
|
|
</if>
|
|
<if test="mode != null">
|
|
`mode`,
|
|
</if>
|
|
<if test="dataSourceId != null">
|
|
data_source_id,
|
|
</if>
|
|
<if test="name != null">
|
|
`name`,
|
|
</if>
|
|
<if test="label != null">
|
|
`label`,
|
|
</if>
|
|
</trim>
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
<if test="id != null">
|
|
#{id,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="pid != null">
|
|
#{pid,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="nodeType != null">
|
|
#{nodeType,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="modelType != null">
|
|
#{modelType,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="modelInnerType != null">
|
|
#{modelInnerType,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="authType != null">
|
|
#{authType,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="createBy != null">
|
|
#{createBy,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="level != null">
|
|
#{level,jdbcType=BIGINT},
|
|
</if>
|
|
<if test="mode != null">
|
|
#{mode,jdbcType=BIGINT},
|
|
</if>
|
|
<if test="dataSourceId != null">
|
|
#{dataSourceId,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="name != null">
|
|
#{name,jdbcType=LONGVARCHAR},
|
|
</if>
|
|
<if test="label != null">
|
|
#{label,jdbcType=LONGVARCHAR},
|
|
</if>
|
|
</trim>
|
|
</insert>
|
|
<select id="countByExample" parameterType="io.dataease.base.domain.VAuthModelExample" resultType="java.lang.Long">
|
|
select count(*) from v_auth_model
|
|
<if test="_parameter != null">
|
|
<include refid="Example_Where_Clause" />
|
|
</if>
|
|
</select>
|
|
<update id="updateByExampleSelective" parameterType="map">
|
|
update v_auth_model
|
|
<set>
|
|
<if test="record.id != null">
|
|
id = #{record.id,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="record.pid != null">
|
|
pid = #{record.pid,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="record.nodeType != null">
|
|
node_type = #{record.nodeType,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="record.modelType != null">
|
|
model_type = #{record.modelType,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="record.modelInnerType != null">
|
|
model_inner_type = #{record.modelInnerType,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="record.authType != null">
|
|
auth_type = #{record.authType,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="record.createBy != null">
|
|
create_by = #{record.createBy,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="record.level != null">
|
|
`level` = #{record.level,jdbcType=BIGINT},
|
|
</if>
|
|
<if test="record.mode != null">
|
|
`mode` = #{record.mode,jdbcType=BIGINT},
|
|
</if>
|
|
<if test="record.dataSourceId != null">
|
|
data_source_id = #{record.dataSourceId,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="record.name != null">
|
|
`name` = #{record.name,jdbcType=LONGVARCHAR},
|
|
</if>
|
|
<if test="record.label != null">
|
|
`label` = #{record.label,jdbcType=LONGVARCHAR},
|
|
</if>
|
|
</set>
|
|
<if test="_parameter != null">
|
|
<include refid="Update_By_Example_Where_Clause" />
|
|
</if>
|
|
</update>
|
|
<update id="updateByExampleWithBLOBs" parameterType="map">
|
|
update v_auth_model
|
|
set id = #{record.id,jdbcType=VARCHAR},
|
|
pid = #{record.pid,jdbcType=VARCHAR},
|
|
node_type = #{record.nodeType,jdbcType=VARCHAR},
|
|
model_type = #{record.modelType,jdbcType=VARCHAR},
|
|
model_inner_type = #{record.modelInnerType,jdbcType=VARCHAR},
|
|
auth_type = #{record.authType,jdbcType=VARCHAR},
|
|
create_by = #{record.createBy,jdbcType=VARCHAR},
|
|
`level` = #{record.level,jdbcType=BIGINT},
|
|
`mode` = #{record.mode,jdbcType=BIGINT},
|
|
data_source_id = #{record.dataSourceId,jdbcType=VARCHAR},
|
|
`name` = #{record.name,jdbcType=LONGVARCHAR},
|
|
`label` = #{record.label,jdbcType=LONGVARCHAR}
|
|
<if test="_parameter != null">
|
|
<include refid="Update_By_Example_Where_Clause" />
|
|
</if>
|
|
</update>
|
|
<update id="updateByExample" parameterType="map">
|
|
update v_auth_model
|
|
set id = #{record.id,jdbcType=VARCHAR},
|
|
pid = #{record.pid,jdbcType=VARCHAR},
|
|
node_type = #{record.nodeType,jdbcType=VARCHAR},
|
|
model_type = #{record.modelType,jdbcType=VARCHAR},
|
|
model_inner_type = #{record.modelInnerType,jdbcType=VARCHAR},
|
|
auth_type = #{record.authType,jdbcType=VARCHAR},
|
|
create_by = #{record.createBy,jdbcType=VARCHAR},
|
|
`level` = #{record.level,jdbcType=BIGINT},
|
|
`mode` = #{record.mode,jdbcType=BIGINT},
|
|
data_source_id = #{record.dataSourceId,jdbcType=VARCHAR}
|
|
<if test="_parameter != null">
|
|
<include refid="Update_By_Example_Where_Clause" />
|
|
</if>
|
|
</update>
|
|
</mapper> |