Guiji_Housingconstruction_Mapper2.xml 7.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197
  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.sooka.mapper.Guiji_Housingconstruction_Mapper2">
  4. <sql id="global_name">
  5. id,create_time,cd_time,cd_batch,cd_operation,cd_source,
  6. </sql>
  7. <sql id="global_value">
  8. #{id},now(),#{cd_time},#{cd_batch},#{cd_operation},#{cd_source},
  9. </sql>
  10. <sql id="update_sql">
  11. create_time = now(),cd_batch = #{cd_batch},cd_operation = #{cd_operation},cd_source =#{cd_source},
  12. </sql>
  13. <parameterMap id="pm_yhjbxx" type="com.sooka.model.bo.Guiji_housingconstruction_yhjjxx_Bean"></parameterMap>
  14. <insert id="add_guiji_housingconstruction_yhjbxx" parameterMap="pm_yhjbxx">
  15. insert into t_guiji_housingconstruction_yhjbxx (
  16. <include refid="global_name"></include>
  17. YHBH,YHMC,YHDZ,YSYF,YSL,SFJF,JFSJ)
  18. values (
  19. <include refid="global_value"></include>
  20. #{YHBH},#{YHMC},#{YHDZ},#{YSYF},#{YSL},#{SFJF},#{JFSJ}
  21. )
  22. </insert>
  23. <update id="update_guiji_housingconstruction_yhjbxx" parameterMap="pm_yhjbxx">
  24. update t_guiji_housingconstruction_yhjbxx
  25. <trim prefix="SET" suffixOverrides=",">
  26. <include refid="update_sql"></include>
  27. <if test="YHBH != null and YHBH != ''">
  28. YHBH = #{YHBH},
  29. </if>
  30. <if test="YHMC != null and YHMC != ''">
  31. YHMC = #{YHMC},
  32. </if>
  33. <if test="YHDZ != null and YHDZ != ''">
  34. YHDZ = #{YHDZ},
  35. </if>
  36. <if test="YSYF != null and YSYF != ''">
  37. YSYF = #{YSYF},
  38. </if>
  39. <if test="YSL != null and YSL != ''">
  40. YSL = #{YSL},
  41. </if>
  42. <if test="SFJF != null and SFJF != ''">
  43. SFJF = #{SFJF},
  44. </if>
  45. <if test="JFSJ != null and JFSJ != ''">
  46. JFSJ = #{JFSJ},
  47. </if>
  48. </trim>
  49. where id = #{id}
  50. </update>
  51. <parameterMap id="pm_ysljc" type="com.sooka.model.bo.Guiji_housingconstruction_ysljc_Bean"></parameterMap>
  52. <insert id="add_guiji_housingconstruction_ysljc" parameterMap="pm_ysljc">
  53. insert into t_guiji_housingconstruction_ysljc (
  54. <include refid="global_name"></include>
  55. name,dnm,snm,value,time
  56. )
  57. values (
  58. <include refid="global_value"></include>
  59. #{name},#{dnm},#{snm},#{value},#{time}
  60. )
  61. </insert>
  62. <update id="update_guiji_housingconstruction_ysljc" parameterMap="pm_ysljc">
  63. update t_guiji_housingconstruction_ysljc
  64. <trim prefix="SET" suffixOverrides=",">
  65. <include refid="update_sql"></include>
  66. <if test="name != null and name != ''">
  67. name = #{name},
  68. </if>
  69. <if test="dnm != null and dnm != ''">
  70. dnm = #{dnm},
  71. </if>
  72. <if test="snm != null and snm != ''">
  73. snm = #{snm},
  74. </if>
  75. <if test="value != null and value != ''">
  76. value = #{value},
  77. </if>
  78. <if test="time != null and time != ''">
  79. time = #{time},
  80. </if>
  81. </trim>
  82. where id=#{id}
  83. </update>
  84. <parameterMap id="pm_zlskfrx" type="com.sooka.model.bo.Guiji_housingconstruction_zlskfrx_Bean"></parameterMap>
  85. <insert id="add_guiji_housingconstruction_zlskfrx" parameterMap="pm_zlskfrx">
  86. insert into t_guiji_housingconstruction_zlskfrx (
  87. <include refid="global_name"></include>
  88. CaseId,IncomingCall,Name,Address,Content,CreateOn)
  89. values (
  90. <include refid="global_value"></include>
  91. #{CaseId},#{IncomingCall},#{Name},#{Address},#{Content},#{CreateOn}
  92. )
  93. </insert>
  94. <update id="update_guiji_housingconstruction_zlskfrx" parameterMap="pm_zlskfrx">
  95. update t_guiji_housingconstruction_zlskfrx
  96. <trim prefix="SET" suffixOverrides=",">
  97. <include refid="update_sql"></include>
  98. <if test="IncomingCall != null and IncomingCall != ''">
  99. IncomingCall= #{IncomingCall},
  100. </if>
  101. <if test="Name != null and Name != ''">
  102. Name= #{Name},
  103. </if>
  104. <if test="Address != null and Address != ''">
  105. Address= #{Address},
  106. </if>
  107. <if test="Content != null and Content != ''">
  108. Content = #{Content},
  109. </if>
  110. <if test="CreateOn != null and CreateOn != ''">
  111. CreateOn = #{CreateOn},
  112. </if>
  113. </trim>
  114. where CaseId = #{CaseId}
  115. </update>
  116. <parameterMap id="pm_ysxt" type="com.sooka.model.bo.Guiji_housingconstruction_ysxt_Bean"></parameterMap>
  117. <insert id="add_guiji_housingconstruction_ysxt" parameterMap="pm_ysxt">
  118. insert into t_guiji_housingconstruction_ysxt (
  119. <include refid="global_name"></include>
  120. YHBH,YHMC,YHDZ,YSYF,YSL,SFJF,JFSJ)
  121. values (
  122. <include refid="global_value"></include>
  123. #{YHBH},#{YHMC},#{YHDZ},#{YSYF},#{YSL},#{SFJF},#{JFSJ}
  124. )
  125. </insert>
  126. <update id="update_guiji_housingconstruction_ysxt" parameterMap="pm_ysxt">
  127. updat t_guiji_housingconstruction_ysxt
  128. <if test="YHBH != null and YHBH != ''">
  129. YHBH = #{YHBH},
  130. </if>
  131. <if test="YHMC != null and YHMC != ''">
  132. YHMC = #{YHMC},
  133. </if>
  134. <if test="YHDZ != null and YHDZ != ''">
  135. YHDZ = #{YHDZ},
  136. </if>
  137. <if test="YSYF != null and YSYF != ''">
  138. YSYF = #{YSYF},
  139. </if>
  140. <if test="YSL != null and YSL != ''">
  141. YSL = #{YSL},
  142. </if>
  143. <if test="SFJF != null and SFJF != ''">
  144. SFJF = #{SFJF},
  145. </if>
  146. <if test="cardno != null and cardno != ''">
  147. JFSJ = #{JFSJ},
  148. </if>
  149. where YHBH = #{YHBH}
  150. </update>
  151. <parameterMap id="pm_hqrlsj" type="com.sooka.model.bo.Guiji_housingconstruction_hqrlsj_Bean"></parameterMap>
  152. <insert id="add_guiji_housingconstruction_hqrlsj" parameterMap="pm_hqrlsj">
  153. insert into t_guiji_housingconstruction_hqrlsj (
  154. <include refid="global_name"></include>
  155. name,time,type)
  156. values (
  157. <include refid="global_value"></include>
  158. #{name},now(),#{type}
  159. )
  160. </insert>
  161. <insert id="add_guiji_housingconstruction_hqrlsj_detail" parameterMap="pm_hqrlsj">
  162. insert into t_guiji_housingconstruction_hqrlsj_detail (
  163. <include refid="global_name"></include>
  164. name,value,hqrlsj_id
  165. )
  166. values (
  167. <include refid="global_value"></include>
  168. #{name},#{value},#{hqrlsj_id}
  169. )
  170. </insert>
  171. <resultMap id="rm_yhjbxx" type="com.sooka.model.bo.Guiji_housingconstruction_yhjjxx_Bean"></resultMap>
  172. <select id="select_guiji_housingconstruction_yhjbxx" parameterMap="pm_yhjbxx" resultMap="rm_yhjbxx">
  173. select
  174. YHBH,YHMC,YHDZ,YSYF,YSL,SFJF,JFSJ from t_guiji_housingconstruction_yhjbxx
  175. where
  176. <if test="YHMC != null and YHMC != ''">
  177. YHMC = #{YHMC}
  178. </if>
  179. </select>
  180. </mapper>