<?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.boco.nbd.wios.manage.mapper.def.RoleMenuMapper" > <resultMap id="BaseResultMap" type="com.boco.nbd.wios.manage.entity.bo.RoleMenu" > <!-- WARNING - @mbggenerated This element is automatically generated by MyBatis Generator, do not modify. This element was generated on Mon May 25 10:18:21 CST 2020. --> <id column="id" property="id" jdbcType="INTEGER" /> <result column="role_id" property="roleId" jdbcType="INTEGER" /> <result column="menu_id" property="menuId" jdbcType="VARCHAR" /> <result column="create_account_id" property="createAccountId" jdbcType="INTEGER" /> <result column="create_time" property="createTime" jdbcType="TIMESTAMP" /> </resultMap> <sql id="Example_Where_Clause" > <!-- WARNING - @mbggenerated This element is automatically generated by MyBatis Generator, do not modify. This element was generated on Mon May 25 10:18:21 CST 2020. --> <where > <foreach collection="oredCriteria" item="criteria" separator="or" > <if test="criteria.valid" > <trim prefix="(" suffix=")" prefixOverrides="and" > <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 collection="criterion.value" item="listItem" open="(" close=")" separator="," > #{listItem} </foreach> </when> </choose> </foreach> </trim> </if> </foreach> </where> </sql> <sql id="Update_By_Example_Where_Clause" > <!-- WARNING - @mbggenerated This element is automatically generated by MyBatis Generator, do not modify. This element was generated on Mon May 25 10:18:21 CST 2020. --> <where > <foreach collection="example.oredCriteria" item="criteria" separator="or" > <if test="criteria.valid" > <trim prefix="(" suffix=")" prefixOverrides="and" > <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 collection="criterion.value" item="listItem" open="(" close=")" separator="," > #{listItem} </foreach> </when> </choose> </foreach> </trim> </if> </foreach> </where> </sql> <sql id="Base_Column_List" > <!-- WARNING - @mbggenerated This element is automatically generated by MyBatis Generator, do not modify. This element was generated on Mon May 25 10:18:21 CST 2020. --> id, role_id, menu_id, create_account_id, create_time </sql> <select id="selectByExample" resultMap="BaseResultMap" parameterType="com.boco.nbd.wios.manage.entity.bo.RoleMenuCriteria" > <!-- WARNING - @mbggenerated This element is automatically generated by MyBatis Generator, do not modify. This element was generated on Mon May 25 10:18:21 CST 2020. --> select <if test="distinct" > distinct </if> <include refid="Base_Column_List" /> from wb_role_menu <if test="_parameter != null" > <include refid="Example_Where_Clause" /> </if> <if test="orderByClause != null" > order by ${orderByClause} </if> </select> <select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.Integer" > <!-- WARNING - @mbggenerated This element is automatically generated by MyBatis Generator, do not modify. This element was generated on Mon May 25 10:18:21 CST 2020. --> select <include refid="Base_Column_List" /> from wb_role_menu where id = #{id,jdbcType=INTEGER} </select> <delete id="deleteByPrimaryKey" parameterType="java.lang.Integer" > <!-- WARNING - @mbggenerated This element is automatically generated by MyBatis Generator, do not modify. This element was generated on Mon May 25 10:18:21 CST 2020. --> delete from wb_role_menu where id = #{id,jdbcType=INTEGER} </delete> <delete id="deleteByExample" parameterType="com.boco.nbd.wios.manage.entity.bo.RoleMenuCriteria" > <!-- WARNING - @mbggenerated This element is automatically generated by MyBatis Generator, do not modify. This element was generated on Mon May 25 10:18:21 CST 2020. --> delete from wb_role_menu <if test="_parameter != null" > <include refid="Example_Where_Clause" /> </if> </delete> <insert id="insert" parameterType="com.boco.nbd.wios.manage.entity.bo.RoleMenu" > <!-- WARNING - @mbggenerated This element is automatically generated by MyBatis Generator, do not modify. This element was generated on Mon May 25 10:18:21 CST 2020. --> insert into wb_role_menu (id, role_id, menu_id, create_account_id, create_time) values (#{id,jdbcType=INTEGER}, #{roleId,jdbcType=INTEGER}, #{menuId,jdbcType=VARCHAR}, #{createAccountId,jdbcType=INTEGER}, #{createTime,jdbcType=TIMESTAMP}) </insert> <insert id="insertSelective" parameterType="com.boco.nbd.wios.manage.entity.bo.RoleMenu" > <!-- WARNING - @mbggenerated This element is automatically generated by MyBatis Generator, do not modify. This element was generated on Mon May 25 10:18:21 CST 2020. --> insert into wb_role_menu <trim prefix="(" suffix=")" suffixOverrides="," > <if test="id != null" > id, </if> <if test="roleId != null" > role_id, </if> <if test="menuId != null" > menu_id, </if> <if test="createAccountId != null" > create_account_id, </if> <if test="createTime != null" > create_time, </if> </trim> <trim prefix="values (" suffix=")" suffixOverrides="," > <if test="id != null" > #{id,jdbcType=INTEGER}, </if> <if test="roleId != null" > #{roleId,jdbcType=INTEGER}, </if> <if test="menuId != null" > #{menuId,jdbcType=VARCHAR}, </if> <if test="createAccountId != null" > #{createAccountId,jdbcType=INTEGER}, </if> <if test="createTime != null" > #{createTime,jdbcType=TIMESTAMP}, </if> </trim> </insert> <select id="countByExample" parameterType="com.boco.nbd.wios.manage.entity.bo.RoleMenuCriteria" resultType="java.lang.Integer" > <!-- WARNING - @mbggenerated This element is automatically generated by MyBatis Generator, do not modify. This element was generated on Mon May 25 10:18:21 CST 2020. --> select count(*) from wb_role_menu <if test="_parameter != null" > <include refid="Example_Where_Clause" /> </if> </select> <update id="updateByExampleSelective" parameterType="map" > <!-- WARNING - @mbggenerated This element is automatically generated by MyBatis Generator, do not modify. This element was generated on Mon May 25 10:18:21 CST 2020. --> update wb_role_menu <set > <if test="record.id != null" > id = #{record.id,jdbcType=INTEGER}, </if> <if test="record.roleId != null" > role_id = #{record.roleId,jdbcType=INTEGER}, </if> <if test="record.menuId != null" > menu_id = #{record.menuId,jdbcType=VARCHAR}, </if> <if test="record.createAccountId != null" > create_account_id = #{record.createAccountId,jdbcType=INTEGER}, </if> <if test="record.createTime != null" > create_time = #{record.createTime,jdbcType=TIMESTAMP}, </if> </set> <if test="_parameter != null" > <include refid="Update_By_Example_Where_Clause" /> </if> </update> <update id="updateByExample" parameterType="map" > <!-- WARNING - @mbggenerated This element is automatically generated by MyBatis Generator, do not modify. This element was generated on Mon May 25 10:18:21 CST 2020. --> update wb_role_menu set id = #{record.id,jdbcType=INTEGER}, role_id = #{record.roleId,jdbcType=INTEGER}, menu_id = #{record.menuId,jdbcType=VARCHAR}, create_account_id = #{record.createAccountId,jdbcType=INTEGER}, create_time = #{record.createTime,jdbcType=TIMESTAMP} <if test="_parameter != null" > <include refid="Update_By_Example_Where_Clause" /> </if> </update> <update id="updateByPrimaryKeySelective" parameterType="com.boco.nbd.wios.manage.entity.bo.RoleMenu" > <!-- WARNING - @mbggenerated This element is automatically generated by MyBatis Generator, do not modify. This element was generated on Mon May 25 10:18:21 CST 2020. --> update wb_role_menu <set > <if test="roleId != null" > role_id = #{roleId,jdbcType=INTEGER}, </if> <if test="menuId != null" > menu_id = #{menuId,jdbcType=VARCHAR}, </if> <if test="createAccountId != null" > create_account_id = #{createAccountId,jdbcType=INTEGER}, </if> <if test="createTime != null" > create_time = #{createTime,jdbcType=TIMESTAMP}, </if> </set> where id = #{id,jdbcType=INTEGER} </update> <update id="updateByPrimaryKey" parameterType="com.boco.nbd.wios.manage.entity.bo.RoleMenu" > <!-- WARNING - @mbggenerated This element is automatically generated by MyBatis Generator, do not modify. This element was generated on Mon May 25 10:18:21 CST 2020. --> update wb_role_menu set role_id = #{roleId,jdbcType=INTEGER}, menu_id = #{menuId,jdbcType=VARCHAR}, create_account_id = #{createAccountId,jdbcType=INTEGER}, create_time = #{createTime,jdbcType=TIMESTAMP} where id = #{id,jdbcType=INTEGER} </update> </mapper>