ImUserPermissionMapper.xml 9.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256
  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.ImUserPermissionMapper" >
  4. <resultMap id="BaseResultMap" type="com.minpay.db.table.model.ImUserPermission" >
  5. <!--
  6. WARNING - @mbggenerated
  7. This element is automatically generated by MyBatis Generator, do not modify.
  8. -->
  9. <id column="UPMS_CHRNO" property="chrno" jdbcType="CHAR" />
  10. <id column="UPMS_NO" property="no" jdbcType="CHAR" />
  11. <id column="UPMS_USERNO" property="userno" jdbcType="CHAR" />
  12. <result column="UPMS_DATETIME" property="datetime" jdbcType="CHAR" />
  13. </resultMap>
  14. <sql id="Example_Where_Clause" >
  15. <!--
  16. WARNING - @mbggenerated
  17. This element is automatically generated by MyBatis Generator, do not modify.
  18. -->
  19. <where >
  20. <foreach collection="oredCriteria" item="criteria" separator="or" >
  21. <if test="criteria.valid" >
  22. <trim prefix="(" suffix=")" prefixOverrides="and" >
  23. <foreach collection="criteria.criteria" item="criterion" >
  24. <choose >
  25. <when test="criterion.noValue" >
  26. and ${criterion.condition}
  27. </when>
  28. <when test="criterion.singleValue" >
  29. and ${criterion.condition} #{criterion.value}
  30. </when>
  31. <when test="criterion.betweenValue" >
  32. and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
  33. </when>
  34. <when test="criterion.listValue" >
  35. and ${criterion.condition}
  36. <foreach collection="criterion.value" item="listItem" open="(" close=")" separator="," >
  37. #{listItem}
  38. </foreach>
  39. </when>
  40. </choose>
  41. </foreach>
  42. </trim>
  43. </if>
  44. </foreach>
  45. </where>
  46. </sql>
  47. <sql id="Update_By_Example_Where_Clause" >
  48. <!--
  49. WARNING - @mbggenerated
  50. This element is automatically generated by MyBatis Generator, do not modify.
  51. -->
  52. <where >
  53. <foreach collection="example.oredCriteria" item="criteria" separator="or" >
  54. <if test="criteria.valid" >
  55. <trim prefix="(" suffix=")" prefixOverrides="and" >
  56. <foreach collection="criteria.criteria" item="criterion" >
  57. <choose >
  58. <when test="criterion.noValue" >
  59. and ${criterion.condition}
  60. </when>
  61. <when test="criterion.singleValue" >
  62. and ${criterion.condition} #{criterion.value}
  63. </when>
  64. <when test="criterion.betweenValue" >
  65. and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
  66. </when>
  67. <when test="criterion.listValue" >
  68. and ${criterion.condition}
  69. <foreach collection="criterion.value" item="listItem" open="(" close=")" separator="," >
  70. #{listItem}
  71. </foreach>
  72. </when>
  73. </choose>
  74. </foreach>
  75. </trim>
  76. </if>
  77. </foreach>
  78. </where>
  79. </sql>
  80. <sql id="Base_Column_List" >
  81. <!--
  82. WARNING - @mbggenerated
  83. This element is automatically generated by MyBatis Generator, do not modify.
  84. -->
  85. UPMS_CHRNO, UPMS_NO, UPMS_USERNO, UPMS_DATETIME
  86. </sql>
  87. <select id="selectByExample" resultMap="BaseResultMap" parameterType="com.minpay.db.table.model.ImUserPermissionExample" >
  88. <!--
  89. WARNING - @mbggenerated
  90. This element is automatically generated by MyBatis Generator, do not modify.
  91. -->
  92. select
  93. <if test="distinct" >
  94. distinct
  95. </if>
  96. <include refid="Base_Column_List" />
  97. from im_user_permission
  98. <if test="_parameter != null" >
  99. <include refid="Example_Where_Clause" />
  100. </if>
  101. <if test="orderByClause != null" >
  102. order by ${orderByClause}
  103. </if>
  104. </select>
  105. <select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="com.minpay.db.table.model.ImUserPermissionKey" >
  106. <!--
  107. WARNING - @mbggenerated
  108. This element is automatically generated by MyBatis Generator, do not modify.
  109. -->
  110. select
  111. <include refid="Base_Column_List" />
  112. from im_user_permission
  113. where UPMS_CHRNO = #{chrno,jdbcType=CHAR}
  114. and UPMS_NO = #{no,jdbcType=CHAR}
  115. and UPMS_USERNO = #{userno,jdbcType=CHAR}
  116. </select>
  117. <delete id="deleteByPrimaryKey" parameterType="com.minpay.db.table.model.ImUserPermissionKey" >
  118. <!--
  119. WARNING - @mbggenerated
  120. This element is automatically generated by MyBatis Generator, do not modify.
  121. -->
  122. delete from im_user_permission
  123. where UPMS_CHRNO = #{chrno,jdbcType=CHAR}
  124. and UPMS_NO = #{no,jdbcType=CHAR}
  125. and UPMS_USERNO = #{userno,jdbcType=CHAR}
  126. </delete>
  127. <delete id="deleteByExample" parameterType="com.minpay.db.table.model.ImUserPermissionExample" >
  128. <!--
  129. WARNING - @mbggenerated
  130. This element is automatically generated by MyBatis Generator, do not modify.
  131. -->
  132. delete from im_user_permission
  133. <if test="_parameter != null" >
  134. <include refid="Example_Where_Clause" />
  135. </if>
  136. </delete>
  137. <insert id="insert" parameterType="com.minpay.db.table.model.ImUserPermission" >
  138. <!--
  139. WARNING - @mbggenerated
  140. This element is automatically generated by MyBatis Generator, do not modify.
  141. -->
  142. insert into im_user_permission (UPMS_CHRNO, UPMS_NO, UPMS_USERNO, UPMS_DATETIME
  143. )
  144. values (#{chrno,jdbcType=CHAR}, #{no,jdbcType=CHAR}, #{userno,jdbcType=CHAR}, #{datetime,jdbcType=CHAR}
  145. )
  146. </insert>
  147. <insert id="insertSelective" parameterType="com.minpay.db.table.model.ImUserPermission" >
  148. <!--
  149. WARNING - @mbggenerated
  150. This element is automatically generated by MyBatis Generator, do not modify.
  151. -->
  152. insert into im_user_permission
  153. <trim prefix="(" suffix=")" suffixOverrides="," >
  154. <if test="chrno != null" >
  155. UPMS_CHRNO,
  156. </if>
  157. <if test="no != null" >
  158. UPMS_NO,
  159. </if>
  160. <if test="userno != null" >
  161. UPMS_USERNO,
  162. </if>
  163. <if test="datetime != null" >
  164. UPMS_DATETIME,
  165. </if>
  166. </trim>
  167. <trim prefix="values (" suffix=")" suffixOverrides="," >
  168. <if test="chrno != null" >
  169. #{chrno,jdbcType=CHAR},
  170. </if>
  171. <if test="no != null" >
  172. #{no,jdbcType=CHAR},
  173. </if>
  174. <if test="userno != null" >
  175. #{userno,jdbcType=CHAR},
  176. </if>
  177. <if test="datetime != null" >
  178. #{datetime,jdbcType=CHAR},
  179. </if>
  180. </trim>
  181. </insert>
  182. <select id="countByExample" parameterType="com.minpay.db.table.model.ImUserPermissionExample" resultType="java.lang.Integer" >
  183. <!--
  184. WARNING - @mbggenerated
  185. This element is automatically generated by MyBatis Generator, do not modify.
  186. -->
  187. select count(*) from im_user_permission
  188. <if test="_parameter != null" >
  189. <include refid="Example_Where_Clause" />
  190. </if>
  191. </select>
  192. <update id="updateByExampleSelective" parameterType="map" >
  193. <!--
  194. WARNING - @mbggenerated
  195. This element is automatically generated by MyBatis Generator, do not modify.
  196. -->
  197. update im_user_permission
  198. <set >
  199. <if test="record.chrno != null" >
  200. UPMS_CHRNO = #{record.chrno,jdbcType=CHAR},
  201. </if>
  202. <if test="record.no != null" >
  203. UPMS_NO = #{record.no,jdbcType=CHAR},
  204. </if>
  205. <if test="record.userno != null" >
  206. UPMS_USERNO = #{record.userno,jdbcType=CHAR},
  207. </if>
  208. <if test="record.datetime != null" >
  209. UPMS_DATETIME = #{record.datetime,jdbcType=CHAR},
  210. </if>
  211. </set>
  212. <if test="_parameter != null" >
  213. <include refid="Update_By_Example_Where_Clause" />
  214. </if>
  215. </update>
  216. <update id="updateByExample" parameterType="map" >
  217. <!--
  218. WARNING - @mbggenerated
  219. This element is automatically generated by MyBatis Generator, do not modify.
  220. -->
  221. update im_user_permission
  222. set UPMS_CHRNO = #{record.chrno,jdbcType=CHAR},
  223. UPMS_NO = #{record.no,jdbcType=CHAR},
  224. UPMS_USERNO = #{record.userno,jdbcType=CHAR},
  225. UPMS_DATETIME = #{record.datetime,jdbcType=CHAR}
  226. <if test="_parameter != null" >
  227. <include refid="Update_By_Example_Where_Clause" />
  228. </if>
  229. </update>
  230. <update id="updateByPrimaryKeySelective" parameterType="com.minpay.db.table.model.ImUserPermission" >
  231. <!--
  232. WARNING - @mbggenerated
  233. This element is automatically generated by MyBatis Generator, do not modify.
  234. -->
  235. update im_user_permission
  236. <set >
  237. <if test="datetime != null" >
  238. UPMS_DATETIME = #{datetime,jdbcType=CHAR},
  239. </if>
  240. </set>
  241. where UPMS_CHRNO = #{chrno,jdbcType=CHAR}
  242. and UPMS_NO = #{no,jdbcType=CHAR}
  243. and UPMS_USERNO = #{userno,jdbcType=CHAR}
  244. </update>
  245. <update id="updateByPrimaryKey" parameterType="com.minpay.db.table.model.ImUserPermission" >
  246. <!--
  247. WARNING - @mbggenerated
  248. This element is automatically generated by MyBatis Generator, do not modify.
  249. -->
  250. update im_user_permission
  251. set UPMS_DATETIME = #{datetime,jdbcType=CHAR}
  252. where UPMS_CHRNO = #{chrno,jdbcType=CHAR}
  253. and UPMS_NO = #{no,jdbcType=CHAR}
  254. and UPMS_USERNO = #{userno,jdbcType=CHAR}
  255. </update>
  256. </mapper>