OmsOrderMapper.xml 34 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858
  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.yonge.cooleshow.mbg.mapper.OmsOrderMapper">
  4. <resultMap id="BaseResultMap" type="com.yonge.cooleshow.mbg.model.OmsOrder">
  5. <id column="id" jdbcType="BIGINT" property="id" />
  6. <result column="member_id" jdbcType="BIGINT" property="memberId" />
  7. <result column="coupon_id" jdbcType="BIGINT" property="couponId" />
  8. <result column="order_sn" jdbcType="VARCHAR" property="orderSn" />
  9. <result column="cart_ids" jdbcType="VARCHAR" property="cartIds" />
  10. <result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
  11. <result column="member_username" jdbcType="VARCHAR" property="memberUsername" />
  12. <result column="total_amount" jdbcType="DECIMAL" property="totalAmount" />
  13. <result column="pay_amount" jdbcType="DECIMAL" property="payAmount" />
  14. <result column="freight_amount" jdbcType="DECIMAL" property="freightAmount" />
  15. <result column="promotion_amount" jdbcType="DECIMAL" property="promotionAmount" />
  16. <result column="integration_amount" jdbcType="DECIMAL" property="integrationAmount" />
  17. <result column="coupon_amount" jdbcType="DECIMAL" property="couponAmount" />
  18. <result column="discount_amount" jdbcType="DECIMAL" property="discountAmount" />
  19. <result column="pay_type" jdbcType="INTEGER" property="payType" />
  20. <result column="source_type" jdbcType="INTEGER" property="sourceType" />
  21. <result column="status" jdbcType="INTEGER" property="status" />
  22. <result column="order_type" jdbcType="INTEGER" property="orderType" />
  23. <result column="delivery_company" jdbcType="VARCHAR" property="deliveryCompany" />
  24. <result column="delivery_sn" jdbcType="VARCHAR" property="deliverySn" />
  25. <result column="auto_confirm_day" jdbcType="INTEGER" property="autoConfirmDay" />
  26. <result column="integration" jdbcType="INTEGER" property="integration" />
  27. <result column="growth" jdbcType="INTEGER" property="growth" />
  28. <result column="promotion_info" jdbcType="VARCHAR" property="promotionInfo" />
  29. <result column="bill_type" jdbcType="INTEGER" property="billType" />
  30. <result column="bill_header" jdbcType="VARCHAR" property="billHeader" />
  31. <result column="bill_content" jdbcType="VARCHAR" property="billContent" />
  32. <result column="bill_receiver_phone" jdbcType="VARCHAR" property="billReceiverPhone" />
  33. <result column="bill_receiver_email" jdbcType="VARCHAR" property="billReceiverEmail" />
  34. <result column="receiver_name" jdbcType="VARCHAR" property="receiverName" />
  35. <result column="receiver_phone" jdbcType="VARCHAR" property="receiverPhone" />
  36. <result column="receiver_post_code" jdbcType="VARCHAR" property="receiverPostCode" />
  37. <result column="receiver_province" jdbcType="VARCHAR" property="receiverProvince" />
  38. <result column="receiver_city" jdbcType="VARCHAR" property="receiverCity" />
  39. <result column="receiver_region" jdbcType="VARCHAR" property="receiverRegion" />
  40. <result column="receiver_detail_address" jdbcType="VARCHAR" property="receiverDetailAddress" />
  41. <result column="note" jdbcType="VARCHAR" property="note" />
  42. <result column="confirm_status" jdbcType="INTEGER" property="confirmStatus" />
  43. <result column="delete_status" jdbcType="INTEGER" property="deleteStatus" />
  44. <result column="use_integration" jdbcType="INTEGER" property="useIntegration" />
  45. <result column="payment_time" jdbcType="TIMESTAMP" property="paymentTime" />
  46. <result column="delivery_time" jdbcType="TIMESTAMP" property="deliveryTime" />
  47. <result column="receive_time" jdbcType="TIMESTAMP" property="receiveTime" />
  48. <result column="comment_time" jdbcType="TIMESTAMP" property="commentTime" />
  49. <result column="modify_time" jdbcType="TIMESTAMP" property="modifyTime" />
  50. <result column="platform_type" jdbcType="TIMESTAMP" property="platformType" />
  51. </resultMap>
  52. <sql id="Example_Where_Clause">
  53. <where>
  54. <foreach collection="oredCriteria" item="criteria" separator="or">
  55. <if test="criteria.valid">
  56. <trim prefix="(" prefixOverrides="and" suffix=")">
  57. <foreach collection="criteria.criteria" item="criterion">
  58. <choose>
  59. <when test="criterion.noValue">
  60. and ${criterion.condition}
  61. </when>
  62. <when test="criterion.singleValue">
  63. and ${criterion.condition} #{criterion.value}
  64. </when>
  65. <when test="criterion.betweenValue">
  66. and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
  67. </when>
  68. <when test="criterion.listValue">
  69. and ${criterion.condition}
  70. <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
  71. #{listItem}
  72. </foreach>
  73. </when>
  74. </choose>
  75. </foreach>
  76. </trim>
  77. </if>
  78. </foreach>
  79. </where>
  80. </sql>
  81. <sql id="Update_By_Example_Where_Clause">
  82. <where>
  83. <foreach collection="example.oredCriteria" item="criteria" separator="or">
  84. <if test="criteria.valid">
  85. <trim prefix="(" prefixOverrides="and" suffix=")">
  86. <foreach collection="criteria.criteria" item="criterion">
  87. <choose>
  88. <when test="criterion.noValue">
  89. and ${criterion.condition}
  90. </when>
  91. <when test="criterion.singleValue">
  92. and ${criterion.condition} #{criterion.value}
  93. </when>
  94. <when test="criterion.betweenValue">
  95. and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
  96. </when>
  97. <when test="criterion.listValue">
  98. and ${criterion.condition}
  99. <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
  100. #{listItem}
  101. </foreach>
  102. </when>
  103. </choose>
  104. </foreach>
  105. </trim>
  106. </if>
  107. </foreach>
  108. </where>
  109. </sql>
  110. <sql id="Base_Column_List">
  111. id, member_id, coupon_id, order_sn, create_time, member_username, total_amount, pay_amount,
  112. freight_amount, promotion_amount, integration_amount, coupon_amount, discount_amount,
  113. pay_type, source_type, status, order_type, delivery_company, delivery_sn, auto_confirm_day,
  114. integration, growth, promotion_info, bill_type, bill_header, bill_content, bill_receiver_phone,
  115. bill_receiver_email, receiver_name, receiver_phone, receiver_post_code, receiver_province,
  116. receiver_city, receiver_region, receiver_detail_address, note, confirm_status, delete_status,
  117. use_integration, payment_time, delivery_time, receive_time, comment_time, modify_time,cart_ids,platform_type
  118. </sql>
  119. <select id="selectByExample" parameterType="com.yonge.cooleshow.mbg.model.OmsOrderExample" resultMap="BaseResultMap">
  120. select
  121. <if test="distinct">
  122. distinct
  123. </if>
  124. <include refid="Base_Column_List" />
  125. from oms_order
  126. <if test="_parameter != null">
  127. <include refid="Example_Where_Clause" />
  128. </if>
  129. <if test="orderByClause != null">
  130. order by ${orderByClause}
  131. </if>
  132. </select>
  133. <select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
  134. select
  135. <include refid="Base_Column_List" />
  136. from oms_order
  137. where id = #{id,jdbcType=BIGINT}
  138. </select>
  139. <delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
  140. delete from oms_order
  141. where id = #{id,jdbcType=BIGINT}
  142. </delete>
  143. <delete id="deleteByExample" parameterType="com.yonge.cooleshow.mbg.model.OmsOrderExample">
  144. delete from oms_order
  145. <if test="_parameter != null">
  146. <include refid="Example_Where_Clause" />
  147. </if>
  148. </delete>
  149. <insert id="insert" parameterType="com.yonge.cooleshow.mbg.model.OmsOrder">
  150. <selectKey keyProperty="id" order="AFTER" resultType="java.lang.Long">
  151. SELECT LAST_INSERT_ID()
  152. </selectKey>
  153. insert into oms_order (member_id, coupon_id, order_sn,
  154. create_time, member_username, total_amount,
  155. pay_amount, freight_amount, promotion_amount,
  156. integration_amount, coupon_amount, discount_amount,
  157. pay_type, source_type, status,
  158. order_type, delivery_company, delivery_sn,
  159. auto_confirm_day, integration, growth,
  160. promotion_info, bill_type, bill_header,
  161. bill_content, bill_receiver_phone, bill_receiver_email,
  162. receiver_name, receiver_phone, receiver_post_code,
  163. receiver_province, receiver_city, receiver_region,
  164. receiver_detail_address, note, confirm_status,
  165. delete_status, use_integration, payment_time,
  166. delivery_time, receive_time, comment_time,
  167. modify_time,cart_ids,platform_type)
  168. values (#{memberId,jdbcType=BIGINT}, #{couponId,jdbcType=BIGINT}, #{orderSn,jdbcType=VARCHAR},
  169. #{createTime,jdbcType=TIMESTAMP}, #{memberUsername,jdbcType=VARCHAR}, #{totalAmount,jdbcType=DECIMAL},
  170. #{payAmount,jdbcType=DECIMAL}, #{freightAmount,jdbcType=DECIMAL}, #{promotionAmount,jdbcType=DECIMAL},
  171. #{integrationAmount,jdbcType=DECIMAL}, #{couponAmount,jdbcType=DECIMAL}, #{discountAmount,jdbcType=DECIMAL},
  172. #{payType,jdbcType=INTEGER}, #{sourceType,jdbcType=INTEGER}, #{status,jdbcType=INTEGER},
  173. #{orderType,jdbcType=INTEGER}, #{deliveryCompany,jdbcType=VARCHAR}, #{deliverySn,jdbcType=VARCHAR},
  174. #{autoConfirmDay,jdbcType=INTEGER}, #{integration,jdbcType=INTEGER}, #{growth,jdbcType=INTEGER},
  175. #{promotionInfo,jdbcType=VARCHAR}, #{billType,jdbcType=INTEGER}, #{billHeader,jdbcType=VARCHAR},
  176. #{billContent,jdbcType=VARCHAR}, #{billReceiverPhone,jdbcType=VARCHAR}, #{billReceiverEmail,jdbcType=VARCHAR},
  177. #{receiverName,jdbcType=VARCHAR}, #{receiverPhone,jdbcType=VARCHAR}, #{receiverPostCode,jdbcType=VARCHAR},
  178. #{receiverProvince,jdbcType=VARCHAR}, #{receiverCity,jdbcType=VARCHAR}, #{receiverRegion,jdbcType=VARCHAR},
  179. #{receiverDetailAddress,jdbcType=VARCHAR}, #{note,jdbcType=VARCHAR}, #{confirmStatus,jdbcType=INTEGER},
  180. #{deleteStatus,jdbcType=INTEGER}, #{useIntegration,jdbcType=INTEGER}, #{paymentTime,jdbcType=TIMESTAMP},
  181. #{deliveryTime,jdbcType=TIMESTAMP}, #{receiveTime,jdbcType=TIMESTAMP}, #{commentTime,jdbcType=TIMESTAMP},
  182. #{modifyTime,jdbcType=TIMESTAMP},#{cartIds},#{platformType})
  183. </insert>
  184. <insert id="insertSelective" parameterType="com.yonge.cooleshow.mbg.model.OmsOrder">
  185. <selectKey keyProperty="id" order="AFTER" resultType="java.lang.Long">
  186. SELECT LAST_INSERT_ID()
  187. </selectKey>
  188. insert into oms_order
  189. <trim prefix="(" suffix=")" suffixOverrides=",">
  190. <if test="memberId != null">
  191. member_id,
  192. </if>
  193. <if test="couponId != null">
  194. coupon_id,
  195. </if>
  196. <if test="orderSn != null">
  197. order_sn,
  198. </if>
  199. <if test="createTime != null">
  200. create_time,
  201. </if>
  202. <if test="memberUsername != null">
  203. member_username,
  204. </if>
  205. <if test="totalAmount != null">
  206. total_amount,
  207. </if>
  208. <if test="payAmount != null">
  209. pay_amount,
  210. </if>
  211. <if test="freightAmount != null">
  212. freight_amount,
  213. </if>
  214. <if test="promotionAmount != null">
  215. promotion_amount,
  216. </if>
  217. <if test="integrationAmount != null">
  218. integration_amount,
  219. </if>
  220. <if test="couponAmount != null">
  221. coupon_amount,
  222. </if>
  223. <if test="discountAmount != null">
  224. discount_amount,
  225. </if>
  226. <if test="payType != null">
  227. pay_type,
  228. </if>
  229. <if test="sourceType != null">
  230. source_type,
  231. </if>
  232. <if test="status != null">
  233. status,
  234. </if>
  235. <if test="orderType != null">
  236. order_type,
  237. </if>
  238. <if test="deliveryCompany != null">
  239. delivery_company,
  240. </if>
  241. <if test="deliverySn != null">
  242. delivery_sn,
  243. </if>
  244. <if test="autoConfirmDay != null">
  245. auto_confirm_day,
  246. </if>
  247. <if test="integration != null">
  248. integration,
  249. </if>
  250. <if test="growth != null">
  251. growth,
  252. </if>
  253. <if test="promotionInfo != null">
  254. promotion_info,
  255. </if>
  256. <if test="billType != null">
  257. bill_type,
  258. </if>
  259. <if test="billHeader != null">
  260. bill_header,
  261. </if>
  262. <if test="billContent != null">
  263. bill_content,
  264. </if>
  265. <if test="billReceiverPhone != null">
  266. bill_receiver_phone,
  267. </if>
  268. <if test="billReceiverEmail != null">
  269. bill_receiver_email,
  270. </if>
  271. <if test="receiverName != null">
  272. receiver_name,
  273. </if>
  274. <if test="receiverPhone != null">
  275. receiver_phone,
  276. </if>
  277. <if test="receiverPostCode != null">
  278. receiver_post_code,
  279. </if>
  280. <if test="receiverProvince != null">
  281. receiver_province,
  282. </if>
  283. <if test="receiverCity != null">
  284. receiver_city,
  285. </if>
  286. <if test="receiverRegion != null">
  287. receiver_region,
  288. </if>
  289. <if test="receiverDetailAddress != null">
  290. receiver_detail_address,
  291. </if>
  292. <if test="note != null">
  293. note,
  294. </if>
  295. <if test="confirmStatus != null">
  296. confirm_status,
  297. </if>
  298. <if test="deleteStatus != null">
  299. delete_status,
  300. </if>
  301. <if test="useIntegration != null">
  302. use_integration,
  303. </if>
  304. <if test="paymentTime != null">
  305. payment_time,
  306. </if>
  307. <if test="deliveryTime != null">
  308. delivery_time,
  309. </if>
  310. <if test="receiveTime != null">
  311. receive_time,
  312. </if>
  313. <if test="commentTime != null">
  314. comment_time,
  315. </if>
  316. <if test="modifyTime != null">
  317. modify_time,
  318. </if>
  319. <if test="cartIds != null">
  320. cart_ids,
  321. </if>
  322. <if test="platformType != null">
  323. platform_type,
  324. </if>
  325. </trim>
  326. <trim prefix="values (" suffix=")" suffixOverrides=",">
  327. <if test="memberId != null">
  328. #{memberId,jdbcType=BIGINT},
  329. </if>
  330. <if test="couponId != null">
  331. #{couponId,jdbcType=BIGINT},
  332. </if>
  333. <if test="orderSn != null">
  334. #{orderSn,jdbcType=VARCHAR},
  335. </if>
  336. <if test="createTime != null">
  337. #{createTime,jdbcType=TIMESTAMP},
  338. </if>
  339. <if test="memberUsername != null">
  340. #{memberUsername,jdbcType=VARCHAR},
  341. </if>
  342. <if test="totalAmount != null">
  343. #{totalAmount,jdbcType=DECIMAL},
  344. </if>
  345. <if test="payAmount != null">
  346. #{payAmount,jdbcType=DECIMAL},
  347. </if>
  348. <if test="freightAmount != null">
  349. #{freightAmount,jdbcType=DECIMAL},
  350. </if>
  351. <if test="promotionAmount != null">
  352. #{promotionAmount,jdbcType=DECIMAL},
  353. </if>
  354. <if test="integrationAmount != null">
  355. #{integrationAmount,jdbcType=DECIMAL},
  356. </if>
  357. <if test="couponAmount != null">
  358. #{couponAmount,jdbcType=DECIMAL},
  359. </if>
  360. <if test="discountAmount != null">
  361. #{discountAmount,jdbcType=DECIMAL},
  362. </if>
  363. <if test="payType != null">
  364. #{payType,jdbcType=INTEGER},
  365. </if>
  366. <if test="sourceType != null">
  367. #{sourceType,jdbcType=INTEGER},
  368. </if>
  369. <if test="status != null">
  370. #{status,jdbcType=INTEGER},
  371. </if>
  372. <if test="orderType != null">
  373. #{orderType,jdbcType=INTEGER},
  374. </if>
  375. <if test="deliveryCompany != null">
  376. #{deliveryCompany,jdbcType=VARCHAR},
  377. </if>
  378. <if test="deliverySn != null">
  379. #{deliverySn,jdbcType=VARCHAR},
  380. </if>
  381. <if test="autoConfirmDay != null">
  382. #{autoConfirmDay,jdbcType=INTEGER},
  383. </if>
  384. <if test="integration != null">
  385. #{integration,jdbcType=INTEGER},
  386. </if>
  387. <if test="growth != null">
  388. #{growth,jdbcType=INTEGER},
  389. </if>
  390. <if test="promotionInfo != null">
  391. #{promotionInfo,jdbcType=VARCHAR},
  392. </if>
  393. <if test="billType != null">
  394. #{billType,jdbcType=INTEGER},
  395. </if>
  396. <if test="billHeader != null">
  397. #{billHeader,jdbcType=VARCHAR},
  398. </if>
  399. <if test="billContent != null">
  400. #{billContent,jdbcType=VARCHAR},
  401. </if>
  402. <if test="billReceiverPhone != null">
  403. #{billReceiverPhone,jdbcType=VARCHAR},
  404. </if>
  405. <if test="billReceiverEmail != null">
  406. #{billReceiverEmail,jdbcType=VARCHAR},
  407. </if>
  408. <if test="receiverName != null">
  409. #{receiverName,jdbcType=VARCHAR},
  410. </if>
  411. <if test="receiverPhone != null">
  412. #{receiverPhone,jdbcType=VARCHAR},
  413. </if>
  414. <if test="receiverPostCode != null">
  415. #{receiverPostCode,jdbcType=VARCHAR},
  416. </if>
  417. <if test="receiverProvince != null">
  418. #{receiverProvince,jdbcType=VARCHAR},
  419. </if>
  420. <if test="receiverCity != null">
  421. #{receiverCity,jdbcType=VARCHAR},
  422. </if>
  423. <if test="receiverRegion != null">
  424. #{receiverRegion,jdbcType=VARCHAR},
  425. </if>
  426. <if test="receiverDetailAddress != null">
  427. #{receiverDetailAddress,jdbcType=VARCHAR},
  428. </if>
  429. <if test="note != null">
  430. #{note,jdbcType=VARCHAR},
  431. </if>
  432. <if test="confirmStatus != null">
  433. #{confirmStatus,jdbcType=INTEGER},
  434. </if>
  435. <if test="deleteStatus != null">
  436. #{deleteStatus,jdbcType=INTEGER},
  437. </if>
  438. <if test="useIntegration != null">
  439. #{useIntegration,jdbcType=INTEGER},
  440. </if>
  441. <if test="paymentTime != null">
  442. #{paymentTime,jdbcType=TIMESTAMP},
  443. </if>
  444. <if test="deliveryTime != null">
  445. #{deliveryTime,jdbcType=TIMESTAMP},
  446. </if>
  447. <if test="receiveTime != null">
  448. #{receiveTime,jdbcType=TIMESTAMP},
  449. </if>
  450. <if test="commentTime != null">
  451. #{commentTime,jdbcType=TIMESTAMP},
  452. </if>
  453. <if test="modifyTime != null">
  454. #{modifyTime,jdbcType=TIMESTAMP},
  455. </if>
  456. <if test="cartIds != null">
  457. #{cartIds},
  458. </if>
  459. <if test="platformType != null">
  460. #{platformType},
  461. </if>
  462. </trim>
  463. </insert>
  464. <select id="countByExample" parameterType="com.yonge.cooleshow.mbg.model.OmsOrderExample" resultType="java.lang.Long">
  465. select count(*) from oms_order
  466. <if test="_parameter != null">
  467. <include refid="Example_Where_Clause" />
  468. </if>
  469. </select>
  470. <update id="updateByExampleSelective" parameterType="map">
  471. update oms_order
  472. <set>
  473. <if test="record.id != null">
  474. id = #{record.id,jdbcType=BIGINT},
  475. </if>
  476. <if test="record.memberId != null">
  477. member_id = #{record.memberId,jdbcType=BIGINT},
  478. </if>
  479. <if test="record.couponId != null">
  480. coupon_id = #{record.couponId,jdbcType=BIGINT},
  481. </if>
  482. <if test="record.orderSn != null">
  483. order_sn = #{record.orderSn,jdbcType=VARCHAR},
  484. </if>
  485. <if test="record.createTime != null">
  486. create_time = #{record.createTime,jdbcType=TIMESTAMP},
  487. </if>
  488. <if test="record.memberUsername != null">
  489. member_username = #{record.memberUsername,jdbcType=VARCHAR},
  490. </if>
  491. <if test="record.totalAmount != null">
  492. total_amount = #{record.totalAmount,jdbcType=DECIMAL},
  493. </if>
  494. <if test="record.payAmount != null">
  495. pay_amount = #{record.payAmount,jdbcType=DECIMAL},
  496. </if>
  497. <if test="record.freightAmount != null">
  498. freight_amount = #{record.freightAmount,jdbcType=DECIMAL},
  499. </if>
  500. <if test="record.promotionAmount != null">
  501. promotion_amount = #{record.promotionAmount,jdbcType=DECIMAL},
  502. </if>
  503. <if test="record.integrationAmount != null">
  504. integration_amount = #{record.integrationAmount,jdbcType=DECIMAL},
  505. </if>
  506. <if test="record.couponAmount != null">
  507. coupon_amount = #{record.couponAmount,jdbcType=DECIMAL},
  508. </if>
  509. <if test="record.discountAmount != null">
  510. discount_amount = #{record.discountAmount,jdbcType=DECIMAL},
  511. </if>
  512. <if test="record.payType != null">
  513. pay_type = #{record.payType,jdbcType=INTEGER},
  514. </if>
  515. <if test="record.sourceType != null">
  516. source_type = #{record.sourceType,jdbcType=INTEGER},
  517. </if>
  518. <if test="record.status != null">
  519. status = #{record.status,jdbcType=INTEGER},
  520. </if>
  521. <if test="record.orderType != null">
  522. order_type = #{record.orderType,jdbcType=INTEGER},
  523. </if>
  524. <if test="record.deliveryCompany != null">
  525. delivery_company = #{record.deliveryCompany,jdbcType=VARCHAR},
  526. </if>
  527. <if test="record.deliverySn != null">
  528. delivery_sn = #{record.deliverySn,jdbcType=VARCHAR},
  529. </if>
  530. <if test="record.autoConfirmDay != null">
  531. auto_confirm_day = #{record.autoConfirmDay,jdbcType=INTEGER},
  532. </if>
  533. <if test="record.integration != null">
  534. integration = #{record.integration,jdbcType=INTEGER},
  535. </if>
  536. <if test="record.growth != null">
  537. growth = #{record.growth,jdbcType=INTEGER},
  538. </if>
  539. <if test="record.promotionInfo != null">
  540. promotion_info = #{record.promotionInfo,jdbcType=VARCHAR},
  541. </if>
  542. <if test="record.billType != null">
  543. bill_type = #{record.billType,jdbcType=INTEGER},
  544. </if>
  545. <if test="record.billHeader != null">
  546. bill_header = #{record.billHeader,jdbcType=VARCHAR},
  547. </if>
  548. <if test="record.billContent != null">
  549. bill_content = #{record.billContent,jdbcType=VARCHAR},
  550. </if>
  551. <if test="record.billReceiverPhone != null">
  552. bill_receiver_phone = #{record.billReceiverPhone,jdbcType=VARCHAR},
  553. </if>
  554. <if test="record.billReceiverEmail != null">
  555. bill_receiver_email = #{record.billReceiverEmail,jdbcType=VARCHAR},
  556. </if>
  557. <if test="record.receiverName != null">
  558. receiver_name = #{record.receiverName,jdbcType=VARCHAR},
  559. </if>
  560. <if test="record.receiverPhone != null">
  561. receiver_phone = #{record.receiverPhone,jdbcType=VARCHAR},
  562. </if>
  563. <if test="record.receiverPostCode != null">
  564. receiver_post_code = #{record.receiverPostCode,jdbcType=VARCHAR},
  565. </if>
  566. <if test="record.receiverProvince != null">
  567. receiver_province = #{record.receiverProvince,jdbcType=VARCHAR},
  568. </if>
  569. <if test="record.receiverCity != null">
  570. receiver_city = #{record.receiverCity,jdbcType=VARCHAR},
  571. </if>
  572. <if test="record.receiverRegion != null">
  573. receiver_region = #{record.receiverRegion,jdbcType=VARCHAR},
  574. </if>
  575. <if test="record.receiverDetailAddress != null">
  576. receiver_detail_address = #{record.receiverDetailAddress,jdbcType=VARCHAR},
  577. </if>
  578. <if test="record.note != null">
  579. note = #{record.note,jdbcType=VARCHAR},
  580. </if>
  581. <if test="record.confirmStatus != null">
  582. confirm_status = #{record.confirmStatus,jdbcType=INTEGER},
  583. </if>
  584. <if test="record.deleteStatus != null">
  585. delete_status = #{record.deleteStatus,jdbcType=INTEGER},
  586. </if>
  587. <if test="record.useIntegration != null">
  588. use_integration = #{record.useIntegration,jdbcType=INTEGER},
  589. </if>
  590. <if test="record.paymentTime != null">
  591. payment_time = #{record.paymentTime,jdbcType=TIMESTAMP},
  592. </if>
  593. <if test="record.deliveryTime != null">
  594. delivery_time = #{record.deliveryTime,jdbcType=TIMESTAMP},
  595. </if>
  596. <if test="record.receiveTime != null">
  597. receive_time = #{record.receiveTime,jdbcType=TIMESTAMP},
  598. </if>
  599. <if test="record.commentTime != null">
  600. comment_time = #{record.commentTime,jdbcType=TIMESTAMP},
  601. </if>
  602. <if test="record.modifyTime != null">
  603. modify_time = #{record.modifyTime,jdbcType=TIMESTAMP},
  604. </if>
  605. <if test="record.cartIds != null">
  606. cart_ids = #{record.cartIds},
  607. </if>
  608. <if test="record.platformType != null">
  609. platform_type = #{record.platformType},
  610. </if>
  611. </set>
  612. <if test="_parameter != null">
  613. <include refid="Update_By_Example_Where_Clause" />
  614. </if>
  615. </update>
  616. <update id="updateByExample" parameterType="map">
  617. update oms_order
  618. set id = #{record.id,jdbcType=BIGINT},
  619. member_id = #{record.memberId,jdbcType=BIGINT},
  620. coupon_id = #{record.couponId,jdbcType=BIGINT},
  621. order_sn = #{record.orderSn,jdbcType=VARCHAR},
  622. create_time = #{record.createTime,jdbcType=TIMESTAMP},
  623. member_username = #{record.memberUsername,jdbcType=VARCHAR},
  624. total_amount = #{record.totalAmount,jdbcType=DECIMAL},
  625. pay_amount = #{record.payAmount,jdbcType=DECIMAL},
  626. freight_amount = #{record.freightAmount,jdbcType=DECIMAL},
  627. promotion_amount = #{record.promotionAmount,jdbcType=DECIMAL},
  628. integration_amount = #{record.integrationAmount,jdbcType=DECIMAL},
  629. coupon_amount = #{record.couponAmount,jdbcType=DECIMAL},
  630. discount_amount = #{record.discountAmount,jdbcType=DECIMAL},
  631. pay_type = #{record.payType,jdbcType=INTEGER},
  632. source_type = #{record.sourceType,jdbcType=INTEGER},
  633. status = #{record.status,jdbcType=INTEGER},
  634. order_type = #{record.orderType,jdbcType=INTEGER},
  635. delivery_company = #{record.deliveryCompany,jdbcType=VARCHAR},
  636. delivery_sn = #{record.deliverySn,jdbcType=VARCHAR},
  637. auto_confirm_day = #{record.autoConfirmDay,jdbcType=INTEGER},
  638. integration = #{record.integration,jdbcType=INTEGER},
  639. growth = #{record.growth,jdbcType=INTEGER},
  640. promotion_info = #{record.promotionInfo,jdbcType=VARCHAR},
  641. bill_type = #{record.billType,jdbcType=INTEGER},
  642. bill_header = #{record.billHeader,jdbcType=VARCHAR},
  643. bill_content = #{record.billContent,jdbcType=VARCHAR},
  644. bill_receiver_phone = #{record.billReceiverPhone,jdbcType=VARCHAR},
  645. bill_receiver_email = #{record.billReceiverEmail,jdbcType=VARCHAR},
  646. receiver_name = #{record.receiverName,jdbcType=VARCHAR},
  647. receiver_phone = #{record.receiverPhone,jdbcType=VARCHAR},
  648. receiver_post_code = #{record.receiverPostCode,jdbcType=VARCHAR},
  649. receiver_province = #{record.receiverProvince,jdbcType=VARCHAR},
  650. receiver_city = #{record.receiverCity,jdbcType=VARCHAR},
  651. receiver_region = #{record.receiverRegion,jdbcType=VARCHAR},
  652. receiver_detail_address = #{record.receiverDetailAddress,jdbcType=VARCHAR},
  653. note = #{record.note,jdbcType=VARCHAR},
  654. confirm_status = #{record.confirmStatus,jdbcType=INTEGER},
  655. delete_status = #{record.deleteStatus,jdbcType=INTEGER},
  656. use_integration = #{record.useIntegration,jdbcType=INTEGER},
  657. payment_time = #{record.paymentTime,jdbcType=TIMESTAMP},
  658. delivery_time = #{record.deliveryTime,jdbcType=TIMESTAMP},
  659. receive_time = #{record.receiveTime,jdbcType=TIMESTAMP},
  660. comment_time = #{record.commentTime,jdbcType=TIMESTAMP},
  661. cart_ids = #{record.cartIds},
  662. platform_type = #{record.platformType},
  663. modify_time = #{record.modifyTime,jdbcType=TIMESTAMP}
  664. <if test="_parameter != null">
  665. <include refid="Update_By_Example_Where_Clause" />
  666. </if>
  667. </update>
  668. <update id="updateByPrimaryKeySelective" parameterType="com.yonge.cooleshow.mbg.model.OmsOrder">
  669. update oms_order
  670. <set>
  671. <if test="memberId != null">
  672. member_id = #{memberId,jdbcType=BIGINT},
  673. </if>
  674. <if test="couponId != null">
  675. coupon_id = #{couponId,jdbcType=BIGINT},
  676. </if>
  677. <if test="orderSn != null">
  678. order_sn = #{orderSn,jdbcType=VARCHAR},
  679. </if>
  680. <if test="createTime != null">
  681. create_time = #{createTime,jdbcType=TIMESTAMP},
  682. </if>
  683. <if test="memberUsername != null">
  684. member_username = #{memberUsername,jdbcType=VARCHAR},
  685. </if>
  686. <if test="totalAmount != null">
  687. total_amount = #{totalAmount,jdbcType=DECIMAL},
  688. </if>
  689. <if test="payAmount != null">
  690. pay_amount = #{payAmount,jdbcType=DECIMAL},
  691. </if>
  692. <if test="freightAmount != null">
  693. freight_amount = #{freightAmount,jdbcType=DECIMAL},
  694. </if>
  695. <if test="promotionAmount != null">
  696. promotion_amount = #{promotionAmount,jdbcType=DECIMAL},
  697. </if>
  698. <if test="integrationAmount != null">
  699. integration_amount = #{integrationAmount,jdbcType=DECIMAL},
  700. </if>
  701. <if test="couponAmount != null">
  702. coupon_amount = #{couponAmount,jdbcType=DECIMAL},
  703. </if>
  704. <if test="discountAmount != null">
  705. discount_amount = #{discountAmount,jdbcType=DECIMAL},
  706. </if>
  707. <if test="payType != null">
  708. pay_type = #{payType,jdbcType=INTEGER},
  709. </if>
  710. <if test="sourceType != null">
  711. source_type = #{sourceType,jdbcType=INTEGER},
  712. </if>
  713. <if test="status != null">
  714. status = #{status,jdbcType=INTEGER},
  715. </if>
  716. <if test="orderType != null">
  717. order_type = #{orderType,jdbcType=INTEGER},
  718. </if>
  719. <if test="deliveryCompany != null">
  720. delivery_company = #{deliveryCompany,jdbcType=VARCHAR},
  721. </if>
  722. <if test="deliverySn != null">
  723. delivery_sn = #{deliverySn,jdbcType=VARCHAR},
  724. </if>
  725. <if test="autoConfirmDay != null">
  726. auto_confirm_day = #{autoConfirmDay,jdbcType=INTEGER},
  727. </if>
  728. <if test="integration != null">
  729. integration = #{integration,jdbcType=INTEGER},
  730. </if>
  731. <if test="growth != null">
  732. growth = #{growth,jdbcType=INTEGER},
  733. </if>
  734. <if test="promotionInfo != null">
  735. promotion_info = #{promotionInfo,jdbcType=VARCHAR},
  736. </if>
  737. <if test="billType != null">
  738. bill_type = #{billType,jdbcType=INTEGER},
  739. </if>
  740. <if test="billHeader != null">
  741. bill_header = #{billHeader,jdbcType=VARCHAR},
  742. </if>
  743. <if test="billContent != null">
  744. bill_content = #{billContent,jdbcType=VARCHAR},
  745. </if>
  746. <if test="billReceiverPhone != null">
  747. bill_receiver_phone = #{billReceiverPhone,jdbcType=VARCHAR},
  748. </if>
  749. <if test="billReceiverEmail != null">
  750. bill_receiver_email = #{billReceiverEmail,jdbcType=VARCHAR},
  751. </if>
  752. <if test="receiverName != null">
  753. receiver_name = #{receiverName,jdbcType=VARCHAR},
  754. </if>
  755. <if test="receiverPhone != null">
  756. receiver_phone = #{receiverPhone,jdbcType=VARCHAR},
  757. </if>
  758. <if test="receiverPostCode != null">
  759. receiver_post_code = #{receiverPostCode,jdbcType=VARCHAR},
  760. </if>
  761. <if test="receiverProvince != null">
  762. receiver_province = #{receiverProvince,jdbcType=VARCHAR},
  763. </if>
  764. <if test="receiverCity != null">
  765. receiver_city = #{receiverCity,jdbcType=VARCHAR},
  766. </if>
  767. <if test="receiverRegion != null">
  768. receiver_region = #{receiverRegion,jdbcType=VARCHAR},
  769. </if>
  770. <if test="receiverDetailAddress != null">
  771. receiver_detail_address = #{receiverDetailAddress,jdbcType=VARCHAR},
  772. </if>
  773. <if test="note != null">
  774. note = #{note,jdbcType=VARCHAR},
  775. </if>
  776. <if test="confirmStatus != null">
  777. confirm_status = #{confirmStatus,jdbcType=INTEGER},
  778. </if>
  779. <if test="deleteStatus != null">
  780. delete_status = #{deleteStatus,jdbcType=INTEGER},
  781. </if>
  782. <if test="useIntegration != null">
  783. use_integration = #{useIntegration,jdbcType=INTEGER},
  784. </if>
  785. <if test="paymentTime != null">
  786. payment_time = #{paymentTime,jdbcType=TIMESTAMP},
  787. </if>
  788. <if test="deliveryTime != null">
  789. delivery_time = #{deliveryTime,jdbcType=TIMESTAMP},
  790. </if>
  791. <if test="receiveTime != null">
  792. receive_time = #{receiveTime,jdbcType=TIMESTAMP},
  793. </if>
  794. <if test="commentTime != null">
  795. comment_time = #{commentTime,jdbcType=TIMESTAMP},
  796. </if>
  797. <if test="modifyTime != null">
  798. modify_time = #{modifyTime,jdbcType=TIMESTAMP},
  799. </if>
  800. <if test="cartIds != null">
  801. cart_ids = #{cartIds},
  802. </if>
  803. <if test="platformType != null">
  804. platform_type = #{platformType},
  805. </if>
  806. </set>
  807. where id = #{id,jdbcType=BIGINT}
  808. </update>
  809. <update id="updateByPrimaryKey" parameterType="com.yonge.cooleshow.mbg.model.OmsOrder">
  810. update oms_order
  811. set member_id = #{memberId,jdbcType=BIGINT},
  812. coupon_id = #{couponId,jdbcType=BIGINT},
  813. order_sn = #{orderSn,jdbcType=VARCHAR},
  814. create_time = #{createTime,jdbcType=TIMESTAMP},
  815. member_username = #{memberUsername,jdbcType=VARCHAR},
  816. total_amount = #{totalAmount,jdbcType=DECIMAL},
  817. pay_amount = #{payAmount,jdbcType=DECIMAL},
  818. freight_amount = #{freightAmount,jdbcType=DECIMAL},
  819. promotion_amount = #{promotionAmount,jdbcType=DECIMAL},
  820. integration_amount = #{integrationAmount,jdbcType=DECIMAL},
  821. coupon_amount = #{couponAmount,jdbcType=DECIMAL},
  822. discount_amount = #{discountAmount,jdbcType=DECIMAL},
  823. pay_type = #{payType,jdbcType=INTEGER},
  824. source_type = #{sourceType,jdbcType=INTEGER},
  825. status = #{status,jdbcType=INTEGER},
  826. order_type = #{orderType,jdbcType=INTEGER},
  827. delivery_company = #{deliveryCompany,jdbcType=VARCHAR},
  828. delivery_sn = #{deliverySn,jdbcType=VARCHAR},
  829. auto_confirm_day = #{autoConfirmDay,jdbcType=INTEGER},
  830. integration = #{integration,jdbcType=INTEGER},
  831. growth = #{growth,jdbcType=INTEGER},
  832. promotion_info = #{promotionInfo,jdbcType=VARCHAR},
  833. bill_type = #{billType,jdbcType=INTEGER},
  834. bill_header = #{billHeader,jdbcType=VARCHAR},
  835. bill_content = #{billContent,jdbcType=VARCHAR},
  836. bill_receiver_phone = #{billReceiverPhone,jdbcType=VARCHAR},
  837. bill_receiver_email = #{billReceiverEmail,jdbcType=VARCHAR},
  838. receiver_name = #{receiverName,jdbcType=VARCHAR},
  839. receiver_phone = #{receiverPhone,jdbcType=VARCHAR},
  840. receiver_post_code = #{receiverPostCode,jdbcType=VARCHAR},
  841. receiver_province = #{receiverProvince,jdbcType=VARCHAR},
  842. receiver_city = #{receiverCity,jdbcType=VARCHAR},
  843. receiver_region = #{receiverRegion,jdbcType=VARCHAR},
  844. receiver_detail_address = #{receiverDetailAddress,jdbcType=VARCHAR},
  845. note = #{note,jdbcType=VARCHAR},
  846. confirm_status = #{confirmStatus,jdbcType=INTEGER},
  847. delete_status = #{deleteStatus,jdbcType=INTEGER},
  848. use_integration = #{useIntegration,jdbcType=INTEGER},
  849. payment_time = #{paymentTime,jdbcType=TIMESTAMP},
  850. delivery_time = #{deliveryTime,jdbcType=TIMESTAMP},
  851. receive_time = #{receiveTime,jdbcType=TIMESTAMP},
  852. comment_time = #{commentTime,jdbcType=TIMESTAMP},
  853. cart_ids = #{cartIds},
  854. platform_type = #{platformType},
  855. modify_time = #{modifyTime,jdbcType=TIMESTAMP}
  856. where id = #{id,jdbcType=BIGINT}
  857. </update>
  858. </mapper>