TRepayMapper.xml 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354
  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.mvc.dao.TRepayMapper">
  4. <resultMap id="BaseResultMap" type="com.mvc.entity.TRepay">
  5. <id column="id" jdbcType="INTEGER" property="id" />
  6. <result column="BILL_CODE" jdbcType="VARCHAR" property="billCode" />
  7. <result column="DAY_BILLY_INDEX" jdbcType="INTEGER" property="dayBillyIndex" />
  8. <result column="REPAY_TIME" jdbcType="TIMESTAMP" property="repayTime" />
  9. <result column="REPAY_MAN" jdbcType="VARCHAR" property="repayMan" />
  10. <result column="REPAY_SIGN_IMG" jdbcType="VARCHAR" property="repaySignImg" />
  11. <result column="RETURN_MAN" jdbcType="VARCHAR" property="returnMan" />
  12. <result column="RETURN_INFO" jdbcType="VARCHAR" property="returnInfo" />
  13. <result column="RETURN_IMG_URL" jdbcType="VARCHAR" property="returnImgUrl" />
  14. <result column="REPAY_MEMO" jdbcType="VARCHAR" property="repayMemo" />
  15. <result column="INVAILD_FLAG" jdbcType="CHAR" property="invaildFlag" />
  16. <result column="INVALID_TIME" jdbcType="TIMESTAMP" property="invalidTime" />
  17. <result column="INVALID_MAN" jdbcType="VARCHAR" property="invalidMan" />
  18. <result column="INVALID_BECAUSE" jdbcType="VARCHAR" property="invalidBecause" />
  19. </resultMap>
  20. <sql id="Example_Where_Clause">
  21. <where>
  22. <foreach collection="oredCriteria" item="criteria" separator="or">
  23. <if test="criteria.valid">
  24. <trim prefix="(" prefixOverrides="and" suffix=")">
  25. <foreach collection="criteria.criteria" item="criterion">
  26. <choose>
  27. <when test="criterion.noValue">
  28. and ${criterion.condition}
  29. </when>
  30. <when test="criterion.singleValue">
  31. and ${criterion.condition} #{criterion.value}
  32. </when>
  33. <when test="criterion.betweenValue">
  34. and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
  35. </when>
  36. <when test="criterion.listValue">
  37. and ${criterion.condition}
  38. <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
  39. #{listItem}
  40. </foreach>
  41. </when>
  42. </choose>
  43. </foreach>
  44. </trim>
  45. </if>
  46. </foreach>
  47. </where>
  48. </sql>
  49. <sql id="Update_By_Example_Where_Clause">
  50. <where>
  51. <foreach collection="example.oredCriteria" item="criteria" separator="or">
  52. <if test="criteria.valid">
  53. <trim prefix="(" prefixOverrides="and" suffix=")">
  54. <foreach collection="criteria.criteria" item="criterion">
  55. <choose>
  56. <when test="criterion.noValue">
  57. and ${criterion.condition}
  58. </when>
  59. <when test="criterion.singleValue">
  60. and ${criterion.condition} #{criterion.value}
  61. </when>
  62. <when test="criterion.betweenValue">
  63. and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
  64. </when>
  65. <when test="criterion.listValue">
  66. and ${criterion.condition}
  67. <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
  68. #{listItem}
  69. </foreach>
  70. </when>
  71. </choose>
  72. </foreach>
  73. </trim>
  74. </if>
  75. </foreach>
  76. </where>
  77. </sql>
  78. <sql id="Base_Column_List">
  79. id, BILL_CODE, DAY_BILLY_INDEX, REPAY_TIME, REPAY_MAN, REPAY_SIGN_IMG, RETURN_MAN,
  80. RETURN_INFO, RETURN_IMG_URL, REPAY_MEMO, INVAILD_FLAG, INVALID_TIME, INVALID_MAN,
  81. INVALID_BECAUSE
  82. </sql>
  83. <select id="selectByExample" parameterType="com.mvc.entity.TRepayExample" resultMap="BaseResultMap">
  84. select
  85. <if test="distinct">
  86. distinct
  87. </if>
  88. <include refid="Base_Column_List" />
  89. from t_repay
  90. <if test="_parameter != null">
  91. <include refid="Example_Where_Clause" />
  92. </if>
  93. <if test="orderByClause != null">
  94. order by ${orderByClause}
  95. </if>
  96. </select>
  97. <select id="selectByPrimaryKey" parameterType="java.lang.Integer" resultMap="BaseResultMap">
  98. select
  99. <include refid="Base_Column_List" />
  100. from t_repay
  101. where id = #{id,jdbcType=INTEGER}
  102. </select>
  103. <delete id="deleteByPrimaryKey" parameterType="java.lang.Integer">
  104. delete from t_repay
  105. where id = #{id,jdbcType=INTEGER}
  106. </delete>
  107. <delete id="deleteByExample" parameterType="com.mvc.entity.TRepayExample">
  108. delete from t_repay
  109. <if test="_parameter != null">
  110. <include refid="Example_Where_Clause" />
  111. </if>
  112. </delete>
  113. <insert id="insert" parameterType="com.mvc.entity.TRepay">
  114. insert into t_repay (id, BILL_CODE, DAY_BILLY_INDEX,
  115. REPAY_TIME, REPAY_MAN, REPAY_SIGN_IMG,
  116. RETURN_MAN, RETURN_INFO, RETURN_IMG_URL,
  117. REPAY_MEMO, INVAILD_FLAG, INVALID_TIME,
  118. INVALID_MAN, INVALID_BECAUSE)
  119. values (#{id,jdbcType=INTEGER}, #{billCode,jdbcType=VARCHAR}, #{dayBillyIndex,jdbcType=INTEGER},
  120. #{repayTime,jdbcType=TIMESTAMP}, #{repayMan,jdbcType=VARCHAR}, #{repaySignImg,jdbcType=VARCHAR},
  121. #{returnMan,jdbcType=VARCHAR}, #{returnInfo,jdbcType=VARCHAR}, #{returnImgUrl,jdbcType=VARCHAR},
  122. #{repayMemo,jdbcType=VARCHAR}, #{invaildFlag,jdbcType=CHAR}, #{invalidTime,jdbcType=TIMESTAMP},
  123. #{invalidMan,jdbcType=VARCHAR}, #{invalidBecause,jdbcType=VARCHAR})
  124. </insert>
  125. <insert id="insertSelective" parameterType="com.mvc.entity.TRepay">
  126. insert into t_repay
  127. <trim prefix="(" suffix=")" suffixOverrides=",">
  128. <if test="id != null">
  129. id,
  130. </if>
  131. <if test="billCode != null">
  132. BILL_CODE,
  133. </if>
  134. <if test="dayBillyIndex != null">
  135. DAY_BILLY_INDEX,
  136. </if>
  137. <if test="repayTime != null">
  138. REPAY_TIME,
  139. </if>
  140. <if test="repayMan != null">
  141. REPAY_MAN,
  142. </if>
  143. <if test="repaySignImg != null">
  144. REPAY_SIGN_IMG,
  145. </if>
  146. <if test="returnMan != null">
  147. RETURN_MAN,
  148. </if>
  149. <if test="returnInfo != null">
  150. RETURN_INFO,
  151. </if>
  152. <if test="returnImgUrl != null">
  153. RETURN_IMG_URL,
  154. </if>
  155. <if test="repayMemo != null">
  156. REPAY_MEMO,
  157. </if>
  158. <if test="invaildFlag != null">
  159. INVAILD_FLAG,
  160. </if>
  161. <if test="invalidTime != null">
  162. INVALID_TIME,
  163. </if>
  164. <if test="invalidMan != null">
  165. INVALID_MAN,
  166. </if>
  167. <if test="invalidBecause != null">
  168. INVALID_BECAUSE,
  169. </if>
  170. </trim>
  171. <trim prefix="values (" suffix=")" suffixOverrides=",">
  172. <if test="id != null">
  173. #{id,jdbcType=INTEGER},
  174. </if>
  175. <if test="billCode != null">
  176. #{billCode,jdbcType=VARCHAR},
  177. </if>
  178. <if test="dayBillyIndex != null">
  179. #{dayBillyIndex,jdbcType=INTEGER},
  180. </if>
  181. <if test="repayTime != null">
  182. #{repayTime,jdbcType=TIMESTAMP},
  183. </if>
  184. <if test="repayMan != null">
  185. #{repayMan,jdbcType=VARCHAR},
  186. </if>
  187. <if test="repaySignImg != null">
  188. #{repaySignImg,jdbcType=VARCHAR},
  189. </if>
  190. <if test="returnMan != null">
  191. #{returnMan,jdbcType=VARCHAR},
  192. </if>
  193. <if test="returnInfo != null">
  194. #{returnInfo,jdbcType=VARCHAR},
  195. </if>
  196. <if test="returnImgUrl != null">
  197. #{returnImgUrl,jdbcType=VARCHAR},
  198. </if>
  199. <if test="repayMemo != null">
  200. #{repayMemo,jdbcType=VARCHAR},
  201. </if>
  202. <if test="invaildFlag != null">
  203. #{invaildFlag,jdbcType=CHAR},
  204. </if>
  205. <if test="invalidTime != null">
  206. #{invalidTime,jdbcType=TIMESTAMP},
  207. </if>
  208. <if test="invalidMan != null">
  209. #{invalidMan,jdbcType=VARCHAR},
  210. </if>
  211. <if test="invalidBecause != null">
  212. #{invalidBecause,jdbcType=VARCHAR},
  213. </if>
  214. </trim>
  215. </insert>
  216. <select id="countByExample" parameterType="com.mvc.entity.TRepayExample" resultType="java.lang.Long">
  217. select count(*) from t_repay
  218. <if test="_parameter != null">
  219. <include refid="Example_Where_Clause" />
  220. </if>
  221. </select>
  222. <update id="updateByExampleSelective" parameterType="map">
  223. update t_repay
  224. <set>
  225. <if test="record.id != null">
  226. id = #{record.id,jdbcType=INTEGER},
  227. </if>
  228. <if test="record.billCode != null">
  229. BILL_CODE = #{record.billCode,jdbcType=VARCHAR},
  230. </if>
  231. <if test="record.dayBillyIndex != null">
  232. DAY_BILLY_INDEX = #{record.dayBillyIndex,jdbcType=INTEGER},
  233. </if>
  234. <if test="record.repayTime != null">
  235. REPAY_TIME = #{record.repayTime,jdbcType=TIMESTAMP},
  236. </if>
  237. <if test="record.repayMan != null">
  238. REPAY_MAN = #{record.repayMan,jdbcType=VARCHAR},
  239. </if>
  240. <if test="record.repaySignImg != null">
  241. REPAY_SIGN_IMG = #{record.repaySignImg,jdbcType=VARCHAR},
  242. </if>
  243. <if test="record.returnMan != null">
  244. RETURN_MAN = #{record.returnMan,jdbcType=VARCHAR},
  245. </if>
  246. <if test="record.returnInfo != null">
  247. RETURN_INFO = #{record.returnInfo,jdbcType=VARCHAR},
  248. </if>
  249. <if test="record.returnImgUrl != null">
  250. RETURN_IMG_URL = #{record.returnImgUrl,jdbcType=VARCHAR},
  251. </if>
  252. <if test="record.repayMemo != null">
  253. REPAY_MEMO = #{record.repayMemo,jdbcType=VARCHAR},
  254. </if>
  255. <if test="record.invaildFlag != null">
  256. INVAILD_FLAG = #{record.invaildFlag,jdbcType=CHAR},
  257. </if>
  258. <if test="record.invalidTime != null">
  259. INVALID_TIME = #{record.invalidTime,jdbcType=TIMESTAMP},
  260. </if>
  261. <if test="record.invalidMan != null">
  262. INVALID_MAN = #{record.invalidMan,jdbcType=VARCHAR},
  263. </if>
  264. <if test="record.invalidBecause != null">
  265. INVALID_BECAUSE = #{record.invalidBecause,jdbcType=VARCHAR},
  266. </if>
  267. </set>
  268. <if test="_parameter != null">
  269. <include refid="Update_By_Example_Where_Clause" />
  270. </if>
  271. </update>
  272. <update id="updateByExample" parameterType="map">
  273. update t_repay
  274. set id = #{record.id,jdbcType=INTEGER},
  275. BILL_CODE = #{record.billCode,jdbcType=VARCHAR},
  276. DAY_BILLY_INDEX = #{record.dayBillyIndex,jdbcType=INTEGER},
  277. REPAY_TIME = #{record.repayTime,jdbcType=TIMESTAMP},
  278. REPAY_MAN = #{record.repayMan,jdbcType=VARCHAR},
  279. REPAY_SIGN_IMG = #{record.repaySignImg,jdbcType=VARCHAR},
  280. RETURN_MAN = #{record.returnMan,jdbcType=VARCHAR},
  281. RETURN_INFO = #{record.returnInfo,jdbcType=VARCHAR},
  282. RETURN_IMG_URL = #{record.returnImgUrl,jdbcType=VARCHAR},
  283. REPAY_MEMO = #{record.repayMemo,jdbcType=VARCHAR},
  284. INVAILD_FLAG = #{record.invaildFlag,jdbcType=CHAR},
  285. INVALID_TIME = #{record.invalidTime,jdbcType=TIMESTAMP},
  286. INVALID_MAN = #{record.invalidMan,jdbcType=VARCHAR},
  287. INVALID_BECAUSE = #{record.invalidBecause,jdbcType=VARCHAR}
  288. <if test="_parameter != null">
  289. <include refid="Update_By_Example_Where_Clause" />
  290. </if>
  291. </update>
  292. <update id="updateByPrimaryKeySelective" parameterType="com.mvc.entity.TRepay">
  293. update t_repay
  294. <set>
  295. <if test="billCode != null">
  296. BILL_CODE = #{billCode,jdbcType=VARCHAR},
  297. </if>
  298. <if test="dayBillyIndex != null">
  299. DAY_BILLY_INDEX = #{dayBillyIndex,jdbcType=INTEGER},
  300. </if>
  301. <if test="repayTime != null">
  302. REPAY_TIME = #{repayTime,jdbcType=TIMESTAMP},
  303. </if>
  304. <if test="repayMan != null">
  305. REPAY_MAN = #{repayMan,jdbcType=VARCHAR},
  306. </if>
  307. <if test="repaySignImg != null">
  308. REPAY_SIGN_IMG = #{repaySignImg,jdbcType=VARCHAR},
  309. </if>
  310. <if test="returnMan != null">
  311. RETURN_MAN = #{returnMan,jdbcType=VARCHAR},
  312. </if>
  313. <if test="returnInfo != null">
  314. RETURN_INFO = #{returnInfo,jdbcType=VARCHAR},
  315. </if>
  316. <if test="returnImgUrl != null">
  317. RETURN_IMG_URL = #{returnImgUrl,jdbcType=VARCHAR},
  318. </if>
  319. <if test="repayMemo != null">
  320. REPAY_MEMO = #{repayMemo,jdbcType=VARCHAR},
  321. </if>
  322. <if test="invaildFlag != null">
  323. INVAILD_FLAG = #{invaildFlag,jdbcType=CHAR},
  324. </if>
  325. <if test="invalidTime != null">
  326. INVALID_TIME = #{invalidTime,jdbcType=TIMESTAMP},
  327. </if>
  328. <if test="invalidMan != null">
  329. INVALID_MAN = #{invalidMan,jdbcType=VARCHAR},
  330. </if>
  331. <if test="invalidBecause != null">
  332. INVALID_BECAUSE = #{invalidBecause,jdbcType=VARCHAR},
  333. </if>
  334. </set>
  335. where id = #{id,jdbcType=INTEGER}
  336. </update>
  337. <update id="updateByPrimaryKey" parameterType="com.mvc.entity.TRepay">
  338. update t_repay
  339. set BILL_CODE = #{billCode,jdbcType=VARCHAR},
  340. DAY_BILLY_INDEX = #{dayBillyIndex,jdbcType=INTEGER},
  341. REPAY_TIME = #{repayTime,jdbcType=TIMESTAMP},
  342. REPAY_MAN = #{repayMan,jdbcType=VARCHAR},
  343. REPAY_SIGN_IMG = #{repaySignImg,jdbcType=VARCHAR},
  344. RETURN_MAN = #{returnMan,jdbcType=VARCHAR},
  345. RETURN_INFO = #{returnInfo,jdbcType=VARCHAR},
  346. RETURN_IMG_URL = #{returnImgUrl,jdbcType=VARCHAR},
  347. REPAY_MEMO = #{repayMemo,jdbcType=VARCHAR},
  348. INVAILD_FLAG = #{invaildFlag,jdbcType=CHAR},
  349. INVALID_TIME = #{invalidTime,jdbcType=TIMESTAMP},
  350. INVALID_MAN = #{invalidMan,jdbcType=VARCHAR},
  351. INVALID_BECAUSE = #{invalidBecause,jdbcType=VARCHAR}
  352. where id = #{id,jdbcType=INTEGER}
  353. </update>
  354. </mapper>