WpMttrAndMtbfDayMapper.xml 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318
  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.gyee.frame.mapper.auto.WpMttrAndMtbfDayMapper">
  4. <resultMap id="BaseResultMap" type="com.gyee.frame.model.auto.WpMttrAndMtbfDay">
  5. <!--
  6. WARNING - @mbg.generated
  7. This element is automatically generated by MyBatis Generator, do not modify.
  8. -->
  9. <id column="ID" jdbcType="VARCHAR" property="id" />
  10. <result column="WPID" jdbcType="VARCHAR" property="wpid" />
  11. <result column="WPNAME" jdbcType="VARCHAR" property="wpname" />
  12. <result column="LOCATION" jdbcType="VARCHAR" property="location" />
  13. <result column="RECORDDATE" jdbcType="TIMESTAMP" property="recorddate" />
  14. <result column="STOPHOURS" jdbcType="DECIMAL" property="stophours" />
  15. <result column="STOPRTIMES" jdbcType="DECIMAL" property="stoprtimes" />
  16. <result column="WTHOURS" jdbcType="DECIMAL" property="wthours" />
  17. </resultMap>
  18. <sql id="Example_Where_Clause">
  19. <!--
  20. WARNING - @mbg.generated
  21. This element is automatically generated by MyBatis Generator, do not modify.
  22. -->
  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. <!--
  53. WARNING - @mbg.generated
  54. This element is automatically generated by MyBatis Generator, do not modify.
  55. -->
  56. <where>
  57. <foreach collection="example.oredCriteria" item="criteria" separator="or">
  58. <if test="criteria.valid">
  59. <trim prefix="(" prefixOverrides="and" suffix=")">
  60. <foreach collection="criteria.criteria" item="criterion">
  61. <choose>
  62. <when test="criterion.noValue">
  63. and ${criterion.condition}
  64. </when>
  65. <when test="criterion.singleValue">
  66. and ${criterion.condition} #{criterion.value}
  67. </when>
  68. <when test="criterion.betweenValue">
  69. and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
  70. </when>
  71. <when test="criterion.listValue">
  72. and ${criterion.condition}
  73. <foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
  74. #{listItem}
  75. </foreach>
  76. </when>
  77. </choose>
  78. </foreach>
  79. </trim>
  80. </if>
  81. </foreach>
  82. </where>
  83. </sql>
  84. <sql id="Base_Column_List">
  85. <!--
  86. WARNING - @mbg.generated
  87. This element is automatically generated by MyBatis Generator, do not modify.
  88. -->
  89. ID, WPID, WPNAME, LOCATION, RECORDDATE, STOPHOURS, STOPRTIMES, WTHOURS
  90. </sql>
  91. <select id="selectByExample" parameterType="com.gyee.frame.model.auto.WpMttrAndMtbfDayExample" resultMap="BaseResultMap">
  92. <!--
  93. WARNING - @mbg.generated
  94. This element is automatically generated by MyBatis Generator, do not modify.
  95. -->
  96. select
  97. <if test="distinct">
  98. distinct
  99. </if>
  100. <include refid="Base_Column_List" />
  101. from WPMTTRANDMTBFDAY
  102. <if test="_parameter != null">
  103. <include refid="Example_Where_Clause" />
  104. </if>
  105. <if test="orderByClause != null">
  106. order by ${orderByClause}
  107. </if>
  108. </select>
  109. <select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
  110. <!--
  111. WARNING - @mbg.generated
  112. This element is automatically generated by MyBatis Generator, do not modify.
  113. -->
  114. select
  115. <include refid="Base_Column_List" />
  116. from WPMTTRANDMTBFDAY
  117. where ID = #{id,jdbcType=VARCHAR}
  118. </select>
  119. <delete id="deleteByPrimaryKey" parameterType="java.lang.String">
  120. <!--
  121. WARNING - @mbg.generated
  122. This element is automatically generated by MyBatis Generator, do not modify.
  123. -->
  124. delete from WPMTTRANDMTBFDAY
  125. where ID = #{id,jdbcType=VARCHAR}
  126. </delete>
  127. <delete id="deleteByExample" parameterType="com.gyee.frame.model.auto.WpMttrAndMtbfDayExample">
  128. <!--
  129. WARNING - @mbg.generated
  130. This element is automatically generated by MyBatis Generator, do not modify.
  131. -->
  132. delete from WPMTTRANDMTBFDAY
  133. <if test="_parameter != null">
  134. <include refid="Example_Where_Clause" />
  135. </if>
  136. </delete>
  137. <insert id="insert" parameterType="com.gyee.frame.model.auto.WpMttrAndMtbfDay">
  138. <!--
  139. WARNING - @mbg.generated
  140. This element is automatically generated by MyBatis Generator, do not modify.
  141. -->
  142. insert into WPMTTRANDMTBFDAY (ID, WPID, WPNAME,
  143. LOCATION, RECORDDATE, STOPHOURS,
  144. STOPRTIMES, WTHOURS)
  145. values (#{id,jdbcType=VARCHAR}, #{wpid,jdbcType=VARCHAR}, #{wpname,jdbcType=VARCHAR},
  146. #{location,jdbcType=VARCHAR}, #{recorddate,jdbcType=TIMESTAMP}, #{stophours,jdbcType=DECIMAL},
  147. #{stoprtimes,jdbcType=DECIMAL}, #{wthours,jdbcType=DECIMAL})
  148. </insert>
  149. <insert id="insertSelective" parameterType="com.gyee.frame.model.auto.WpMttrAndMtbfDay">
  150. <!--
  151. WARNING - @mbg.generated
  152. This element is automatically generated by MyBatis Generator, do not modify.
  153. -->
  154. insert into WPMTTRANDMTBFDAY
  155. <trim prefix="(" suffix=")" suffixOverrides=",">
  156. <if test="id != null">
  157. ID,
  158. </if>
  159. <if test="wpid != null">
  160. WPID,
  161. </if>
  162. <if test="wpname != null">
  163. WPNAME,
  164. </if>
  165. <if test="location != null">
  166. LOCATION,
  167. </if>
  168. <if test="recorddate != null">
  169. RECORDDATE,
  170. </if>
  171. <if test="stophours != null">
  172. STOPHOURS,
  173. </if>
  174. <if test="stoprtimes != null">
  175. STOPRTIMES,
  176. </if>
  177. <if test="wthours != null">
  178. WTHOURS,
  179. </if>
  180. </trim>
  181. <trim prefix="values (" suffix=")" suffixOverrides=",">
  182. <if test="id != null">
  183. #{id,jdbcType=VARCHAR},
  184. </if>
  185. <if test="wpid != null">
  186. #{wpid,jdbcType=VARCHAR},
  187. </if>
  188. <if test="wpname != null">
  189. #{wpname,jdbcType=VARCHAR},
  190. </if>
  191. <if test="location != null">
  192. #{location,jdbcType=VARCHAR},
  193. </if>
  194. <if test="recorddate != null">
  195. #{recorddate,jdbcType=TIMESTAMP},
  196. </if>
  197. <if test="stophours != null">
  198. #{stophours,jdbcType=DECIMAL},
  199. </if>
  200. <if test="stoprtimes != null">
  201. #{stoprtimes,jdbcType=DECIMAL},
  202. </if>
  203. <if test="wthours != null">
  204. #{wthours,jdbcType=DECIMAL},
  205. </if>
  206. </trim>
  207. </insert>
  208. <select id="countByExample" parameterType="com.gyee.frame.model.auto.WpMttrAndMtbfDayExample" resultType="java.lang.Long">
  209. <!--
  210. WARNING - @mbg.generated
  211. This element is automatically generated by MyBatis Generator, do not modify.
  212. -->
  213. select count(*) from WPMTTRANDMTBFDAY
  214. <if test="_parameter != null">
  215. <include refid="Example_Where_Clause" />
  216. </if>
  217. </select>
  218. <update id="updateByExampleSelective" parameterType="map">
  219. <!--
  220. WARNING - @mbg.generated
  221. This element is automatically generated by MyBatis Generator, do not modify.
  222. -->
  223. update WPMTTRANDMTBFDAY
  224. <set>
  225. <if test="record.id != null">
  226. ID = #{record.id,jdbcType=VARCHAR},
  227. </if>
  228. <if test="record.wpid != null">
  229. WPID = #{record.wpid,jdbcType=VARCHAR},
  230. </if>
  231. <if test="record.wpname != null">
  232. WPNAME = #{record.wpname,jdbcType=VARCHAR},
  233. </if>
  234. <if test="record.location != null">
  235. LOCATION = #{record.location,jdbcType=VARCHAR},
  236. </if>
  237. <if test="record.recorddate != null">
  238. RECORDDATE = #{record.recorddate,jdbcType=TIMESTAMP},
  239. </if>
  240. <if test="record.stophours != null">
  241. STOPHOURS = #{record.stophours,jdbcType=DECIMAL},
  242. </if>
  243. <if test="record.stoprtimes != null">
  244. STOPRTIMES = #{record.stoprtimes,jdbcType=DECIMAL},
  245. </if>
  246. <if test="record.wthours != null">
  247. WTHOURS = #{record.wthours,jdbcType=DECIMAL},
  248. </if>
  249. </set>
  250. <if test="_parameter != null">
  251. <include refid="Update_By_Example_Where_Clause" />
  252. </if>
  253. </update>
  254. <update id="updateByExample" parameterType="map">
  255. <!--
  256. WARNING - @mbg.generated
  257. This element is automatically generated by MyBatis Generator, do not modify.
  258. -->
  259. update WPMTTRANDMTBFDAY
  260. set ID = #{record.id,jdbcType=VARCHAR},
  261. WPID = #{record.wpid,jdbcType=VARCHAR},
  262. WPNAME = #{record.wpname,jdbcType=VARCHAR},
  263. LOCATION = #{record.location,jdbcType=VARCHAR},
  264. RECORDDATE = #{record.recorddate,jdbcType=TIMESTAMP},
  265. STOPHOURS = #{record.stophours,jdbcType=DECIMAL},
  266. STOPRTIMES = #{record.stoprtimes,jdbcType=DECIMAL},
  267. WTHOURS = #{record.wthours,jdbcType=DECIMAL}
  268. <if test="_parameter != null">
  269. <include refid="Update_By_Example_Where_Clause" />
  270. </if>
  271. </update>
  272. <update id="updateByPrimaryKeySelective" parameterType="com.gyee.frame.model.auto.WpMttrAndMtbfDay">
  273. <!--
  274. WARNING - @mbg.generated
  275. This element is automatically generated by MyBatis Generator, do not modify.
  276. -->
  277. update WPMTTRANDMTBFDAY
  278. <set>
  279. <if test="wpid != null">
  280. WPID = #{wpid,jdbcType=VARCHAR},
  281. </if>
  282. <if test="wpname != null">
  283. WPNAME = #{wpname,jdbcType=VARCHAR},
  284. </if>
  285. <if test="location != null">
  286. LOCATION = #{location,jdbcType=VARCHAR},
  287. </if>
  288. <if test="recorddate != null">
  289. RECORDDATE = #{recorddate,jdbcType=TIMESTAMP},
  290. </if>
  291. <if test="stophours != null">
  292. STOPHOURS = #{stophours,jdbcType=DECIMAL},
  293. </if>
  294. <if test="stoprtimes != null">
  295. STOPRTIMES = #{stoprtimes,jdbcType=DECIMAL},
  296. </if>
  297. <if test="wthours != null">
  298. WTHOURS = #{wthours,jdbcType=DECIMAL},
  299. </if>
  300. </set>
  301. where ID = #{id,jdbcType=VARCHAR}
  302. </update>
  303. <update id="updateByPrimaryKey" parameterType="com.gyee.frame.model.auto.WpMttrAndMtbfDay">
  304. <!--
  305. WARNING - @mbg.generated
  306. This element is automatically generated by MyBatis Generator, do not modify.
  307. -->
  308. update WPMTTRANDMTBFDAY
  309. set WPID = #{wpid,jdbcType=VARCHAR},
  310. WPNAME = #{wpname,jdbcType=VARCHAR},
  311. LOCATION = #{location,jdbcType=VARCHAR},
  312. RECORDDATE = #{recorddate,jdbcType=TIMESTAMP},
  313. STOPHOURS = #{stophours,jdbcType=DECIMAL},
  314. STOPRTIMES = #{stoprtimes,jdbcType=DECIMAL},
  315. WTHOURS = #{wthours,jdbcType=DECIMAL}
  316. where ID = #{id,jdbcType=VARCHAR}
  317. </update>
  318. </mapper>