| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312 |
- <?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.idea.workPanel.mapper.ParkWaitReadMapper">
- <resultMap id="BaseResultMap" type="com.idea.workPanel.model.ParkWaitRead">
- <id column="id" jdbcType="VARCHAR" property="id" />
- <result column="read_type" jdbcType="INTEGER" property="readType" />
- <result column="title" jdbcType="VARCHAR" property="title" />
- <result column="src_user_id" jdbcType="VARCHAR" property="srcUserId" />
- <result column="src_user_type" jdbcType="INTEGER" property="srcUserType" />
- <result column="src_user_name" jdbcType="VARCHAR" property="srcUserName" />
- <result column="receive_user_id" jdbcType="VARCHAR" property="receiveUserId" />
- <result column="route_url" jdbcType="VARCHAR" property="routeUrl" />
- <result column="route_param" jdbcType="VARCHAR" property="routeParam" />
- <result column="created_at" jdbcType="TIMESTAMP" property="createdAt" />
- <result column="create_by" jdbcType="VARCHAR" property="createBy" />
- </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, read_type, title, src_user_id, src_user_type, src_user_name, receive_user_id,
- route_url, route_param, created_at, create_by
- </sql>
- <select id="selectByExample" parameterType="com.idea.workPanel.model.ParkWaitReadExample" resultMap="BaseResultMap">
- select
- <if test="distinct">
- distinct
- </if>
- <include refid="Base_Column_List" />
- from park_wait_read
- <if test="_parameter != null">
- <include refid="Example_Where_Clause" />
- </if>
- <if test="orderByClause != null">
- order by ${orderByClause}
- </if>
- </select>
- <select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
- select
- <include refid="Base_Column_List" />
- from park_wait_read
- where id = #{id,jdbcType=VARCHAR}
- </select>
- <delete id="deleteByPrimaryKey" parameterType="java.lang.String">
- delete from park_wait_read
- where id = #{id,jdbcType=VARCHAR}
- </delete>
- <delete id="deleteByExample" parameterType="com.idea.workPanel.model.ParkWaitReadExample">
- delete from park_wait_read
- <if test="_parameter != null">
- <include refid="Example_Where_Clause" />
- </if>
- </delete>
- <insert id="insert" parameterType="com.idea.workPanel.model.ParkWaitRead">
- <selectKey keyProperty="id" order="AFTER" resultType="java.lang.String">
- SELECT LAST_INSERT_ID()
- </selectKey>
- insert into park_wait_read (id, read_type, title, src_user_id,
- src_user_type, src_user_name, receive_user_id,
- route_url, route_param, created_at,
- create_by)
- values (#{id,jdbcType=INTEGER}, #{readType,jdbcType=INTEGER}, #{title,jdbcType=VARCHAR}, #{srcUserId,jdbcType=VARCHAR},
- #{srcUserType,jdbcType=INTEGER}, #{srcUserName,jdbcType=VARCHAR}, #{receiveUserId,jdbcType=VARCHAR},
- #{routeUrl,jdbcType=VARCHAR}, #{routeParam,jdbcType=VARCHAR}, #{createdAt,jdbcType=TIMESTAMP},
- #{createBy,jdbcType=VARCHAR})
- </insert>
- <insert id="insertSelective" parameterType="com.idea.workPanel.model.ParkWaitRead">
- <selectKey keyProperty="id" order="AFTER" resultType="java.lang.String">
- SELECT LAST_INSERT_ID()
- </selectKey>
- insert into park_wait_read
- <trim prefix="(" suffix=")" suffixOverrides=",">
- <if test="id != null">
- id,
- </if>
- <if test="readType != null">
- read_type,
- </if>
- <if test="title != null">
- title,
- </if>
- <if test="srcUserId != null">
- src_user_id,
- </if>
- <if test="srcUserType != null">
- src_user_type,
- </if>
- <if test="srcUserName != null">
- src_user_name,
- </if>
- <if test="receiveUserId != null">
- receive_user_id,
- </if>
- <if test="routeUrl != null">
- route_url,
- </if>
- <if test="routeParam != null">
- route_param,
- </if>
- <if test="createdAt != null">
- created_at,
- </if>
- <if test="createBy != null">
- create_by,
- </if>
- </trim>
- <trim prefix="values (" suffix=")" suffixOverrides=",">
- <if test="id != null">
- #{id,jdbcType=INTEGER},
- </if>
- <if test="readType != null">
- #{readType,jdbcType=INTEGER},
- </if>
- <if test="title != null">
- #{title,jdbcType=VARCHAR},
- </if>
- <if test="srcUserId != null">
- #{srcUserId,jdbcType=VARCHAR},
- </if>
- <if test="srcUserType != null">
- #{srcUserType,jdbcType=INTEGER},
- </if>
- <if test="srcUserName != null">
- #{srcUserName,jdbcType=VARCHAR},
- </if>
- <if test="receiveUserId != null">
- #{receiveUserId,jdbcType=VARCHAR},
- </if>
- <if test="routeUrl != null">
- #{routeUrl,jdbcType=VARCHAR},
- </if>
- <if test="routeParam != null">
- #{routeParam,jdbcType=VARCHAR},
- </if>
- <if test="createdAt != null">
- #{createdAt,jdbcType=TIMESTAMP},
- </if>
- <if test="createBy != null">
- #{createBy,jdbcType=VARCHAR},
- </if>
- </trim>
- </insert>
- <select id="countByExample" parameterType="com.idea.workPanel.model.ParkWaitReadExample" resultType="java.lang.Long">
- select count(*) from park_wait_read
- <if test="_parameter != null">
- <include refid="Example_Where_Clause" />
- </if>
- </select>
- <update id="updateByExampleSelective" parameterType="map">
- update park_wait_read
- <set>
- <if test="record.id != null">
- id = #{record.id,jdbcType=VARCHAR},
- </if>
- <if test="record.readType != null">
- read_type = #{record.readType,jdbcType=INTEGER},
- </if>
- <if test="record.title != null">
- title = #{record.title,jdbcType=VARCHAR},
- </if>
- <if test="record.srcUserId != null">
- src_user_id = #{record.srcUserId,jdbcType=VARCHAR},
- </if>
- <if test="record.srcUserType != null">
- src_user_type = #{record.srcUserType,jdbcType=INTEGER},
- </if>
- <if test="record.srcUserName != null">
- src_user_name = #{record.srcUserName,jdbcType=VARCHAR},
- </if>
- <if test="record.receiveUserId != null">
- receive_user_id = #{record.receiveUserId,jdbcType=VARCHAR},
- </if>
- <if test="record.routeUrl != null">
- route_url = #{record.routeUrl,jdbcType=VARCHAR},
- </if>
- <if test="record.routeParam != null">
- route_param = #{record.routeParam,jdbcType=VARCHAR},
- </if>
- <if test="record.createdAt != null">
- created_at = #{record.createdAt,jdbcType=TIMESTAMP},
- </if>
- <if test="record.createBy != null">
- create_by = #{record.createBy,jdbcType=VARCHAR},
- </if>
- </set>
- <if test="_parameter != null">
- <include refid="Update_By_Example_Where_Clause" />
- </if>
- </update>
- <update id="updateByExample" parameterType="map">
- update park_wait_read
- set id = #{record.id,jdbcType=VARCHAR},
- read_type = #{record.readType,jdbcType=INTEGER},
- title = #{record.title,jdbcType=VARCHAR},
- src_user_id = #{record.srcUserId,jdbcType=VARCHAR},
- src_user_type = #{record.srcUserType,jdbcType=INTEGER},
- src_user_name = #{record.srcUserName,jdbcType=VARCHAR},
- receive_user_id = #{record.receiveUserId,jdbcType=VARCHAR},
- route_url = #{record.routeUrl,jdbcType=VARCHAR},
- route_param = #{record.routeParam,jdbcType=VARCHAR},
- created_at = #{record.createdAt,jdbcType=TIMESTAMP},
- create_by = #{record.createBy,jdbcType=VARCHAR}
- <if test="_parameter != null">
- <include refid="Update_By_Example_Where_Clause" />
- </if>
- </update>
- <update id="updateByPrimaryKeySelective" parameterType="com.idea.workPanel.model.ParkWaitRead">
- update park_wait_read
- <set>
- <if test="readType != null">
- read_type = #{readType,jdbcType=INTEGER},
- </if>
- <if test="title != null">
- title = #{title,jdbcType=VARCHAR},
- </if>
- <if test="srcUserId != null">
- src_user_id = #{srcUserId,jdbcType=VARCHAR},
- </if>
- <if test="srcUserType != null">
- src_user_type = #{srcUserType,jdbcType=INTEGER},
- </if>
- <if test="srcUserName != null">
- src_user_name = #{srcUserName,jdbcType=VARCHAR},
- </if>
- <if test="receiveUserId != null">
- receive_user_id = #{receiveUserId,jdbcType=VARCHAR},
- </if>
- <if test="routeUrl != null">
- route_url = #{routeUrl,jdbcType=VARCHAR},
- </if>
- <if test="routeParam != null">
- route_param = #{routeParam,jdbcType=VARCHAR},
- </if>
- <if test="createdAt != null">
- created_at = #{createdAt,jdbcType=TIMESTAMP},
- </if>
- <if test="createBy != null">
- create_by = #{createBy,jdbcType=VARCHAR},
- </if>
- </set>
- where id = #{id,jdbcType=VARCHAR}
- </update>
- <update id="updateByPrimaryKey" parameterType="com.idea.workPanel.model.ParkWaitRead">
- update park_wait_read
- set read_type = #{readType,jdbcType=INTEGER},
- title = #{title,jdbcType=VARCHAR},
- src_user_id = #{srcUserId,jdbcType=VARCHAR},
- src_user_type = #{srcUserType,jdbcType=INTEGER},
- src_user_name = #{srcUserName,jdbcType=VARCHAR},
- receive_user_id = #{receiveUserId,jdbcType=VARCHAR},
- route_url = #{routeUrl,jdbcType=VARCHAR},
- route_param = #{routeParam,jdbcType=VARCHAR},
- created_at = #{createdAt,jdbcType=TIMESTAMP},
- create_by = #{createBy,jdbcType=VARCHAR}
- where id = #{id,jdbcType=VARCHAR}
- </update>
- </mapper>
|