VmRechargeRuleMapper.xml 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
  3. <mapper namespace="com.minpay.db.table.mapper.VmRechargeRuleMapper">
  4. <resultMap id="BaseResultMap" type="com.minpay.db.table.model.VmRechargeRule">
  5. <!--
  6. WARNING - @mbggenerated
  7. This element is automatically generated by MyBatis Generator, do not modify.
  8. -->
  9. <id column="VRR_ID" jdbcType="VARCHAR" property="id" />
  10. <result column="VRR_RECHARGE_AMT" jdbcType="VARCHAR" property="rechargeAmt" />
  11. <result column="VRR_GIVE_AMT" jdbcType="VARCHAR" property="giveAmt" />
  12. <result column="VRR_DESC" jdbcType="VARCHAR" property="desc" />
  13. <result column="VRR_CREATE_TIME" jdbcType="VARCHAR" property="createTime" />
  14. <result column="VRR_CREATE_USER" jdbcType="VARCHAR" property="createUser" />
  15. <result column="VRR_STATE" jdbcType="VARCHAR" property="state" />
  16. <result column="VRR_BRANCH" jdbcType="VARCHAR" property="branch" />
  17. </resultMap>
  18. <sql id="Example_Where_Clause">
  19. <!--
  20. WARNING - @mbggenerated
  21. This element is automatically generated by MyBatis Generator, do not modify.
  22. -->
  23. <where>
  24. <foreach collection="oredCriteria" item="criteria" separator="or">
  25. <if test="criteria.valid">
  26. <trim prefix="(" prefixOverrides="and" suffix=")">
  27. <foreach collection="criteria.criteria" item="criterion">
  28. <choose>
  29. <when test="criterion.noValue">
  30. and ${criterion.condition}
  31. </when>
  32. <when test="criterion.singleValue">
  33. and ${criterion.condition} #{criterion.value}
  34. </when>
  35. <when test="criterion.betweenValue">
  36. and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
  37. </when>
  38. <when test="criterion.listValue">
  39. and ${criterion.condition}
  40. <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
  41. #{listItem}
  42. </foreach>
  43. </when>
  44. </choose>
  45. </foreach>
  46. </trim>
  47. </if>
  48. </foreach>
  49. </where>
  50. </sql>
  51. <sql id="Update_By_Example_Where_Clause">
  52. <!--
  53. WARNING - @mbggenerated
  54. This element is automatically generated by MyBatis Generator, do not modify.
  55. -->
  56. <where>
  57. <foreach collection="example.oredCriteria" item="criteria" separator="or">
  58. <if test="criteria.valid">
  59. <trim prefix="(" prefixOverrides="and" suffix=")">
  60. <foreach collection="criteria.criteria" item="criterion">
  61. <choose>
  62. <when test="criterion.noValue">
  63. and ${criterion.condition}
  64. </when>
  65. <when test="criterion.singleValue">
  66. and ${criterion.condition} #{criterion.value}
  67. </when>
  68. <when test="criterion.betweenValue">
  69. and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
  70. </when>
  71. <when test="criterion.listValue">
  72. and ${criterion.condition}
  73. <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
  74. #{listItem}
  75. </foreach>
  76. </when>
  77. </choose>
  78. </foreach>
  79. </trim>
  80. </if>
  81. </foreach>
  82. </where>
  83. </sql>
  84. <sql id="Base_Column_List">
  85. <!--
  86. WARNING - @mbggenerated
  87. This element is automatically generated by MyBatis Generator, do not modify.
  88. -->
  89. VRR_ID, VRR_RECHARGE_AMT, VRR_GIVE_AMT, VRR_DESC, VRR_CREATE_TIME, VRR_CREATE_USER,
  90. VRR_STATE, VRR_BRANCH
  91. </sql>
  92. <select id="selectByExample" parameterType="com.minpay.db.table.model.VmRechargeRuleExample" resultMap="BaseResultMap">
  93. <!--
  94. WARNING - @mbggenerated
  95. This element is automatically generated by MyBatis Generator, do not modify.
  96. -->
  97. select
  98. <if test="distinct">
  99. distinct
  100. </if>
  101. <include refid="Base_Column_List" />
  102. from vm_recharge_rule
  103. <if test="_parameter != null">
  104. <include refid="Example_Where_Clause" />
  105. </if>
  106. <if test="orderByClause != null">
  107. order by ${orderByClause}
  108. </if>
  109. </select>
  110. <select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
  111. <!--
  112. WARNING - @mbggenerated
  113. This element is automatically generated by MyBatis Generator, do not modify.
  114. -->
  115. select
  116. <include refid="Base_Column_List" />
  117. from vm_recharge_rule
  118. where VRR_ID = #{id,jdbcType=VARCHAR}
  119. </select>
  120. <delete id="deleteByPrimaryKey" parameterType="java.lang.String">
  121. <!--
  122. WARNING - @mbggenerated
  123. This element is automatically generated by MyBatis Generator, do not modify.
  124. -->
  125. delete from vm_recharge_rule
  126. where VRR_ID = #{id,jdbcType=VARCHAR}
  127. </delete>
  128. <delete id="deleteByExample" parameterType="com.minpay.db.table.model.VmRechargeRuleExample">
  129. <!--
  130. WARNING - @mbggenerated
  131. This element is automatically generated by MyBatis Generator, do not modify.
  132. -->
  133. delete from vm_recharge_rule
  134. <if test="_parameter != null">
  135. <include refid="Example_Where_Clause" />
  136. </if>
  137. </delete>
  138. <insert id="insert" parameterType="com.minpay.db.table.model.VmRechargeRule">
  139. <!--
  140. WARNING - @mbggenerated
  141. This element is automatically generated by MyBatis Generator, do not modify.
  142. -->
  143. insert into vm_recharge_rule (VRR_ID, VRR_RECHARGE_AMT, VRR_GIVE_AMT,
  144. VRR_DESC, VRR_CREATE_TIME, VRR_CREATE_USER,
  145. VRR_STATE, VRR_BRANCH)
  146. values (#{id,jdbcType=VARCHAR}, #{rechargeAmt,jdbcType=VARCHAR}, #{giveAmt,jdbcType=VARCHAR},
  147. #{desc,jdbcType=VARCHAR}, #{createTime,jdbcType=VARCHAR}, #{createUser,jdbcType=VARCHAR},
  148. #{state,jdbcType=VARCHAR}, #{branch,jdbcType=VARCHAR})
  149. </insert>
  150. <insert id="insertSelective" parameterType="com.minpay.db.table.model.VmRechargeRule">
  151. <!--
  152. WARNING - @mbggenerated
  153. This element is automatically generated by MyBatis Generator, do not modify.
  154. -->
  155. insert into vm_recharge_rule
  156. <trim prefix="(" suffix=")" suffixOverrides=",">
  157. <if test="id != null">
  158. VRR_ID,
  159. </if>
  160. <if test="rechargeAmt != null">
  161. VRR_RECHARGE_AMT,
  162. </if>
  163. <if test="giveAmt != null">
  164. VRR_GIVE_AMT,
  165. </if>
  166. <if test="desc != null">
  167. VRR_DESC,
  168. </if>
  169. <if test="createTime != null">
  170. VRR_CREATE_TIME,
  171. </if>
  172. <if test="createUser != null">
  173. VRR_CREATE_USER,
  174. </if>
  175. <if test="state != null">
  176. VRR_STATE,
  177. </if>
  178. <if test="branch != null">
  179. VRR_BRANCH,
  180. </if>
  181. </trim>
  182. <trim prefix="values (" suffix=")" suffixOverrides=",">
  183. <if test="id != null">
  184. #{id,jdbcType=VARCHAR},
  185. </if>
  186. <if test="rechargeAmt != null">
  187. #{rechargeAmt,jdbcType=VARCHAR},
  188. </if>
  189. <if test="giveAmt != null">
  190. #{giveAmt,jdbcType=VARCHAR},
  191. </if>
  192. <if test="desc != null">
  193. #{desc,jdbcType=VARCHAR},
  194. </if>
  195. <if test="createTime != null">
  196. #{createTime,jdbcType=VARCHAR},
  197. </if>
  198. <if test="createUser != null">
  199. #{createUser,jdbcType=VARCHAR},
  200. </if>
  201. <if test="state != null">
  202. #{state,jdbcType=VARCHAR},
  203. </if>
  204. <if test="branch != null">
  205. #{branch,jdbcType=VARCHAR},
  206. </if>
  207. </trim>
  208. </insert>
  209. <select id="countByExample" parameterType="com.minpay.db.table.model.VmRechargeRuleExample" resultType="java.lang.Integer">
  210. <!--
  211. WARNING - @mbggenerated
  212. This element is automatically generated by MyBatis Generator, do not modify.
  213. -->
  214. select count(*) from vm_recharge_rule
  215. <if test="_parameter != null">
  216. <include refid="Example_Where_Clause" />
  217. </if>
  218. </select>
  219. <update id="updateByExampleSelective" parameterType="map">
  220. <!--
  221. WARNING - @mbggenerated
  222. This element is automatically generated by MyBatis Generator, do not modify.
  223. -->
  224. update vm_recharge_rule
  225. <set>
  226. <if test="record.id != null">
  227. VRR_ID = #{record.id,jdbcType=VARCHAR},
  228. </if>
  229. <if test="record.rechargeAmt != null">
  230. VRR_RECHARGE_AMT = #{record.rechargeAmt,jdbcType=VARCHAR},
  231. </if>
  232. <if test="record.giveAmt != null">
  233. VRR_GIVE_AMT = #{record.giveAmt,jdbcType=VARCHAR},
  234. </if>
  235. <if test="record.desc != null">
  236. VRR_DESC = #{record.desc,jdbcType=VARCHAR},
  237. </if>
  238. <if test="record.createTime != null">
  239. VRR_CREATE_TIME = #{record.createTime,jdbcType=VARCHAR},
  240. </if>
  241. <if test="record.createUser != null">
  242. VRR_CREATE_USER = #{record.createUser,jdbcType=VARCHAR},
  243. </if>
  244. <if test="record.state != null">
  245. VRR_STATE = #{record.state,jdbcType=VARCHAR},
  246. </if>
  247. <if test="record.branch != null">
  248. VRR_BRANCH = #{record.branch,jdbcType=VARCHAR},
  249. </if>
  250. </set>
  251. <if test="_parameter != null">
  252. <include refid="Update_By_Example_Where_Clause" />
  253. </if>
  254. </update>
  255. <update id="updateByExample" parameterType="map">
  256. <!--
  257. WARNING - @mbggenerated
  258. This element is automatically generated by MyBatis Generator, do not modify.
  259. -->
  260. update vm_recharge_rule
  261. set VRR_ID = #{record.id,jdbcType=VARCHAR},
  262. VRR_RECHARGE_AMT = #{record.rechargeAmt,jdbcType=VARCHAR},
  263. VRR_GIVE_AMT = #{record.giveAmt,jdbcType=VARCHAR},
  264. VRR_DESC = #{record.desc,jdbcType=VARCHAR},
  265. VRR_CREATE_TIME = #{record.createTime,jdbcType=VARCHAR},
  266. VRR_CREATE_USER = #{record.createUser,jdbcType=VARCHAR},
  267. VRR_STATE = #{record.state,jdbcType=VARCHAR},
  268. VRR_BRANCH = #{record.branch,jdbcType=VARCHAR}
  269. <if test="_parameter != null">
  270. <include refid="Update_By_Example_Where_Clause" />
  271. </if>
  272. </update>
  273. <update id="updateByPrimaryKeySelective" parameterType="com.minpay.db.table.model.VmRechargeRule">
  274. <!--
  275. WARNING - @mbggenerated
  276. This element is automatically generated by MyBatis Generator, do not modify.
  277. -->
  278. update vm_recharge_rule
  279. <set>
  280. <if test="rechargeAmt != null">
  281. VRR_RECHARGE_AMT = #{rechargeAmt,jdbcType=VARCHAR},
  282. </if>
  283. <if test="giveAmt != null">
  284. VRR_GIVE_AMT = #{giveAmt,jdbcType=VARCHAR},
  285. </if>
  286. <if test="desc != null">
  287. VRR_DESC = #{desc,jdbcType=VARCHAR},
  288. </if>
  289. <if test="createTime != null">
  290. VRR_CREATE_TIME = #{createTime,jdbcType=VARCHAR},
  291. </if>
  292. <if test="createUser != null">
  293. VRR_CREATE_USER = #{createUser,jdbcType=VARCHAR},
  294. </if>
  295. <if test="state != null">
  296. VRR_STATE = #{state,jdbcType=VARCHAR},
  297. </if>
  298. <if test="branch != null">
  299. VRR_BRANCH = #{branch,jdbcType=VARCHAR},
  300. </if>
  301. </set>
  302. where VRR_ID = #{id,jdbcType=VARCHAR}
  303. </update>
  304. <update id="updateByPrimaryKey" parameterType="com.minpay.db.table.model.VmRechargeRule">
  305. <!--
  306. WARNING - @mbggenerated
  307. This element is automatically generated by MyBatis Generator, do not modify.
  308. -->
  309. update vm_recharge_rule
  310. set VRR_RECHARGE_AMT = #{rechargeAmt,jdbcType=VARCHAR},
  311. VRR_GIVE_AMT = #{giveAmt,jdbcType=VARCHAR},
  312. VRR_DESC = #{desc,jdbcType=VARCHAR},
  313. VRR_CREATE_TIME = #{createTime,jdbcType=VARCHAR},
  314. VRR_CREATE_USER = #{createUser,jdbcType=VARCHAR},
  315. VRR_STATE = #{state,jdbcType=VARCHAR},
  316. VRR_BRANCH = #{branch,jdbcType=VARCHAR}
  317. where VRR_ID = #{id,jdbcType=VARCHAR}
  318. </update>
  319. </mapper>