PeConfirmsponsorUserMapper.xml 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386
  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.ghsc.partybuild.mapper.PeConfirmsponsorUserMapper">
  4. <resultMap id="BaseResultMap" type="com.ghsc.partybuild.model.PeConfirmsponsorUser">
  5. <id column="ID" jdbcType="VARCHAR" property="id" />
  6. <result column="CONFIRMSPONSORID" jdbcType="VARCHAR" property="confirmsponsorid" />
  7. <result column="USERNAME" jdbcType="VARCHAR" property="username" />
  8. <result column="USERCODE" jdbcType="VARCHAR" property="usercode" />
  9. <result column="POSITION" jdbcType="VARCHAR" property="position" />
  10. <result column="JOINTIME" jdbcType="TIMESTAMP" property="jointime" />
  11. <result column="ISLINECLAN" jdbcType="DECIMAL" property="islineclan" />
  12. <result column="CREATETIME" jdbcType="TIMESTAMP" property="createtime" />
  13. <result column="CREATEUSERID" jdbcType="VARCHAR" property="createuserid" />
  14. <result column="CREATEUSERNAME" jdbcType="VARCHAR" property="createusername" />
  15. <result column="UPDATETIME" jdbcType="TIMESTAMP" property="updatetime" />
  16. <result column="UPDATEUSERID" jdbcType="VARCHAR" property="updateuserid" />
  17. <result column="UPDATEUSERNAME" jdbcType="VARCHAR" property="updateusername" />
  18. <result column="OPERATETIME" jdbcType="TIMESTAMP" property="operatetime" />
  19. <result column="OPERATESTATE" jdbcType="VARCHAR" property="operatestate" />
  20. <result column="SYNCSTATE" jdbcType="VARCHAR" property="syncstate" />
  21. </resultMap>
  22. <sql id="Example_Where_Clause">
  23. <where>
  24. <foreach collection="oredCriteria" item="criteria" separator="or">
  25. <if test="criteria.valid">
  26. <trim prefix="(" prefixOverrides="and" suffix=")">
  27. <foreach collection="criteria.criteria" item="criterion">
  28. <choose>
  29. <when test="criterion.noValue">
  30. and ${criterion.condition}
  31. </when>
  32. <when test="criterion.singleValue">
  33. and ${criterion.condition} #{criterion.value}
  34. </when>
  35. <when test="criterion.betweenValue">
  36. and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
  37. </when>
  38. <when test="criterion.listValue">
  39. and ${criterion.condition}
  40. <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
  41. #{listItem}
  42. </foreach>
  43. </when>
  44. </choose>
  45. </foreach>
  46. </trim>
  47. </if>
  48. </foreach>
  49. </where>
  50. </sql>
  51. <sql id="Update_By_Example_Where_Clause">
  52. <where>
  53. <foreach collection="example.oredCriteria" item="criteria" separator="or">
  54. <if test="criteria.valid">
  55. <trim prefix="(" prefixOverrides="and" suffix=")">
  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 close=")" collection="criterion.value" item="listItem" open="(" 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. ID, CONFIRMSPONSORID, USERNAME, USERCODE, POSITION, JOINTIME, ISLINECLAN, CREATETIME,
  82. CREATEUSERID, CREATEUSERNAME, UPDATETIME, UPDATEUSERID, UPDATEUSERNAME, OPERATETIME,
  83. OPERATESTATE, SYNCSTATE
  84. </sql>
  85. <select id="selectByExample" parameterType="com.ghsc.partybuild.model.PeConfirmsponsorUserExample" resultMap="BaseResultMap">
  86. select
  87. <if test="distinct">
  88. distinct
  89. </if>
  90. <include refid="Base_Column_List" />
  91. from pe_confirmsponsor_user
  92. <if test="_parameter != null">
  93. <include refid="Example_Where_Clause" />
  94. </if>
  95. <if test="orderByClause != null">
  96. order by ${orderByClause}
  97. </if>
  98. </select>
  99. <select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
  100. select
  101. <include refid="Base_Column_List" />
  102. from pe_confirmsponsor_user
  103. where ID = #{id,jdbcType=VARCHAR}
  104. </select>
  105. <delete id="deleteByPrimaryKey" parameterType="java.lang.String">
  106. delete from pe_confirmsponsor_user
  107. where ID = #{id,jdbcType=VARCHAR}
  108. </delete>
  109. <delete id="deleteByExample" parameterType="com.ghsc.partybuild.model.PeConfirmsponsorUserExample">
  110. delete from pe_confirmsponsor_user
  111. <if test="_parameter != null">
  112. <include refid="Example_Where_Clause" />
  113. </if>
  114. </delete>
  115. <insert id="insert" parameterType="com.ghsc.partybuild.model.PeConfirmsponsorUser">
  116. insert into pe_confirmsponsor_user (ID, CONFIRMSPONSORID, USERNAME,
  117. USERCODE, POSITION, JOINTIME,
  118. ISLINECLAN, CREATETIME, CREATEUSERID,
  119. CREATEUSERNAME, UPDATETIME, UPDATEUSERID,
  120. UPDATEUSERNAME, OPERATETIME, OPERATESTATE,
  121. SYNCSTATE)
  122. values (#{id,jdbcType=VARCHAR}, #{confirmsponsorid,jdbcType=VARCHAR}, #{username,jdbcType=VARCHAR},
  123. #{usercode,jdbcType=VARCHAR}, #{position,jdbcType=VARCHAR}, #{jointime,jdbcType=TIMESTAMP},
  124. #{islineclan,jdbcType=DECIMAL}, #{createtime,jdbcType=TIMESTAMP}, #{createuserid,jdbcType=VARCHAR},
  125. #{createusername,jdbcType=VARCHAR}, #{updatetime,jdbcType=TIMESTAMP}, #{updateuserid,jdbcType=VARCHAR},
  126. #{updateusername,jdbcType=VARCHAR}, #{operatetime,jdbcType=TIMESTAMP}, #{operatestate,jdbcType=VARCHAR},
  127. #{syncstate,jdbcType=VARCHAR})
  128. </insert>
  129. <insert id="insertSelective" parameterType="com.ghsc.partybuild.model.PeConfirmsponsorUser">
  130. insert into pe_confirmsponsor_user
  131. <trim prefix="(" suffix=")" suffixOverrides=",">
  132. <if test="id != null">
  133. ID,
  134. </if>
  135. <if test="confirmsponsorid != null">
  136. CONFIRMSPONSORID,
  137. </if>
  138. <if test="username != null">
  139. USERNAME,
  140. </if>
  141. <if test="usercode != null">
  142. USERCODE,
  143. </if>
  144. <if test="position != null">
  145. POSITION,
  146. </if>
  147. <if test="jointime != null">
  148. JOINTIME,
  149. </if>
  150. <if test="islineclan != null">
  151. ISLINECLAN,
  152. </if>
  153. <if test="createtime != null">
  154. CREATETIME,
  155. </if>
  156. <if test="createuserid != null">
  157. CREATEUSERID,
  158. </if>
  159. <if test="createusername != null">
  160. CREATEUSERNAME,
  161. </if>
  162. <if test="updatetime != null">
  163. UPDATETIME,
  164. </if>
  165. <if test="updateuserid != null">
  166. UPDATEUSERID,
  167. </if>
  168. <if test="updateusername != null">
  169. UPDATEUSERNAME,
  170. </if>
  171. <if test="operatetime != null">
  172. OPERATETIME,
  173. </if>
  174. <if test="operatestate != null">
  175. OPERATESTATE,
  176. </if>
  177. <if test="syncstate != null">
  178. SYNCSTATE,
  179. </if>
  180. </trim>
  181. <trim prefix="values (" suffix=")" suffixOverrides=",">
  182. <if test="id != null">
  183. #{id,jdbcType=VARCHAR},
  184. </if>
  185. <if test="confirmsponsorid != null">
  186. #{confirmsponsorid,jdbcType=VARCHAR},
  187. </if>
  188. <if test="username != null">
  189. #{username,jdbcType=VARCHAR},
  190. </if>
  191. <if test="usercode != null">
  192. #{usercode,jdbcType=VARCHAR},
  193. </if>
  194. <if test="position != null">
  195. #{position,jdbcType=VARCHAR},
  196. </if>
  197. <if test="jointime != null">
  198. #{jointime,jdbcType=TIMESTAMP},
  199. </if>
  200. <if test="islineclan != null">
  201. #{islineclan,jdbcType=DECIMAL},
  202. </if>
  203. <if test="createtime != null">
  204. #{createtime,jdbcType=TIMESTAMP},
  205. </if>
  206. <if test="createuserid != null">
  207. #{createuserid,jdbcType=VARCHAR},
  208. </if>
  209. <if test="createusername != null">
  210. #{createusername,jdbcType=VARCHAR},
  211. </if>
  212. <if test="updatetime != null">
  213. #{updatetime,jdbcType=TIMESTAMP},
  214. </if>
  215. <if test="updateuserid != null">
  216. #{updateuserid,jdbcType=VARCHAR},
  217. </if>
  218. <if test="updateusername != null">
  219. #{updateusername,jdbcType=VARCHAR},
  220. </if>
  221. <if test="operatetime != null">
  222. #{operatetime,jdbcType=TIMESTAMP},
  223. </if>
  224. <if test="operatestate != null">
  225. #{operatestate,jdbcType=VARCHAR},
  226. </if>
  227. <if test="syncstate != null">
  228. #{syncstate,jdbcType=VARCHAR},
  229. </if>
  230. </trim>
  231. </insert>
  232. <select id="countByExample" parameterType="com.ghsc.partybuild.model.PeConfirmsponsorUserExample" resultType="java.lang.Long">
  233. select count(*) from pe_confirmsponsor_user
  234. <if test="_parameter != null">
  235. <include refid="Example_Where_Clause" />
  236. </if>
  237. </select>
  238. <update id="updateByExampleSelective" parameterType="map">
  239. update pe_confirmsponsor_user
  240. <set>
  241. <if test="record.id != null">
  242. ID = #{record.id,jdbcType=VARCHAR},
  243. </if>
  244. <if test="record.confirmsponsorid != null">
  245. CONFIRMSPONSORID = #{record.confirmsponsorid,jdbcType=VARCHAR},
  246. </if>
  247. <if test="record.username != null">
  248. USERNAME = #{record.username,jdbcType=VARCHAR},
  249. </if>
  250. <if test="record.usercode != null">
  251. USERCODE = #{record.usercode,jdbcType=VARCHAR},
  252. </if>
  253. <if test="record.position != null">
  254. POSITION = #{record.position,jdbcType=VARCHAR},
  255. </if>
  256. <if test="record.jointime != null">
  257. JOINTIME = #{record.jointime,jdbcType=TIMESTAMP},
  258. </if>
  259. <if test="record.islineclan != null">
  260. ISLINECLAN = #{record.islineclan,jdbcType=DECIMAL},
  261. </if>
  262. <if test="record.createtime != null">
  263. CREATETIME = #{record.createtime,jdbcType=TIMESTAMP},
  264. </if>
  265. <if test="record.createuserid != null">
  266. CREATEUSERID = #{record.createuserid,jdbcType=VARCHAR},
  267. </if>
  268. <if test="record.createusername != null">
  269. CREATEUSERNAME = #{record.createusername,jdbcType=VARCHAR},
  270. </if>
  271. <if test="record.updatetime != null">
  272. UPDATETIME = #{record.updatetime,jdbcType=TIMESTAMP},
  273. </if>
  274. <if test="record.updateuserid != null">
  275. UPDATEUSERID = #{record.updateuserid,jdbcType=VARCHAR},
  276. </if>
  277. <if test="record.updateusername != null">
  278. UPDATEUSERNAME = #{record.updateusername,jdbcType=VARCHAR},
  279. </if>
  280. <if test="record.operatetime != null">
  281. OPERATETIME = #{record.operatetime,jdbcType=TIMESTAMP},
  282. </if>
  283. <if test="record.operatestate != null">
  284. OPERATESTATE = #{record.operatestate,jdbcType=VARCHAR},
  285. </if>
  286. <if test="record.syncstate != null">
  287. SYNCSTATE = #{record.syncstate,jdbcType=VARCHAR},
  288. </if>
  289. </set>
  290. <if test="_parameter != null">
  291. <include refid="Update_By_Example_Where_Clause" />
  292. </if>
  293. </update>
  294. <update id="updateByExample" parameterType="map">
  295. update pe_confirmsponsor_user
  296. set ID = #{record.id,jdbcType=VARCHAR},
  297. CONFIRMSPONSORID = #{record.confirmsponsorid,jdbcType=VARCHAR},
  298. USERNAME = #{record.username,jdbcType=VARCHAR},
  299. USERCODE = #{record.usercode,jdbcType=VARCHAR},
  300. POSITION = #{record.position,jdbcType=VARCHAR},
  301. JOINTIME = #{record.jointime,jdbcType=TIMESTAMP},
  302. ISLINECLAN = #{record.islineclan,jdbcType=DECIMAL},
  303. CREATETIME = #{record.createtime,jdbcType=TIMESTAMP},
  304. CREATEUSERID = #{record.createuserid,jdbcType=VARCHAR},
  305. CREATEUSERNAME = #{record.createusername,jdbcType=VARCHAR},
  306. UPDATETIME = #{record.updatetime,jdbcType=TIMESTAMP},
  307. UPDATEUSERID = #{record.updateuserid,jdbcType=VARCHAR},
  308. UPDATEUSERNAME = #{record.updateusername,jdbcType=VARCHAR},
  309. OPERATETIME = #{record.operatetime,jdbcType=TIMESTAMP},
  310. OPERATESTATE = #{record.operatestate,jdbcType=VARCHAR},
  311. SYNCSTATE = #{record.syncstate,jdbcType=VARCHAR}
  312. <if test="_parameter != null">
  313. <include refid="Update_By_Example_Where_Clause" />
  314. </if>
  315. </update>
  316. <update id="updateByPrimaryKeySelective" parameterType="com.ghsc.partybuild.model.PeConfirmsponsorUser">
  317. update pe_confirmsponsor_user
  318. <set>
  319. <if test="confirmsponsorid != null">
  320. CONFIRMSPONSORID = #{confirmsponsorid,jdbcType=VARCHAR},
  321. </if>
  322. <if test="username != null">
  323. USERNAME = #{username,jdbcType=VARCHAR},
  324. </if>
  325. <if test="usercode != null">
  326. USERCODE = #{usercode,jdbcType=VARCHAR},
  327. </if>
  328. <if test="position != null">
  329. POSITION = #{position,jdbcType=VARCHAR},
  330. </if>
  331. <if test="jointime != null">
  332. JOINTIME = #{jointime,jdbcType=TIMESTAMP},
  333. </if>
  334. <if test="islineclan != null">
  335. ISLINECLAN = #{islineclan,jdbcType=DECIMAL},
  336. </if>
  337. <if test="createtime != null">
  338. CREATETIME = #{createtime,jdbcType=TIMESTAMP},
  339. </if>
  340. <if test="createuserid != null">
  341. CREATEUSERID = #{createuserid,jdbcType=VARCHAR},
  342. </if>
  343. <if test="createusername != null">
  344. CREATEUSERNAME = #{createusername,jdbcType=VARCHAR},
  345. </if>
  346. <if test="updatetime != null">
  347. UPDATETIME = #{updatetime,jdbcType=TIMESTAMP},
  348. </if>
  349. <if test="updateuserid != null">
  350. UPDATEUSERID = #{updateuserid,jdbcType=VARCHAR},
  351. </if>
  352. <if test="updateusername != null">
  353. UPDATEUSERNAME = #{updateusername,jdbcType=VARCHAR},
  354. </if>
  355. <if test="operatetime != null">
  356. OPERATETIME = #{operatetime,jdbcType=TIMESTAMP},
  357. </if>
  358. <if test="operatestate != null">
  359. OPERATESTATE = #{operatestate,jdbcType=VARCHAR},
  360. </if>
  361. <if test="syncstate != null">
  362. SYNCSTATE = #{syncstate,jdbcType=VARCHAR},
  363. </if>
  364. </set>
  365. where ID = #{id,jdbcType=VARCHAR}
  366. </update>
  367. <update id="updateByPrimaryKey" parameterType="com.ghsc.partybuild.model.PeConfirmsponsorUser">
  368. update pe_confirmsponsor_user
  369. set CONFIRMSPONSORID = #{confirmsponsorid,jdbcType=VARCHAR},
  370. USERNAME = #{username,jdbcType=VARCHAR},
  371. USERCODE = #{usercode,jdbcType=VARCHAR},
  372. POSITION = #{position,jdbcType=VARCHAR},
  373. JOINTIME = #{jointime,jdbcType=TIMESTAMP},
  374. ISLINECLAN = #{islineclan,jdbcType=DECIMAL},
  375. CREATETIME = #{createtime,jdbcType=TIMESTAMP},
  376. CREATEUSERID = #{createuserid,jdbcType=VARCHAR},
  377. CREATEUSERNAME = #{createusername,jdbcType=VARCHAR},
  378. UPDATETIME = #{updatetime,jdbcType=TIMESTAMP},
  379. UPDATEUSERID = #{updateuserid,jdbcType=VARCHAR},
  380. UPDATEUSERNAME = #{updateusername,jdbcType=VARCHAR},
  381. OPERATETIME = #{operatetime,jdbcType=TIMESTAMP},
  382. OPERATESTATE = #{operatestate,jdbcType=VARCHAR},
  383. SYNCSTATE = #{syncstate,jdbcType=VARCHAR}
  384. where ID = #{id,jdbcType=VARCHAR}
  385. </update>
  386. </mapper>