123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133 |
- <?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.game.business.mapper.AppChargeChannelMapper">
-
- <resultMap type="com.game.business.domain.AppChargeChannel" id="AppChargeChannelResult">
- <result property="id" column="id" />
- <result property="name" column="name" />
- <result property="channelKey" column="channel_key" />
- <result property="rate" column="rate" />
- <result property="logoUrl" column="logo_url" />
- <result property="company" column="company" />
- <result property="appId" column="app_id" />
- <result property="appSecret" column="app_secret" />
- <result property="thirdUrl" column="third_url" />
- <result property="status" column="status" />
- <result property="certPath" column="cert_path" />
- <result property="aliPublicCert" column="ali_public_cert" />
- <result property="aliApplyCert" column="ali_apply_cert" />
- <result property="aliCaCert" column="ali_ca_cert" />
- <result property="merchantNo" column="merchant_no" />
- <result property="apiSecret" column="api_secret" />
- <result property="orderno" column="orderno" />
- </resultMap>
- <sql id="selectAppChargeChannelVo">
- select id, name, channel_key, rate, logo_url, company, app_id, app_secret, third_url, status, cert_path, ali_public_cert, ali_apply_cert, ali_ca_cert, merchant_no, api_secret, orderno from app_charge_channel
- </sql>
- <select id="selectAppChargeChannelList" parameterType="com.game.business.domain.AppChargeChannel" resultMap="AppChargeChannelResult">
- <include refid="selectAppChargeChannelVo"/>
- <where>
- <if test="name != null and name != ''"> and name like concat('%', #{name}, '%')</if>
- <if test="channelKey != null and channelKey != ''"> and channel_key = #{channelKey}</if>
- <if test="rate != null "> and rate = #{rate}</if>
- <if test="logoUrl != null and logoUrl != ''"> and logo_url = #{logoUrl}</if>
- <if test="company != null and company != ''"> and company = #{company}</if>
- <if test="appId != null and appId != ''"> and app_id = #{appId}</if>
- <if test="appSecret != null and appSecret != ''"> and app_secret = #{appSecret}</if>
- <if test="thirdUrl != null and thirdUrl != ''"> and third_url = #{thirdUrl}</if>
- <if test="status != null "> and status = #{status}</if>
- <if test="certPath != null and certPath != ''"> and cert_path = #{certPath}</if>
- <if test="aliPublicCert != null and aliPublicCert != ''"> and ali_public_cert = #{aliPublicCert}</if>
- <if test="aliApplyCert != null and aliApplyCert != ''"> and ali_apply_cert = #{aliApplyCert}</if>
- <if test="aliCaCert != null and aliCaCert != ''"> and ali_ca_cert = #{aliCaCert}</if>
- <if test="merchantNo != null and merchantNo != ''"> and merchant_no = #{merchantNo}</if>
- <if test="apiSecret != null and apiSecret != ''"> and api_secret = #{apiSecret}</if>
- <if test="orderno != null "> and orderno = #{orderno}</if>
- </where>
- </select>
-
- <select id="selectAppChargeChannelById" parameterType="Long" resultMap="AppChargeChannelResult">
- <include refid="selectAppChargeChannelVo"/>
- where id = #{id}
- </select>
-
- <insert id="insertAppChargeChannel" parameterType="com.game.business.domain.AppChargeChannel">
- insert into app_charge_channel
- <trim prefix="(" suffix=")" suffixOverrides=",">
- <if test="id != null">id,</if>
- <if test="name != null">name,</if>
- <if test="channelKey != null">channel_key,</if>
- <if test="rate != null">rate,</if>
- <if test="logoUrl != null">logo_url,</if>
- <if test="company != null">company,</if>
- <if test="appId != null">app_id,</if>
- <if test="appSecret != null">app_secret,</if>
- <if test="thirdUrl != null">third_url,</if>
- <if test="status != null">status,</if>
- <if test="certPath != null">cert_path,</if>
- <if test="aliPublicCert != null">ali_public_cert,</if>
- <if test="aliApplyCert != null">ali_apply_cert,</if>
- <if test="aliCaCert != null">ali_ca_cert,</if>
- <if test="merchantNo != null">merchant_no,</if>
- <if test="apiSecret != null">api_secret,</if>
- <if test="orderno != null">orderno,</if>
- </trim>
- <trim prefix="values (" suffix=")" suffixOverrides=",">
- <if test="id != null">#{id},</if>
- <if test="name != null">#{name},</if>
- <if test="channelKey != null">#{channelKey},</if>
- <if test="rate != null">#{rate},</if>
- <if test="logoUrl != null">#{logoUrl},</if>
- <if test="company != null">#{company},</if>
- <if test="appId != null">#{appId},</if>
- <if test="appSecret != null">#{appSecret},</if>
- <if test="thirdUrl != null">#{thirdUrl},</if>
- <if test="status != null">#{status},</if>
- <if test="certPath != null">#{certPath},</if>
- <if test="aliPublicCert != null">#{aliPublicCert},</if>
- <if test="aliApplyCert != null">#{aliApplyCert},</if>
- <if test="aliCaCert != null">#{aliCaCert},</if>
- <if test="merchantNo != null">#{merchantNo},</if>
- <if test="apiSecret != null">#{apiSecret},</if>
- <if test="orderno != null">#{orderno},</if>
- </trim>
- </insert>
- <update id="updateAppChargeChannel" parameterType="com.game.business.domain.AppChargeChannel">
- update app_charge_channel
- <trim prefix="SET" suffixOverrides=",">
- <if test="name != null">name = #{name},</if>
- <if test="channelKey != null">channel_key = #{channelKey},</if>
- <if test="rate != null">rate = #{rate},</if>
- <if test="logoUrl != null">logo_url = #{logoUrl},</if>
- <if test="company != null">company = #{company},</if>
- <if test="appId != null">app_id = #{appId},</if>
- <if test="appSecret != null">app_secret = #{appSecret},</if>
- <if test="thirdUrl != null">third_url = #{thirdUrl},</if>
- <if test="status != null">status = #{status},</if>
- <if test="certPath != null">cert_path = #{certPath},</if>
- <if test="aliPublicCert != null">ali_public_cert = #{aliPublicCert},</if>
- <if test="aliApplyCert != null">ali_apply_cert = #{aliApplyCert},</if>
- <if test="aliCaCert != null">ali_ca_cert = #{aliCaCert},</if>
- <if test="merchantNo != null">merchant_no = #{merchantNo},</if>
- <if test="apiSecret != null">api_secret = #{apiSecret},</if>
- <if test="orderno != null">orderno = #{orderno},</if>
- </trim>
- where id = #{id}
- </update>
- <delete id="deleteAppChargeChannelById" parameterType="Long">
- delete from app_charge_channel where id = #{id}
- </delete>
- <delete id="deleteAppChargeChannelByIds" parameterType="String">
- delete from app_charge_channel where id in
- <foreach item="id" collection="array" open="(" separator="," close=")">
- #{id}
- </foreach>
- </delete>
- </mapper>
|