From c4d56f4a2c7687739f3bf0f43bcc1f35c9bbeb8b Mon Sep 17 00:00:00 2001 From: liurunyu <lry9898@163.com> Date: 星期三, 14 五月 2025 15:18:44 +0800 Subject: [PATCH] 1、表阀一体协议解析同步新版本;2、默认设备是表阀一体(0x02) --- pipIrr-platform/pipIrr-global/src/main/resources/mapper/PrIntakeMapper.xml | 26 +++++++++++++++----------- 1 files changed, 15 insertions(+), 11 deletions(-) diff --git a/pipIrr-platform/pipIrr-global/src/main/resources/mapper/PrIntakeMapper.xml b/pipIrr-platform/pipIrr-global/src/main/resources/mapper/PrIntakeMapper.xml index c4b2f4f..01b3bcf 100644 --- a/pipIrr-platform/pipIrr-global/src/main/resources/mapper/PrIntakeMapper.xml +++ b/pipIrr-platform/pipIrr-global/src/main/resources/mapper/PrIntakeMapper.xml @@ -50,17 +50,19 @@ ge.`operator`, ge.operateDt, blo.`name` AS blockName, - CONCAT(country.`name`, town.`name`, village.`name`) AS address + CONCAT(country.`name`, town.`name`, village.`name`) AS address, + con.id AS controllerId, + con.rtuAddr, + con.protocol FROM pr_intake ge - INNER JOIN pr_divide divi ON ge.divideId = divi.id - INNER JOIN ba_block blo ON divi.blockId = blo.id + LEFT JOIN pr_divide divi ON ge.divideId = divi.id + LEFT JOIN ba_block blo ON divi.blockId = blo.id LEFT JOIN ba_district country ON ge.countyId = country.id LEFT JOIN ba_district town ON ge.townId = town.id LEFT JOIN ba_district village ON ge.villageId = village.id + LEFT JOIN pr_controller con ON con.intakeId = ge.id where ge.id = #{id,jdbcType=BIGINT} AND ge.deleted = 0 - AND divi.deleted = 0 - AND blo.deleted = 0 </select> <delete id="deleteLogicById" parameterType="java.lang.Long"> @@ -378,7 +380,7 @@ AND bindNumTb.num = #{bindNumber} </if> </where> - ORDER BY ge.operateDt DESC + ORDER BY ge.divideId DESC, ge.id DESC <trim prefix="limit "> <if test="start != null and count != null"> #{start,javaType=Integer,jdbcType=INTEGER}, #{count,javaType=Integer,jdbcType=INTEGER} @@ -593,7 +595,9 @@ SELECT inta.id AS intakeId, con.rtuAddr, - inta.name AS intakeNum, + con.protocol, + con.protocol_version AS protocolVersion, + inta.name AS intakeNum, inta.lng, inta.lat, IFNULL(hou.instant_amount, 0) AS instantAmount, @@ -774,8 +778,8 @@ FROM pr_intake tb <where> tb.deleted = 0 - <if test="intakeName != null and intakeName != ''"> - AND tb.name LIKE CONCAT('%', #{intakeName}) + <if test="intakeNum != null and intakeNum != ''"> + AND tb.name LIKE CONCAT('%', #{intakeNum}) </if> </where> </select> @@ -790,8 +794,8 @@ INNER JOIN pr_controller con ON con.intakeId = inta.id <where> inta.deleted = 0 - <if test="intakeName != null and intakeName != ''"> - AND inta.name LIKE CONCAT('%', #{intakeName}) + <if test="intakeNum != null and intakeNum != ''"> + AND inta.name LIKE CONCAT('%', #{intakeNum}) </if> </where> ORDER BY inta.id DESC -- Gitblit v1.8.0