SDdglFpglInvoiceinfoMapper.xml 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303
  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="SDdglFpglInvoiceinfoMapper" >
  4. <!-- 通用查询映射结果 -->
  5. <select id="selectSDdglFpglInvoiceinfoList" parameterType="pd" resultType="pd">
  6. select * from s_ddgl_fpgl_invoiceinfo where 1=1
  7. <if test="id !=null and id !='' ">
  8. and id = #{id}
  9. </if>
  10. <if test="platformOrderNo !=null and platformOrderNo !='' ">
  11. and platformOrderNo = #{platformOrderNo}
  12. </if>
  13. <if test="invoiceCode !=null and invoiceCode !='' ">
  14. and invoiceCode = #{invoiceCode}
  15. </if>
  16. <if test="invoiceNumber !=null and invoiceNumber !='' ">
  17. and invoiceNumber = #{invoiceNumber}
  18. </if>
  19. <if test="invoiceAmount !=null and invoiceAmount !='' ">
  20. and invoiceAmount = #{invoiceAmount}
  21. </if>
  22. <if test="channelStore !=null and channelStore !='' ">
  23. and channelStore = #{channelStore}
  24. </if>
  25. <if test="orderInvoiceType !=null and orderInvoiceType !='' ">
  26. and orderInvoiceType = #{orderInvoiceType}
  27. </if>
  28. <if test="invoiceType !=null and invoiceType !='' ">
  29. and invoiceType = #{invoiceType}
  30. </if>
  31. <if test="headerType !=null and headerType !='' ">
  32. and headerType = #{headerType}
  33. </if>
  34. <if test="headerName !=null and headerName !='' ">
  35. and headerName = #{headerName}
  36. </if>
  37. <if test="billingType !=null and billingType !='' ">
  38. and billingType = #{billingType}
  39. </if>
  40. <if test="billingTime !=null and billingTime !='' ">
  41. and billingTime = #{billingTime}
  42. </if>
  43. <if test="mailingInfo !=null and mailingInfo !='' ">
  44. and mailingInfo = #{mailingInfo}
  45. </if>
  46. <if test="billingAmount !=null and billingAmount !='' ">
  47. and billingAmount = #{billingAmount}
  48. </if>
  49. <if test="storeName !=null and storeName !='' ">
  50. and storeName = #{storeName}
  51. </if>
  52. <if test="auditType !=null and auditType !='' ">
  53. and auditType = #{auditType}
  54. </if>
  55. <if test="auditStatus !=null and auditStatus !='' ">
  56. and auditStatus = #{auditStatus}
  57. </if>
  58. <if test="noData !=null and noData !='' ">
  59. and noData = #{noData}
  60. </if>
  61. <if test="mergeOrderNo !=null and mergeOrderNo !='' ">
  62. and mergeOrderNo = #{mergeOrderNo}
  63. </if>
  64. <if test="orderNo !=null and orderNo !='' ">
  65. and orderNo = #{orderNo}
  66. </if>
  67. <if test="billingStatus !=null and billingStatus !='' ">
  68. and billingStatus = #{billingStatus}
  69. </if>
  70. <if test="createTime !=null and createTime !='' ">
  71. and createTime = #{createTime}
  72. </if>
  73. <if test="beginTime != null and beginTime!='' and endTime != null and endTime!=''">
  74. and createTime between #{beginTime} and #{endTime}
  75. </if>
  76. <if test="id !=null and id !='' ">
  77. and id = #{id}
  78. </if>
  79. </select>
  80. <update id="updateSDdglFpglInvoiceinfo" parameterType="pd" >
  81. update s_ddgl_fpgl_invoiceinfo
  82. <trim prefix=" SET " suffix="" prefixOverrides="," suffixOverrides=",">
  83. <if test="platformOrderNo !=null and platformOrderNo !='' ">
  84. platformOrderNo = #{platformOrderNo},
  85. </if>
  86. <if test="invoiceCode !=null and invoiceCode !='' ">
  87. invoiceCode = #{invoiceCode},
  88. </if>
  89. <if test="invoiceNumber !=null and invoiceNumber !='' ">
  90. invoiceNumber = #{invoiceNumber},
  91. </if>
  92. <if test="invoiceAmount !=null and invoiceAmount !='' ">
  93. invoiceAmount = #{invoiceAmount},
  94. </if>
  95. <if test="channelStore !=null and channelStore !='' ">
  96. channelStore = #{channelStore},
  97. </if>
  98. <if test="orderInvoiceType !=null and orderInvoiceType !='' ">
  99. orderInvoiceType = #{orderInvoiceType},
  100. </if>
  101. <if test="invoiceType !=null and invoiceType !='' ">
  102. invoiceType = #{invoiceType},
  103. </if>
  104. <if test="headerType !=null and headerType !='' ">
  105. headerType = #{headerType},
  106. </if>
  107. <if test="headerName !=null and headerName !='' ">
  108. headerName = #{headerName},
  109. </if>
  110. <if test="billingType !=null and billingType !='' ">
  111. billingType = #{billingType},
  112. </if>
  113. <if test="billingTime !=null and billingTime !='' ">
  114. billingTime = #{billingTime},
  115. </if>
  116. <if test="mailingInfo !=null and mailingInfo !='' ">
  117. mailingInfo = #{mailingInfo},
  118. </if>
  119. <if test="billingAmount !=null and billingAmount !='' ">
  120. billingAmount = #{billingAmount},
  121. </if>
  122. <if test="storeName !=null and storeName !='' ">
  123. storeName = #{storeName},
  124. </if>
  125. <if test="auditType !=null and auditType !='' ">
  126. auditType = #{auditType},
  127. </if>
  128. <if test="auditStatus !=null and auditStatus !='' ">
  129. auditStatus = #{auditStatus},
  130. </if>
  131. <if test="noData !=null and noData !='' ">
  132. noData = #{noData},
  133. </if>
  134. <if test="mergeOrderNo !=null and mergeOrderNo !='' ">
  135. mergeOrderNo = #{mergeOrderNo},
  136. </if>
  137. <if test="orderNo !=null and orderNo !='' ">
  138. orderNo = #{orderNo},
  139. </if>
  140. <if test="billingStatus !=null and billingStatus !='' ">
  141. billingStatus = #{billingStatus},
  142. </if>
  143. <if test="createTime !=null and createTime !='' ">
  144. createTime = #{createTime},
  145. </if>
  146. </trim>
  147. <if test="up != null and up!=''">
  148. <if test="id != null and id!=''">
  149. where id=#{id}
  150. </if>
  151. </if>
  152. </update>
  153. <delete id="SDdglFpglInvoiceinfoRemove" parameterType="pd">
  154. <if test="ids != null">
  155. delete from s_ddgl_fpgl_invoiceinfo where
  156. <if test="ids != null">
  157. id in(${ids})
  158. </if>
  159. </if>
  160. </delete>
  161. <insert id="addSDdglFpglInvoiceinfo" parameterType="pd" >
  162. insert into s_ddgl_fpgl_invoiceinfo
  163. <trim prefix="(" suffix=")" prefixOverrides="," suffixOverrides=",">
  164. <if test="platformOrderNo !=null and platformOrderNo !='' ">
  165. platformOrderNo,
  166. </if>
  167. <if test="invoiceCode !=null and invoiceCode !='' ">
  168. invoiceCode,
  169. </if>
  170. <if test="invoiceNumber !=null and invoiceNumber !='' ">
  171. invoiceNumber,
  172. </if>
  173. <if test="invoiceAmount !=null and invoiceAmount !='' ">
  174. invoiceAmount,
  175. </if>
  176. <if test="channelStore !=null and channelStore !='' ">
  177. channelStore,
  178. </if>
  179. <if test="orderInvoiceType !=null and orderInvoiceType !='' ">
  180. orderInvoiceType,
  181. </if>
  182. <if test="invoiceType !=null and invoiceType !='' ">
  183. invoiceType,
  184. </if>
  185. <if test="headerType !=null and headerType !='' ">
  186. headerType,
  187. </if>
  188. <if test="headerName !=null and headerName !='' ">
  189. headerName,
  190. </if>
  191. <if test="billingType !=null and billingType !='' ">
  192. billingType,
  193. </if>
  194. <if test="billingTime !=null and billingTime !='' ">
  195. billingTime,
  196. </if>
  197. <if test="mailingInfo !=null and mailingInfo !='' ">
  198. mailingInfo,
  199. </if>
  200. <if test="billingAmount !=null and billingAmount !='' ">
  201. billingAmount,
  202. </if>
  203. <if test="storeName !=null and storeName !='' ">
  204. storeName,
  205. </if>
  206. <if test="auditType !=null and auditType !='' ">
  207. auditType,
  208. </if>
  209. <if test="auditStatus !=null and auditStatus !='' ">
  210. auditStatus,
  211. </if>
  212. <if test="noData !=null and noData !='' ">
  213. noData,
  214. </if>
  215. <if test="mergeOrderNo !=null and mergeOrderNo !='' ">
  216. mergeOrderNo,
  217. </if>
  218. <if test="orderNo !=null and orderNo !='' ">
  219. orderNo,
  220. </if>
  221. <if test="billingStatus !=null and billingStatus !='' ">
  222. billingStatus,
  223. </if>
  224. <if test="createTime !=null and createTime !='' ">
  225. createTime,
  226. </if>
  227. </trim>
  228. <trim prefix=" VALUES (" suffix=")" prefixOverrides="," suffixOverrides=",">
  229. <if test="platformOrderNo !=null and platformOrderNo !='' ">
  230. #{platformOrderNo},
  231. </if>
  232. <if test="invoiceCode !=null and invoiceCode !='' ">
  233. #{invoiceCode},
  234. </if>
  235. <if test="invoiceNumber !=null and invoiceNumber !='' ">
  236. #{invoiceNumber},
  237. </if>
  238. <if test="invoiceAmount !=null and invoiceAmount !='' ">
  239. #{invoiceAmount},
  240. </if>
  241. <if test="channelStore !=null and channelStore !='' ">
  242. #{channelStore},
  243. </if>
  244. <if test="orderInvoiceType !=null and orderInvoiceType !='' ">
  245. #{orderInvoiceType},
  246. </if>
  247. <if test="invoiceType !=null and invoiceType !='' ">
  248. #{invoiceType},
  249. </if>
  250. <if test="headerType !=null and headerType !='' ">
  251. #{headerType},
  252. </if>
  253. <if test="headerName !=null and headerName !='' ">
  254. #{headerName},
  255. </if>
  256. <if test="billingType !=null and billingType !='' ">
  257. #{billingType},
  258. </if>
  259. <if test="billingTime !=null and billingTime !='' ">
  260. #{billingTime},
  261. </if>
  262. <if test="mailingInfo !=null and mailingInfo !='' ">
  263. #{mailingInfo},
  264. </if>
  265. <if test="billingAmount !=null and billingAmount !='' ">
  266. #{billingAmount},
  267. </if>
  268. <if test="storeName !=null and storeName !='' ">
  269. #{storeName},
  270. </if>
  271. <if test="auditType !=null and auditType !='' ">
  272. #{auditType},
  273. </if>
  274. <if test="auditStatus !=null and auditStatus !='' ">
  275. #{auditStatus},
  276. </if>
  277. <if test="noData !=null and noData !='' ">
  278. #{noData},
  279. </if>
  280. <if test="mergeOrderNo !=null and mergeOrderNo !='' ">
  281. #{mergeOrderNo},
  282. </if>
  283. <if test="orderNo !=null and orderNo !='' ">
  284. #{orderNo},
  285. </if>
  286. <if test="billingStatus !=null and billingStatus !='' ">
  287. #{billingStatus},
  288. </if>
  289. <if test="createTime !=null and createTime !='' ">
  290. #{createTime},
  291. </if>
  292. </trim>
  293. </insert>
  294. </mapper>