PdmBranchLineMapper.xml 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323
  1. <?xml version="1.0" encoding="UTF-8" ?>
  2. <!DOCTYPE mapper
  3. PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
  4. "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
  5. <mapper namespace="com.ruoyi.powerdistribution.mapper.PdmBranchLineMapper">
  6. <resultMap type="PdmBranchLine" id="PdmBranchLineResult">
  7. <result property="id" column="id" />
  8. <result property="bigFeederBranchLineId" column="big_feeder_branch_line_id" />
  9. <result property="lineNm" column="line_nm" />
  10. <result property="eqpNo" column="eqp_no" />
  11. <result property="runNo" column="run_no" />
  12. <result property="blgBigFeederId" column="blg_big_feeder_id" />
  13. <result property="blgBigFeederNm" column="blg_big_feeder_nm" />
  14. <result property="voltLvlCd" column="volt_lvl_cd" />
  15. <result property="voltLvlDsc" column="volt_lvl_dsc" />
  16. <result property="erectModeCd" column="erect_mode_cd" />
  17. <result property="erectModeDsc" column="erect_mode_dsc" />
  18. <result property="overhdLineLen" column="overhd_line_len" />
  19. <result property="cableLineLen" column="cable_line_len" />
  20. <result property="lineTolLen" column="line_tol_len" />
  21. <result property="startEqpId" column="start_eqp_id" />
  22. <result property="startEqpNm" column="start_eqp_nm" />
  23. <result property="startEqpTypCd" column="start_eqp_typ_cd" />
  24. <result property="startEqpTypDsc" column="start_eqp_typ_dsc" />
  25. <result property="lineNatureCd" column="line_nature_cd" />
  26. <result property="lineNatureDsc" column="line_nature_dsc" />
  27. <result property="blgSuperLineId" column="blg_super_line_id" />
  28. <result property="blgSuperLineNm" column="blg_super_line_nm" />
  29. <result property="blgCityId" column="blg_city_id" />
  30. <result property="blgCityNm" column="blg_city_nm" />
  31. <result property="opMaintOrgId" column="op_maint_org_id" />
  32. <result property="opMaintOrgNm" column="op_maint_org_nm" />
  33. <result property="maintTeamId" column="maint_team_id" />
  34. <result property="maintTeamNm" column="maint_team_nm" />
  35. <result property="runStCd" column="run_st_cd" />
  36. <result property="runStDsc" column="run_st_dsc" />
  37. <result property="releaseStDsc" column="release_st_dsc" />
  38. <result property="repmaintLineLen" column="repmaint_line_len" />
  39. <result property="isHaveFigur" column="is_have_figur" />
  40. <result property="stdEqpMasterId" column="std_eqp_master_id" />
  41. <result property="stdEqpMasterNm" column="std_eqp_master_nm" />
  42. <result property="shipDt" column="ship_dt" />
  43. <result property="stdOrgNo" column="std_org_no" />
  44. <result property="stdOrgNm" column="std_org_nm" />
  45. <result property="stdCityOrgNm" column="std_city_org_nm" />
  46. <result property="stdCountyOrgNo" column="std_county_org_no" />
  47. <result property="stdCountyOrgNm" column="std_county_org_nm" />
  48. <result property="dataDt" column="data_dt" />
  49. <result property="etlTm" column="etl_tm" />
  50. <result property="stdCityOrgNo" column="std_city_org_no" />
  51. <result property="startPos" column="start_pos" />
  52. <result property="eqpMasterId" column="eqp_master_id" />
  53. <result property="eqpMasterNm" column="eqp_master_nm" />
  54. <result property="battalionId" column="battalion_id" />
  55. <result property="battalionNm" column="battalion_nm" />
  56. <result property="retrogresDt" column="retrogres_dt" />
  57. <result property="createTm" column="create_tm" />
  58. <result property="latestUpdTm" column="latest_upd_tm" />
  59. <result property="rewardAmount" column="reward_amount" />
  60. <result property="faultFreeDuration" column="fault_free_duration" />
  61. <result property="poweroffNum" column="poweroff_num" />
  62. </resultMap>
  63. <sql id="selectPdmBranchLineVo">
  64. select id, big_feeder_branch_line_id, line_nm, eqp_no, run_no, blg_big_feeder_id, blg_big_feeder_nm, volt_lvl_cd, volt_lvl_dsc, erect_mode_cd, erect_mode_dsc, overhd_line_len, cable_line_len, line_tol_len, start_eqp_id, start_eqp_nm, start_eqp_typ_cd, start_eqp_typ_dsc, line_nature_cd, line_nature_dsc, blg_super_line_id, blg_super_line_nm, blg_city_id, blg_city_nm, op_maint_org_id, op_maint_org_nm, maint_team_id, maint_team_nm, run_st_cd, run_st_dsc, release_st_dsc, repmaint_line_len, is_have_figur, std_eqp_master_id, std_eqp_master_nm, ship_dt, std_org_no, std_org_nm, SUBSTRING_INDEX(std_city_org_nm, '国网湖南省电力有限公司', -1)std_city_org_nm , std_county_org_no, SUBSTRING_INDEX(std_county_org_nm, '国网湖南省电力有限公司', -1)std_county_org_nm, data_dt, etl_tm, std_city_org_no, start_pos, eqp_master_id, eqp_master_nm, battalion_id, battalion_nm, retrogres_dt, create_tm, latest_upd_tm,bouns as reward_amount,fault_free_duration
  65. , (SELECT count(1) from ads_cst_hygszdbb_pdmstopbranchrecords_df t1 where t1.branch_line_id=t.big_feeder_branch_line_id and poweroff_start_tm > DATE_SUB(NOW(), INTERVAL 1 YEAR) )poweroff_num,
  66. t.fault_poweroff_tm,t.poweroff_tm
  67. from pdm_branch_line t
  68. </sql>
  69. <select id="selectPdmBranchLineList" parameterType="PdmBranchLine" resultMap="PdmBranchLineResult">
  70. <include refid="selectPdmBranchLineVo"/>
  71. <where>
  72. <if test="bigFeederBranchLineId != null and bigFeederBranchLineId != ''"> and big_feeder_branch_line_id = #{bigFeederBranchLineId}</if>
  73. <if test="lineNm != null and lineNm != ''"> and line_nm = #{lineNm}</if>
  74. <if test="eqpNo != null and eqpNo != ''"> and eqp_no = #{eqpNo}</if>
  75. <if test="runNo != null and runNo != ''"> and run_no = #{runNo}</if>
  76. <if test="blgBigFeederId != null and blgBigFeederId != ''"> and blg_big_feeder_id = #{blgBigFeederId}</if>
  77. <if test="blgBigFeederNm != null and blgBigFeederNm != ''"> and blg_big_feeder_nm = #{blgBigFeederNm}</if>
  78. <if test="voltLvlCd != null and voltLvlCd != ''"> and volt_lvl_cd = #{voltLvlCd}</if>
  79. <if test="voltLvlDsc != null and voltLvlDsc != ''"> and volt_lvl_dsc = #{voltLvlDsc}</if>
  80. <if test="erectModeCd != null and erectModeCd != ''"> and erect_mode_cd = #{erectModeCd}</if>
  81. <if test="erectModeDsc != null and erectModeDsc != ''"> and erect_mode_dsc = #{erectModeDsc}</if>
  82. <if test="overhdLineLen != null "> and overhd_line_len = #{overhdLineLen}</if>
  83. <if test="cableLineLen != null "> and cable_line_len = #{cableLineLen}</if>
  84. <if test="lineTolLen != null "> and line_tol_len = #{lineTolLen}</if>
  85. <if test="startEqpId != null and startEqpId != ''"> and start_eqp_id = #{startEqpId}</if>
  86. <if test="startEqpNm != null and startEqpNm != ''"> and start_eqp_nm = #{startEqpNm}</if>
  87. <if test="startEqpTypCd != null and startEqpTypCd != ''"> and start_eqp_typ_cd = #{startEqpTypCd}</if>
  88. <if test="startEqpTypDsc != null and startEqpTypDsc != ''"> and start_eqp_typ_dsc = #{startEqpTypDsc}</if>
  89. <if test="lineNatureCd != null and lineNatureCd != ''"> and line_nature_cd = #{lineNatureCd}</if>
  90. <if test="lineNatureDsc != null and lineNatureDsc != ''"> and line_nature_dsc = #{lineNatureDsc}</if>
  91. <if test="blgSuperLineId != null and blgSuperLineId != ''"> and blg_super_line_id = #{blgSuperLineId}</if>
  92. <if test="blgSuperLineNm != null and blgSuperLineNm != ''"> and blg_super_line_nm = #{blgSuperLineNm}</if>
  93. <if test="blgCityId != null and blgCityId != ''"> and blg_city_id = #{blgCityId}</if>
  94. <if test="blgCityNm != null and blgCityNm != ''"> and blg_city_nm = #{blgCityNm}</if>
  95. <if test="opMaintOrgId != null and opMaintOrgId != ''"> and op_maint_org_id = #{opMaintOrgId}</if>
  96. <if test="opMaintOrgNm != null and opMaintOrgNm != ''"> and op_maint_org_nm = #{opMaintOrgNm}</if>
  97. <if test="maintTeamId != null and maintTeamId != ''"> and maint_team_id = #{maintTeamId}</if>
  98. <if test="maintTeamNm != null and maintTeamNm != ''"> and maint_team_nm = #{maintTeamNm}</if>
  99. <if test="runStCd != null and runStCd != ''"> and run_st_cd = #{runStCd}</if>
  100. <if test="runStDsc != null and runStDsc != ''"> and run_st_dsc = #{runStDsc}</if>
  101. <if test="releaseStDsc != null and releaseStDsc != ''"> and release_st_dsc = #{releaseStDsc}</if>
  102. <if test="repmaintLineLen != null "> and repmaint_line_len = #{repmaintLineLen}</if>
  103. <if test="isHaveFigur != null and isHaveFigur != ''"> and is_have_figur = #{isHaveFigur}</if>
  104. <if test="stdEqpMasterId != null and stdEqpMasterId != ''"> and std_eqp_master_id = #{stdEqpMasterId}</if>
  105. <if test="stdEqpMasterNm != null and stdEqpMasterNm != ''"> and std_eqp_master_nm = #{stdEqpMasterNm}</if>
  106. <if test="shipDt != null and shipDt != ''"> and ship_dt = #{shipDt}</if>
  107. <if test="stdOrgNo != null and stdOrgNo != ''"> and std_org_no = #{stdOrgNo}</if>
  108. <if test="stdOrgNm != null and stdOrgNm != ''"> and std_org_nm = #{stdOrgNm}</if>
  109. <if test="stdCityOrgNm != null and stdCityOrgNm != ''"> and std_city_org_nm = #{stdCityOrgNm}</if>
  110. <if test="stdCountyOrgNo != null and stdCountyOrgNo != ''"> and std_county_org_no = #{stdCountyOrgNo}</if>
  111. <if test="stdCountyOrgNm != null and stdCountyOrgNm != ''"> and std_county_org_nm = #{stdCountyOrgNm}</if>
  112. <if test="dataDt != null and dataDt != ''"> and data_dt = #{dataDt}</if>
  113. <if test="etlTm != null "> and etl_tm = #{etlTm}</if>
  114. <if test="stdCityOrgNo != null and stdCityOrgNo != ''"> and std_city_org_no = #{stdCityOrgNo}</if>
  115. <if test="startPos != null and startPos != ''"> and start_pos = #{startPos}</if>
  116. <if test="eqpMasterId != null and eqpMasterId != ''"> and eqp_master_id = #{eqpMasterId}</if>
  117. <if test="eqpMasterNm != null and eqpMasterNm != ''"> and eqp_master_nm = #{eqpMasterNm}</if>
  118. <if test="battalionId != null and battalionId != ''"> and battalion_id = #{battalionId}</if>
  119. <if test="battalionNm != null and battalionNm != ''"> and battalion_nm = #{battalionNm}</if>
  120. <if test="retrogresDt != null "> and retrogres_dt = #{retrogresDt}</if>
  121. <if test="createTm != null "> and create_tm = #{createTm}</if>
  122. <if test="latestUpdTm != null "> and latest_upd_tm = #{latestUpdTm}</if>
  123. </where>
  124. </select>
  125. <select id="selectPdmBranchLineById" parameterType="Long" resultMap="PdmBranchLineResult">
  126. <include refid="selectPdmBranchLineVo"/>
  127. where id = #{id}
  128. </select>
  129. <insert id="insertPdmBranchLine" parameterType="PdmBranchLine" useGeneratedKeys="true" keyProperty="id">
  130. insert into pdm_branch_line
  131. <trim prefix="(" suffix=")" suffixOverrides=",">
  132. <if test="bigFeederBranchLineId != null">big_feeder_branch_line_id,</if>
  133. <if test="lineNm != null">line_nm,</if>
  134. <if test="eqpNo != null">eqp_no,</if>
  135. <if test="runNo != null">run_no,</if>
  136. <if test="blgBigFeederId != null">blg_big_feeder_id,</if>
  137. <if test="blgBigFeederNm != null">blg_big_feeder_nm,</if>
  138. <if test="voltLvlCd != null">volt_lvl_cd,</if>
  139. <if test="voltLvlDsc != null">volt_lvl_dsc,</if>
  140. <if test="erectModeCd != null">erect_mode_cd,</if>
  141. <if test="erectModeDsc != null">erect_mode_dsc,</if>
  142. <if test="overhdLineLen != null">overhd_line_len,</if>
  143. <if test="cableLineLen != null">cable_line_len,</if>
  144. <if test="lineTolLen != null">line_tol_len,</if>
  145. <if test="startEqpId != null">start_eqp_id,</if>
  146. <if test="startEqpNm != null">start_eqp_nm,</if>
  147. <if test="startEqpTypCd != null">start_eqp_typ_cd,</if>
  148. <if test="startEqpTypDsc != null">start_eqp_typ_dsc,</if>
  149. <if test="lineNatureCd != null">line_nature_cd,</if>
  150. <if test="lineNatureDsc != null">line_nature_dsc,</if>
  151. <if test="blgSuperLineId != null">blg_super_line_id,</if>
  152. <if test="blgSuperLineNm != null">blg_super_line_nm,</if>
  153. <if test="blgCityId != null">blg_city_id,</if>
  154. <if test="blgCityNm != null">blg_city_nm,</if>
  155. <if test="opMaintOrgId != null">op_maint_org_id,</if>
  156. <if test="opMaintOrgNm != null">op_maint_org_nm,</if>
  157. <if test="maintTeamId != null">maint_team_id,</if>
  158. <if test="maintTeamNm != null">maint_team_nm,</if>
  159. <if test="runStCd != null">run_st_cd,</if>
  160. <if test="runStDsc != null">run_st_dsc,</if>
  161. <if test="releaseStDsc != null">release_st_dsc,</if>
  162. <if test="repmaintLineLen != null">repmaint_line_len,</if>
  163. <if test="isHaveFigur != null">is_have_figur,</if>
  164. <if test="stdEqpMasterId != null">std_eqp_master_id,</if>
  165. <if test="stdEqpMasterNm != null">std_eqp_master_nm,</if>
  166. <if test="shipDt != null">ship_dt,</if>
  167. <if test="stdOrgNo != null">std_org_no,</if>
  168. <if test="stdOrgNm != null">std_org_nm,</if>
  169. <if test="stdCityOrgNm != null">std_city_org_nm,</if>
  170. <if test="stdCountyOrgNo != null">std_county_org_no,</if>
  171. <if test="stdCountyOrgNm != null">std_county_org_nm,</if>
  172. <if test="dataDt != null">data_dt,</if>
  173. <if test="etlTm != null">etl_tm,</if>
  174. <if test="stdCityOrgNo != null">std_city_org_no,</if>
  175. <if test="startPos != null">start_pos,</if>
  176. <if test="eqpMasterId != null">eqp_master_id,</if>
  177. <if test="eqpMasterNm != null">eqp_master_nm,</if>
  178. <if test="battalionId != null">battalion_id,</if>
  179. <if test="battalionNm != null">battalion_nm,</if>
  180. <if test="retrogresDt != null">retrogres_dt,</if>
  181. <if test="createTm != null">create_tm,</if>
  182. <if test="latestUpdTm != null">latest_upd_tm,</if>
  183. </trim>
  184. <trim prefix="values (" suffix=")" suffixOverrides=",">
  185. <if test="bigFeederBranchLineId != null">#{bigFeederBranchLineId},</if>
  186. <if test="lineNm != null">#{lineNm},</if>
  187. <if test="eqpNo != null">#{eqpNo},</if>
  188. <if test="runNo != null">#{runNo},</if>
  189. <if test="blgBigFeederId != null">#{blgBigFeederId},</if>
  190. <if test="blgBigFeederNm != null">#{blgBigFeederNm},</if>
  191. <if test="voltLvlCd != null">#{voltLvlCd},</if>
  192. <if test="voltLvlDsc != null">#{voltLvlDsc},</if>
  193. <if test="erectModeCd != null">#{erectModeCd},</if>
  194. <if test="erectModeDsc != null">#{erectModeDsc},</if>
  195. <if test="overhdLineLen != null">#{overhdLineLen},</if>
  196. <if test="cableLineLen != null">#{cableLineLen},</if>
  197. <if test="lineTolLen != null">#{lineTolLen},</if>
  198. <if test="startEqpId != null">#{startEqpId},</if>
  199. <if test="startEqpNm != null">#{startEqpNm},</if>
  200. <if test="startEqpTypCd != null">#{startEqpTypCd},</if>
  201. <if test="startEqpTypDsc != null">#{startEqpTypDsc},</if>
  202. <if test="lineNatureCd != null">#{lineNatureCd},</if>
  203. <if test="lineNatureDsc != null">#{lineNatureDsc},</if>
  204. <if test="blgSuperLineId != null">#{blgSuperLineId},</if>
  205. <if test="blgSuperLineNm != null">#{blgSuperLineNm},</if>
  206. <if test="blgCityId != null">#{blgCityId},</if>
  207. <if test="blgCityNm != null">#{blgCityNm},</if>
  208. <if test="opMaintOrgId != null">#{opMaintOrgId},</if>
  209. <if test="opMaintOrgNm != null">#{opMaintOrgNm},</if>
  210. <if test="maintTeamId != null">#{maintTeamId},</if>
  211. <if test="maintTeamNm != null">#{maintTeamNm},</if>
  212. <if test="runStCd != null">#{runStCd},</if>
  213. <if test="runStDsc != null">#{runStDsc},</if>
  214. <if test="releaseStDsc != null">#{releaseStDsc},</if>
  215. <if test="repmaintLineLen != null">#{repmaintLineLen},</if>
  216. <if test="isHaveFigur != null">#{isHaveFigur},</if>
  217. <if test="stdEqpMasterId != null">#{stdEqpMasterId},</if>
  218. <if test="stdEqpMasterNm != null">#{stdEqpMasterNm},</if>
  219. <if test="shipDt != null">#{shipDt},</if>
  220. <if test="stdOrgNo != null">#{stdOrgNo},</if>
  221. <if test="stdOrgNm != null">#{stdOrgNm},</if>
  222. <if test="stdCityOrgNm != null">#{stdCityOrgNm},</if>
  223. <if test="stdCountyOrgNo != null">#{stdCountyOrgNo},</if>
  224. <if test="stdCountyOrgNm != null">#{stdCountyOrgNm},</if>
  225. <if test="dataDt != null">#{dataDt},</if>
  226. <if test="etlTm != null">#{etlTm},</if>
  227. <if test="stdCityOrgNo != null">#{stdCityOrgNo},</if>
  228. <if test="startPos != null">#{startPos},</if>
  229. <if test="eqpMasterId != null">#{eqpMasterId},</if>
  230. <if test="eqpMasterNm != null">#{eqpMasterNm},</if>
  231. <if test="battalionId != null">#{battalionId},</if>
  232. <if test="battalionNm != null">#{battalionNm},</if>
  233. <if test="retrogresDt != null">#{retrogresDt},</if>
  234. <if test="createTm != null">#{createTm},</if>
  235. <if test="latestUpdTm != null">#{latestUpdTm},</if>
  236. </trim>
  237. </insert>
  238. <update id="updatePdmBranchLine" parameterType="PdmBranchLine">
  239. update pdm_branch_line
  240. <trim prefix="SET" suffixOverrides=",">
  241. <if test="bigFeederBranchLineId != null">big_feeder_branch_line_id = #{bigFeederBranchLineId},</if>
  242. <if test="lineNm != null">line_nm = #{lineNm},</if>
  243. <if test="eqpNo != null">eqp_no = #{eqpNo},</if>
  244. <if test="runNo != null">run_no = #{runNo},</if>
  245. <if test="blgBigFeederId != null">blg_big_feeder_id = #{blgBigFeederId},</if>
  246. <if test="blgBigFeederNm != null">blg_big_feeder_nm = #{blgBigFeederNm},</if>
  247. <if test="voltLvlCd != null">volt_lvl_cd = #{voltLvlCd},</if>
  248. <if test="voltLvlDsc != null">volt_lvl_dsc = #{voltLvlDsc},</if>
  249. <if test="erectModeCd != null">erect_mode_cd = #{erectModeCd},</if>
  250. <if test="erectModeDsc != null">erect_mode_dsc = #{erectModeDsc},</if>
  251. <if test="overhdLineLen != null">overhd_line_len = #{overhdLineLen},</if>
  252. <if test="cableLineLen != null">cable_line_len = #{cableLineLen},</if>
  253. <if test="lineTolLen != null">line_tol_len = #{lineTolLen},</if>
  254. <if test="startEqpId != null">start_eqp_id = #{startEqpId},</if>
  255. <if test="startEqpNm != null">start_eqp_nm = #{startEqpNm},</if>
  256. <if test="startEqpTypCd != null">start_eqp_typ_cd = #{startEqpTypCd},</if>
  257. <if test="startEqpTypDsc != null">start_eqp_typ_dsc = #{startEqpTypDsc},</if>
  258. <if test="lineNatureCd != null">line_nature_cd = #{lineNatureCd},</if>
  259. <if test="lineNatureDsc != null">line_nature_dsc = #{lineNatureDsc},</if>
  260. <if test="blgSuperLineId != null">blg_super_line_id = #{blgSuperLineId},</if>
  261. <if test="blgSuperLineNm != null">blg_super_line_nm = #{blgSuperLineNm},</if>
  262. <if test="blgCityId != null">blg_city_id = #{blgCityId},</if>
  263. <if test="blgCityNm != null">blg_city_nm = #{blgCityNm},</if>
  264. <if test="opMaintOrgId != null">op_maint_org_id = #{opMaintOrgId},</if>
  265. <if test="opMaintOrgNm != null">op_maint_org_nm = #{opMaintOrgNm},</if>
  266. <if test="maintTeamId != null">maint_team_id = #{maintTeamId},</if>
  267. <if test="maintTeamNm != null">maint_team_nm = #{maintTeamNm},</if>
  268. <if test="runStCd != null">run_st_cd = #{runStCd},</if>
  269. <if test="runStDsc != null">run_st_dsc = #{runStDsc},</if>
  270. <if test="releaseStDsc != null">release_st_dsc = #{releaseStDsc},</if>
  271. <if test="repmaintLineLen != null">repmaint_line_len = #{repmaintLineLen},</if>
  272. <if test="isHaveFigur != null">is_have_figur = #{isHaveFigur},</if>
  273. <if test="stdEqpMasterId != null">std_eqp_master_id = #{stdEqpMasterId},</if>
  274. <if test="stdEqpMasterNm != null">std_eqp_master_nm = #{stdEqpMasterNm},</if>
  275. <if test="shipDt != null">ship_dt = #{shipDt},</if>
  276. <if test="stdOrgNo != null">std_org_no = #{stdOrgNo},</if>
  277. <if test="stdOrgNm != null">std_org_nm = #{stdOrgNm},</if>
  278. <if test="stdCityOrgNm != null">std_city_org_nm = #{stdCityOrgNm},</if>
  279. <if test="stdCountyOrgNo != null">std_county_org_no = #{stdCountyOrgNo},</if>
  280. <if test="stdCountyOrgNm != null">std_county_org_nm = #{stdCountyOrgNm},</if>
  281. <if test="dataDt != null">data_dt = #{dataDt},</if>
  282. <if test="etlTm != null">etl_tm = #{etlTm},</if>
  283. <if test="stdCityOrgNo != null">std_city_org_no = #{stdCityOrgNo},</if>
  284. <if test="startPos != null">start_pos = #{startPos},</if>
  285. <if test="eqpMasterId != null">eqp_master_id = #{eqpMasterId},</if>
  286. <if test="eqpMasterNm != null">eqp_master_nm = #{eqpMasterNm},</if>
  287. <if test="battalionId != null">battalion_id = #{battalionId},</if>
  288. <if test="battalionNm != null">battalion_nm = #{battalionNm},</if>
  289. <if test="retrogresDt != null">retrogres_dt = #{retrogresDt},</if>
  290. <if test="createTm != null">create_tm = #{createTm},</if>
  291. <if test="latestUpdTm != null">latest_upd_tm = #{latestUpdTm},</if>
  292. </trim>
  293. where id = #{id}
  294. </update>
  295. <delete id="deletePdmBranchLineById" parameterType="Long">
  296. delete from pdm_branch_line where id = #{id}
  297. </delete>
  298. <delete id="deletePdmBranchLineByIds" parameterType="String">
  299. delete from pdm_branch_line where id in
  300. <foreach item="id" collection="array" open="(" separator="," close=")">
  301. #{id}
  302. </foreach>
  303. </delete>
  304. <select id="selectBranchLineCompleteList" parameterType="com.ruoyi.powerdistribution.domain.vo.PdmBranchLineComplete" resultType="com.ruoyi.powerdistribution.domain.PdmBranchLine">
  305. <include refid="selectPdmBranchLineVo"/>
  306. <where>
  307. <if test="lineNm != null and lineNm != ''"> and line_nm like concat('%', #{lineNm}, '%')</if>
  308. <if test="eqpNo != null and eqpNo != ''"> and eqp_no = #{eqpNo}</if>
  309. <if test="runNo != null and runNo != ''"> and run_no = #{runNo}</if>
  310. <if test="blgBigFeederId != null and blgBigFeederId != ''"> and blg_big_feeder_id = #{blgBigFeederId}</if>
  311. <if test="blgBigFeederNm != null and blgBigFeederNm != ''"> and blg_big_feeder_nm = #{blgBigFeederNm}</if>
  312. </where>
  313. </select>
  314. </mapper>