<?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.renren.modules.sys.dao.algs.FrameMapper">
  <resultMap id="BaseResultMap" type="io.renren.modules.sys.entity.algs.Frame">
    <id column="frame_id" jdbcType="BIGINT" property="frameId" />
    <result column="frame_name" jdbcType="VARCHAR" property="frameName" />
    <result column="remark" jdbcType="VARCHAR" property="remark" />
    <result column="dfs_url" jdbcType="VARCHAR" property="dfsUrl" />
  </resultMap>
  <sql id="Base_Column_List">
    frame_id, frame_name, remark, dfs_url
  </sql>
  <select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
    select 
    <include refid="Base_Column_List" />
    from frame
    where frame_id = #{frameId,jdbcType=BIGINT}
  </select>
  <delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
    delete from frame
    where frame_id = #{frameId,jdbcType=BIGINT}
  </delete>
  <insert id="insert" parameterType="io.renren.modules.sys.entity.algs.Frame">
    insert into frame (frame_id, frame_name, remark, 
      dfs_url)
    values (#{frameId,jdbcType=BIGINT}, #{frameName,jdbcType=VARCHAR}, #{remark,jdbcType=VARCHAR}, 
      #{dfsUrl,jdbcType=VARCHAR})
  </insert>
  <insert id="insertSelective" parameterType="io.renren.modules.sys.entity.algs.Frame">
    insert into frame
    <trim prefix="(" suffix=")" suffixOverrides=",">
      <if test="frameId != null">
        frame_id,
      </if>
      <if test="frameName != null">
        frame_name,
      </if>
      <if test="remark != null">
        remark,
      </if>
      <if test="dfsUrl != null">
        dfs_url,
      </if>
    </trim>
    <trim prefix="values (" suffix=")" suffixOverrides=",">
      <if test="frameId != null">
        #{frameId,jdbcType=BIGINT},
      </if>
      <if test="frameName != null">
        #{frameName,jdbcType=VARCHAR},
      </if>
      <if test="remark != null">
        #{remark,jdbcType=VARCHAR},
      </if>
      <if test="dfsUrl != null">
        #{dfsUrl,jdbcType=VARCHAR},
      </if>
    </trim>
  </insert>
  <update id="updateByPrimaryKeySelective" parameterType="io.renren.modules.sys.entity.algs.Frame">
    update frame
    <set>
      <if test="frameName != null">
        frame_name = #{frameName,jdbcType=VARCHAR},
      </if>
      <if test="remark != null">
        remark = #{remark,jdbcType=VARCHAR},
      </if>
      <if test="dfsUrl != null">
        dfs_url = #{dfsUrl,jdbcType=VARCHAR},
      </if>
    </set>
    where frame_id = #{frameId,jdbcType=BIGINT}
  </update>
  <update id="updateByPrimaryKey" parameterType="io.renren.modules.sys.entity.algs.Frame">
    update frame
    set frame_name = #{frameName,jdbcType=VARCHAR},
      remark = #{remark,jdbcType=VARCHAR},
      dfs_url = #{dfsUrl,jdbcType=VARCHAR}
    where frame_id = #{frameId,jdbcType=BIGINT}
  </update>
</mapper>