VparkOrderMapper.xml 13 KB

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