|
- <?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.simple.mapper.WxPayAccountMapper">
- <resultMap id="BaseResultMap" type="com.simple.domain.po.WxPayAccount">
- <id column="id" jdbcType="BIGINT" property="id" />
- <result column="mch_id" jdbcType="VARCHAR" property="mchId" />
- <result column="api_key" jdbcType="VARCHAR" property="apiKey" />
- <result column="notify_url" jdbcType="VARCHAR" property="notifyUrl" />
- <result column="cert_path" jdbcType="VARCHAR" property="certPath" />
- </resultMap>
-
- <sql id="allColumns">
- `id`,`mch_id`,`api_key`,`notify_url`,`cert_path`
- </sql>
-
- <sql id="dynamicWhereConditions">
- where 1 = 1
-
- <if test=" null != id ">
- and `id` = #{id}
-
- </if>
-
- <if test=" null != mchId ">
- and `mch_id` like concat('%', #{mchId},'%')
-
- </if>
-
- <if test=" null != apiKey ">
- and `api_key` like concat('%', #{apiKey},'%')
-
- </if>
-
- <if test=" null != notifyUrl ">
- and `notify_url` like concat('%', #{notifyUrl},'%')
-
- </if>
-
- <if test=" null != certPath ">
- and `cert_path` like concat('%', #{certPath},'%')
-
- </if>
- <if test=" null != ids ">
- and id in
- <foreach collection="ids" index="index" item="idItem" open="(" separator="," close=")">
- #{idItem}
- </foreach>
- </if>
- <if test=" null != sortColumns"> order by ${sortColumns} </if>
- </sql>
-
- <select id="findList" parameterType="com.simple.domain.po.WxPayAccount" resultMap="BaseResultMap">
- select <include refid="allColumns" /> from wx_pay_account
- <include refid="dynamicWhereConditions" />
- </select>
-
-
-
-
-
-
- </mapper>
|