123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162 |
- <?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.mofangchuxing.aska.dao.mapper.AskaChannelsMapper">
- <resultMap id="BaseResultMap" type="com.mofangchuxing.aska.dao.domain.AskaChannels">
- <id property="id" column="id" jdbcType="INTEGER"/>
- <result property="name" column="name" jdbcType="CHAR"/>
- <result property="prefix" column="prefix" jdbcType="CHAR"/>
- <result property="ownerId" column="ownerId" jdbcType="INTEGER"/>
- <result property="phone" column="phone" jdbcType="CHAR"/>
- <result property="note" column="note" jdbcType="VARCHAR"/>
- <result property="account" column="account" jdbcType="VARCHAR"/>
- <result property="accountname" column="accountName" jdbcType="VARCHAR"/>
- <result property="apiv3" column="apiv3" jdbcType="VARCHAR"/>
- <result property="certpath" column="certPath" jdbcType="VARCHAR"/>
- <result property="tripartite" column="tripartite" jdbcType="CHAR"/>
- <result property="tripvalue" column="tripvalue" jdbcType="INTEGER"/>
- <result property="realtimesplit" column="realtimeSplit" jdbcType="INTEGER"/>
- <result property="status" column="status" jdbcType="CHAR"/>
- </resultMap>
- <sql id="Base_Column_List">
- id,name,prefix,
- ownerId,phone,note,
- account,accountName,apiv3,
- certPath,tripartite,tripvalue,
- realtimeSplit,status
- </sql>
- <select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
- select
- <include refid="Base_Column_List" />
- from aska_channels
- where id = #{id,jdbcType=INTEGER}
- </select>
- <select id="getAllChannels" resultMap="BaseResultMap">
- select
- <include refid="Base_Column_List" />
- from aska_channels
- where 1=1 <if test="channelName != null">
- and name = #{channelName,jdbcType=CHAR},
- </if>
- </select>
- <delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
- delete from aska_channels
- where id = #{id,jdbcType=INTEGER}
- </delete>
- <insert id="insert" keyColumn="id" keyProperty="id" parameterType="com.mofangchuxing.aska.dao.domain.AskaChannels" useGeneratedKeys="true">
- insert into aska_channels
- ( id,name,prefix
- ,ownerId,phone,note
- ,account,accountName,apiv3
- ,certPath,tripartite,tripvalue
- ,realtimeSplit,status)
- values (#{id,jdbcType=INTEGER},#{name,jdbcType=CHAR},#{prefix,jdbcType=CHAR}
- ,#{ownerid,jdbcType=INTEGER},#{phone,jdbcType=CHAR},#{note,jdbcType=VARCHAR}
- ,#{account,jdbcType=VARCHAR},#{accountname,jdbcType=VARCHAR},#{apiv3,jdbcType=VARCHAR}
- ,#{certpath,jdbcType=VARCHAR},#{tripartite,jdbcType=CHAR},#{tripvalue,jdbcType=INTEGER}
- ,#{realtimesplit,jdbcType=INTEGER},#{status,jdbcType=CHAR})
- </insert>
- <insert id="insertSelective" keyColumn="id" keyProperty="id" parameterType="com.mofangchuxing.aska.dao.domain.AskaChannels" useGeneratedKeys="true">
- insert into aska_channels
- <trim prefix="(" suffix=")" suffixOverrides=",">
- <if test="id != null">id,</if>
- <if test="name != null">name,</if>
- <if test="prefix != null">prefix,</if>
- <if test="ownerid != null">ownerId,</if>
- <if test="phone != null">phone,</if>
- <if test="note != null">note,</if>
- <if test="account != null">account,</if>
- <if test="accountname != null">accountName,</if>
- <if test="apiv3 != null">apiv3,</if>
- <if test="certpath != null">certPath,</if>
- <if test="tripartite != null">tripartite,</if>
- <if test="tripvalue != null">tripvalue,</if>
- <if test="realtimesplit != null">realtimeSplit,</if>
- <if test="status != null">status,</if>
- </trim>
- <trim prefix="values (" suffix=")" suffixOverrides=",">
- <if test="id != null">#{id,jdbcType=INTEGER},</if>
- <if test="name != null">#{name,jdbcType=CHAR},</if>
- <if test="prefix != null">#{prefix,jdbcType=CHAR},</if>
- <if test="ownerid != null">#{ownerid,jdbcType=INTEGER},</if>
- <if test="phone != null">#{phone,jdbcType=CHAR},</if>
- <if test="note != null">#{note,jdbcType=VARCHAR},</if>
- <if test="account != null">#{account,jdbcType=VARCHAR},</if>
- <if test="accountname != null">#{accountname,jdbcType=VARCHAR},</if>
- <if test="apiv3 != null">#{apiv3,jdbcType=VARCHAR},</if>
- <if test="certpath != null">#{certpath,jdbcType=VARCHAR},</if>
- <if test="tripartite != null">#{tripartite,jdbcType=CHAR},</if>
- <if test="tripvalue != null">#{tripvalue,jdbcType=INTEGER},</if>
- <if test="realtimesplit != null">#{realtimesplit,jdbcType=INTEGER},</if>
- <if test="status != null">#{status,jdbcType=CHAR},</if>
- </trim>
- </insert>
- <update id="updateByPrimaryKeySelective" parameterType="com.mofangchuxing.aska.dao.domain.AskaChannels">
- update aska_channels
- <set>
- <if test="name != null">
- name = #{name,jdbcType=CHAR},
- </if>
- <if test="prefix != null">
- prefix = #{prefix,jdbcType=CHAR},
- </if>
- <if test="ownerid != null">
- ownerId = #{ownerid,jdbcType=INTEGER},
- </if>
- <if test="phone != null">
- phone = #{phone,jdbcType=CHAR},
- </if>
- <if test="note != null">
- note = #{note,jdbcType=VARCHAR},
- </if>
- <if test="account != null">
- account = #{account,jdbcType=VARCHAR},
- </if>
- <if test="accountname != null">
- accountName = #{accountname,jdbcType=VARCHAR},
- </if>
- <if test="apiv3 != null">
- apiv3 = #{apiv3,jdbcType=VARCHAR},
- </if>
- <if test="certpath != null">
- certPath = #{certpath,jdbcType=VARCHAR},
- </if>
- <if test="tripartite != null">
- tripartite = #{tripartite,jdbcType=CHAR},
- </if>
- <if test="tripvalue != null">
- tripvalue = #{tripvalue,jdbcType=INTEGER},
- </if>
- <if test="realtimesplit != null">
- realtimeSplit = #{realtimesplit,jdbcType=INTEGER},
- </if>
- <if test="status != null">
- status = #{status,jdbcType=CHAR},
- </if>
- </set>
- where id = #{id,jdbcType=INTEGER}
- </update>
- <update id="updateByPrimaryKey" parameterType="com.mofangchuxing.aska.dao.domain.AskaChannels">
- update aska_channels
- set
- name = #{name,jdbcType=CHAR},
- prefix = #{prefix,jdbcType=CHAR},
- ownerId = #{ownerid,jdbcType=INTEGER},
- phone = #{phone,jdbcType=CHAR},
- note = #{note,jdbcType=VARCHAR},
- account = #{account,jdbcType=VARCHAR},
- accountName = #{accountname,jdbcType=VARCHAR},
- apiv3 = #{apiv3,jdbcType=VARCHAR},
- certPath = #{certpath,jdbcType=VARCHAR},
- tripartite = #{tripartite,jdbcType=CHAR},
- tripvalue = #{tripvalue,jdbcType=INTEGER},
- realtimeSplit = #{realtimesplit,jdbcType=INTEGER},
- status = #{status,jdbcType=CHAR}
- where id = #{id,jdbcType=INTEGER}
- </update>
- </mapper>
|