ThirdPartWeComStaffConfigTaskContentMapper.xml 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278
  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.tzld.piaoquan.api.dao.mapper.wecom.thirdpart.ThirdPartWeComStaffConfigTaskContentMapper">
  4. <resultMap id="BaseResultMap" type="com.tzld.piaoquan.api.model.po.wecom.thirdpart.ThirdPartWeComStaffConfigTaskContent">
  5. <id column="id" jdbcType="VARCHAR" property="id" />
  6. <result column="task_id" jdbcType="VARCHAR" property="taskId" />
  7. <result column="type" jdbcType="INTEGER" property="type" />
  8. <result column="content" jdbcType="VARCHAR" property="content" />
  9. <result column="source" jdbcType="INTEGER" property="source" />
  10. <result column="source_content" jdbcType="VARCHAR" property="sourceContent" />
  11. <result column="seq" jdbcType="INTEGER" property="seq" />
  12. <result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
  13. <result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
  14. </resultMap>
  15. <sql id="Example_Where_Clause">
  16. <where>
  17. <foreach collection="oredCriteria" item="criteria" separator="or">
  18. <if test="criteria.valid">
  19. <trim prefix="(" prefixOverrides="and" suffix=")">
  20. <foreach collection="criteria.criteria" item="criterion">
  21. <choose>
  22. <when test="criterion.noValue">
  23. and ${criterion.condition}
  24. </when>
  25. <when test="criterion.singleValue">
  26. and ${criterion.condition} #{criterion.value}
  27. </when>
  28. <when test="criterion.betweenValue">
  29. and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
  30. </when>
  31. <when test="criterion.listValue">
  32. and ${criterion.condition}
  33. <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
  34. #{listItem}
  35. </foreach>
  36. </when>
  37. </choose>
  38. </foreach>
  39. </trim>
  40. </if>
  41. </foreach>
  42. </where>
  43. </sql>
  44. <sql id="Update_By_Example_Where_Clause">
  45. <where>
  46. <foreach collection="example.oredCriteria" item="criteria" separator="or">
  47. <if test="criteria.valid">
  48. <trim prefix="(" prefixOverrides="and" suffix=")">
  49. <foreach collection="criteria.criteria" item="criterion">
  50. <choose>
  51. <when test="criterion.noValue">
  52. and ${criterion.condition}
  53. </when>
  54. <when test="criterion.singleValue">
  55. and ${criterion.condition} #{criterion.value}
  56. </when>
  57. <when test="criterion.betweenValue">
  58. and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
  59. </when>
  60. <when test="criterion.listValue">
  61. and ${criterion.condition}
  62. <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
  63. #{listItem}
  64. </foreach>
  65. </when>
  66. </choose>
  67. </foreach>
  68. </trim>
  69. </if>
  70. </foreach>
  71. </where>
  72. </sql>
  73. <sql id="Base_Column_List">
  74. id, task_id, `type`, content, `source`, source_content, seq, create_time, update_time
  75. </sql>
  76. <select id="selectByExample" parameterType="com.tzld.piaoquan.api.model.po.wecom.thirdpart.ThirdPartWeComStaffConfigTaskContentExample" resultMap="BaseResultMap">
  77. select
  78. <if test="distinct">
  79. distinct
  80. </if>
  81. <include refid="Base_Column_List" />
  82. from third_part_we_com_staff_config_task_content
  83. <if test="_parameter != null">
  84. <include refid="Example_Where_Clause" />
  85. </if>
  86. <if test="orderByClause != null">
  87. order by ${orderByClause}
  88. </if>
  89. <if test="page != null">
  90. limit #{page.offset} , #{page.pageSize}
  91. </if>
  92. </select>
  93. <select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
  94. select
  95. <include refid="Base_Column_List" />
  96. from third_part_we_com_staff_config_task_content
  97. where id = #{id,jdbcType=VARCHAR}
  98. </select>
  99. <delete id="deleteByPrimaryKey" parameterType="java.lang.String">
  100. delete from third_part_we_com_staff_config_task_content
  101. where id = #{id,jdbcType=VARCHAR}
  102. </delete>
  103. <delete id="deleteByExample" parameterType="com.tzld.piaoquan.api.model.po.wecom.thirdpart.ThirdPartWeComStaffConfigTaskContentExample">
  104. delete from third_part_we_com_staff_config_task_content
  105. <if test="_parameter != null">
  106. <include refid="Example_Where_Clause" />
  107. </if>
  108. </delete>
  109. <insert id="insert" parameterType="com.tzld.piaoquan.api.model.po.wecom.thirdpart.ThirdPartWeComStaffConfigTaskContent">
  110. insert into third_part_we_com_staff_config_task_content (id, task_id, `type`,
  111. content, `source`, source_content,
  112. seq, create_time, update_time
  113. )
  114. values (#{id,jdbcType=VARCHAR}, #{taskId,jdbcType=VARCHAR}, #{type,jdbcType=INTEGER},
  115. #{content,jdbcType=VARCHAR}, #{source,jdbcType=INTEGER}, #{sourceContent,jdbcType=VARCHAR},
  116. #{seq,jdbcType=INTEGER}, #{createTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP}
  117. )
  118. </insert>
  119. <insert id="insertSelective" parameterType="com.tzld.piaoquan.api.model.po.wecom.thirdpart.ThirdPartWeComStaffConfigTaskContent">
  120. insert into third_part_we_com_staff_config_task_content
  121. <trim prefix="(" suffix=")" suffixOverrides=",">
  122. <if test="id != null">
  123. id,
  124. </if>
  125. <if test="taskId != null">
  126. task_id,
  127. </if>
  128. <if test="type != null">
  129. `type`,
  130. </if>
  131. <if test="content != null">
  132. content,
  133. </if>
  134. <if test="source != null">
  135. `source`,
  136. </if>
  137. <if test="sourceContent != null">
  138. source_content,
  139. </if>
  140. <if test="seq != null">
  141. seq,
  142. </if>
  143. <if test="createTime != null">
  144. create_time,
  145. </if>
  146. <if test="updateTime != null">
  147. update_time,
  148. </if>
  149. </trim>
  150. <trim prefix="values (" suffix=")" suffixOverrides=",">
  151. <if test="id != null">
  152. #{id,jdbcType=VARCHAR},
  153. </if>
  154. <if test="taskId != null">
  155. #{taskId,jdbcType=VARCHAR},
  156. </if>
  157. <if test="type != null">
  158. #{type,jdbcType=INTEGER},
  159. </if>
  160. <if test="content != null">
  161. #{content,jdbcType=VARCHAR},
  162. </if>
  163. <if test="source != null">
  164. #{source,jdbcType=INTEGER},
  165. </if>
  166. <if test="sourceContent != null">
  167. #{sourceContent,jdbcType=VARCHAR},
  168. </if>
  169. <if test="seq != null">
  170. #{seq,jdbcType=INTEGER},
  171. </if>
  172. <if test="createTime != null">
  173. #{createTime,jdbcType=TIMESTAMP},
  174. </if>
  175. <if test="updateTime != null">
  176. #{updateTime,jdbcType=TIMESTAMP},
  177. </if>
  178. </trim>
  179. </insert>
  180. <select id="countByExample" parameterType="com.tzld.piaoquan.api.model.po.wecom.thirdpart.ThirdPartWeComStaffConfigTaskContentExample" resultType="java.lang.Long">
  181. select count(*) from third_part_we_com_staff_config_task_content
  182. <if test="_parameter != null">
  183. <include refid="Example_Where_Clause" />
  184. </if>
  185. </select>
  186. <update id="updateByExampleSelective" parameterType="map">
  187. update third_part_we_com_staff_config_task_content
  188. <set>
  189. <if test="record.id != null">
  190. id = #{record.id,jdbcType=VARCHAR},
  191. </if>
  192. <if test="record.taskId != null">
  193. task_id = #{record.taskId,jdbcType=VARCHAR},
  194. </if>
  195. <if test="record.type != null">
  196. `type` = #{record.type,jdbcType=INTEGER},
  197. </if>
  198. <if test="record.content != null">
  199. content = #{record.content,jdbcType=VARCHAR},
  200. </if>
  201. <if test="record.source != null">
  202. `source` = #{record.source,jdbcType=INTEGER},
  203. </if>
  204. <if test="record.sourceContent != null">
  205. source_content = #{record.sourceContent,jdbcType=VARCHAR},
  206. </if>
  207. <if test="record.seq != null">
  208. seq = #{record.seq,jdbcType=INTEGER},
  209. </if>
  210. <if test="record.createTime != null">
  211. create_time = #{record.createTime,jdbcType=TIMESTAMP},
  212. </if>
  213. <if test="record.updateTime != null">
  214. update_time = #{record.updateTime,jdbcType=TIMESTAMP},
  215. </if>
  216. </set>
  217. <if test="_parameter != null">
  218. <include refid="Update_By_Example_Where_Clause" />
  219. </if>
  220. </update>
  221. <update id="updateByExample" parameterType="map">
  222. update third_part_we_com_staff_config_task_content
  223. set id = #{record.id,jdbcType=VARCHAR},
  224. task_id = #{record.taskId,jdbcType=VARCHAR},
  225. `type` = #{record.type,jdbcType=INTEGER},
  226. content = #{record.content,jdbcType=VARCHAR},
  227. `source` = #{record.source,jdbcType=INTEGER},
  228. source_content = #{record.sourceContent,jdbcType=VARCHAR},
  229. seq = #{record.seq,jdbcType=INTEGER},
  230. create_time = #{record.createTime,jdbcType=TIMESTAMP},
  231. update_time = #{record.updateTime,jdbcType=TIMESTAMP}
  232. <if test="_parameter != null">
  233. <include refid="Update_By_Example_Where_Clause" />
  234. </if>
  235. </update>
  236. <update id="updateByPrimaryKeySelective" parameterType="com.tzld.piaoquan.api.model.po.wecom.thirdpart.ThirdPartWeComStaffConfigTaskContent">
  237. update third_part_we_com_staff_config_task_content
  238. <set>
  239. <if test="taskId != null">
  240. task_id = #{taskId,jdbcType=VARCHAR},
  241. </if>
  242. <if test="type != null">
  243. `type` = #{type,jdbcType=INTEGER},
  244. </if>
  245. <if test="content != null">
  246. content = #{content,jdbcType=VARCHAR},
  247. </if>
  248. <if test="source != null">
  249. `source` = #{source,jdbcType=INTEGER},
  250. </if>
  251. <if test="sourceContent != null">
  252. source_content = #{sourceContent,jdbcType=VARCHAR},
  253. </if>
  254. <if test="seq != null">
  255. seq = #{seq,jdbcType=INTEGER},
  256. </if>
  257. <if test="createTime != null">
  258. create_time = #{createTime,jdbcType=TIMESTAMP},
  259. </if>
  260. <if test="updateTime != null">
  261. update_time = #{updateTime,jdbcType=TIMESTAMP},
  262. </if>
  263. </set>
  264. where id = #{id,jdbcType=VARCHAR}
  265. </update>
  266. <update id="updateByPrimaryKey" parameterType="com.tzld.piaoquan.api.model.po.wecom.thirdpart.ThirdPartWeComStaffConfigTaskContent">
  267. update third_part_we_com_staff_config_task_content
  268. set task_id = #{taskId,jdbcType=VARCHAR},
  269. `type` = #{type,jdbcType=INTEGER},
  270. content = #{content,jdbcType=VARCHAR},
  271. `source` = #{source,jdbcType=INTEGER},
  272. source_content = #{sourceContent,jdbcType=VARCHAR},
  273. seq = #{seq,jdbcType=INTEGER},
  274. create_time = #{createTime,jdbcType=TIMESTAMP},
  275. update_time = #{updateTime,jdbcType=TIMESTAMP}
  276. where id = #{id,jdbcType=VARCHAR}
  277. </update>
  278. </mapper>