From 0da2c08f679cb546fab3a0a7c3d6ff472bb87a8c Mon Sep 17 00:00:00 2001
From: liurunyu <lry9898@163.com>
Date: 星期一, 28 十月 2024 21:24:41 +0800
Subject: [PATCH] Merge branch 'master' of http://8.140.179.55:20000/r/pipIrr-SV
---
pipIrr-platform/pipIrr-web/pipIrr-web-sell/src/main/java/com/dy/pipIrrSell/client/QueryVo.java | 5 +
pipIrr-platform/pipIrr-global/src/main/resources/mapper/SeClientMapper.xml | 41 +++++++++----
pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/voSe/VoClient.java | 120 +++++++++++++++++++++++++++++----------
3 files changed, 121 insertions(+), 45 deletions(-)
diff --git a/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/voSe/VoClient.java b/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/voSe/VoClient.java
index 361fc6c..95b72e8 100644
--- a/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/voSe/VoClient.java
+++ b/pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/voSe/VoClient.java
@@ -1,7 +1,10 @@
package com.dy.pipIrrGlobal.voSe;
+import com.alibaba.fastjson2.annotation.JSONField;
+import com.alibaba.fastjson2.writer.ObjectWriterImplToString;
import com.dy.common.po.BaseEntity;
import com.fasterxml.jackson.annotation.JsonFormat;
+import com.fasterxml.jackson.annotation.JsonPropertyOrder;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
@@ -12,70 +15,125 @@
* @author ZhuBaoMin
* @date 2023/12/22 11:43
* @LastEditTime 2023/12/22 11:43
- * @Description
+ * @Description 鍐滄埛瑙嗗浘瀵硅薄
*/
@Data
-@Schema(title = "鍐滄埛瑙嗗浘瀵硅薄")
+@JsonPropertyOrder({"countyId","countryName","townId","townName","villageId","villageName","blockId","blockName","divideId","divideName","typeId","waterTypeName","clientId","name","clientNum","phone","idCard","area","cardCount","address","remarks","operateDt"})
public class VoClient implements BaseEntity {
- private static final long serialVersionUID = 1L;
+ private static final long serialVersionUID = 202410282047001L;
- @Schema(title = "鍘縄D")
- private String countyId;
- @Schema(title = "鍘垮悕绉�")
+ /**
+ * 鍘縄D
+ */
+ @JSONField(serializeUsing= ObjectWriterImplToString.class)
+ private Long countyId;
+
+ /**
+ * 鍘垮悕绉�
+ */
private String countryName;
- @Schema(title = "闀嘔D")
- private String townId;
- @Schema(title = "闀囧悕绉�")
+ /**
+ * 闀嘔D
+ */
+ @JSONField(serializeUsing= ObjectWriterImplToString.class)
+ private Long townId;
+
+ /**
+ * 闀囧悕绉�
+ */
private String townName;
- @Schema(title = "鏉慖D")
- private String villageId;
- @Schema(title = "鏉戝悕绉�")
+ /**
+ * 鏉慖D
+ */
+ @JSONField(serializeUsing= ObjectWriterImplToString.class)
+ private Long villageId;
+
+ /**
+ * 鏉戝悕绉�
+ */
private String villageName;
- @Schema(title = "鐗囧尯ID")
- private String blockId;
- @Schema(title = "鐗囧尯鍚嶇О")
+ /**
+ * 鐗囧尯ID
+ */
+ @JSONField(serializeUsing= ObjectWriterImplToString.class)
+ private Long blockId;
+
+ /**
+ * 鐗囧尯鍚嶇О
+ */
private String blockName;
- @Schema(title = "鍒嗘按鎴縄D")
- private String divideId;
- @Schema(title = "鍒嗘按鎴垮悕绉�")
+ /**
+ * 鍒嗘按鎴縄D
+ */
+ @JSONField(serializeUsing= ObjectWriterImplToString.class)
+ private Long divideId;
+
+ /**
+ * 鍒嗘按鎴垮悕绉�
+ */
private String divideName;
- @Schema(title = "鐢ㄦ埛绫诲瀷ID")
- private String typeId;
- @Schema(title = "鐢ㄦ埛绫诲瀷鍚嶇О")
+ /**
+ * 鐢ㄦ埛绫诲瀷ID
+ */
+ @JSONField(serializeUsing= ObjectWriterImplToString.class)
+ private Long typeId;
+
+ /**
+ * 鐢ㄦ埛绫诲瀷鍚嶇О
+ */
private String waterTypeName;
- @Schema(title = "鍐滄埛ID")
- private String clientId;
+ /**
+ * 鍐滄埛ID
+ */
+ @JSONField(serializeUsing= ObjectWriterImplToString.class)
+ private Long clientId;
- @Schema(title = "鍐滄埛濮撳悕")
+ /**
+ * 鍐滄埛濮撳悕
+ */
private String name;
- @Schema(title = "鍐滄埛缂栧彿")
+ /**
+ * 鍐滄埛缂栧彿
+ */
private String clientNum;
- @Schema(title = "鎵嬫満鍙�")
+ /**
+ * 鎵嬫満鍙�
+ */
private String phone;
- @Schema(title = "韬唤璇佸彿")
+ /**
+ * 韬唤璇佸彿
+ */
private String idCard;
- @Schema(title = "绉嶆闈㈢Н")
+ /**
+ * 绉嶆闈㈢Н
+ */
private Double area;
- @Schema(title = "鍗$墖鏁伴噺")
+ /**
+ * 鍗$墖鏁伴噺
+ */
private Integer cardCount;
- @Schema(title = "鍦板潃")
+ /**
+ * 鍦板潃
+ */
private String address;
- @Schema(title = "澶囨敞")
+ /**
+ * 澶囨敞
+ */
private String remarks;
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
diff --git a/pipIrr-platform/pipIrr-global/src/main/resources/mapper/SeClientMapper.xml b/pipIrr-platform/pipIrr-global/src/main/resources/mapper/SeClientMapper.xml
index e1d1b20..0172422 100644
--- a/pipIrr-platform/pipIrr-global/src/main/resources/mapper/SeClientMapper.xml
+++ b/pipIrr-platform/pipIrr-global/src/main/resources/mapper/SeClientMapper.xml
@@ -306,7 +306,13 @@
SELECT
COUNT(*) AS recordCount
FROM se_client cli
- , (SELECT @i:=0) AS itable
+ LEFT JOIN ba_district dis_con ON cli.countyId = dis_con.id
+ LEFT JOIN ba_district dis_town ON cli.townId = dis_town.id
+ LEFT JOIN ba_district dis_village ON cli.villageId = dis_village.id
+ LEFT JOIN ba_block blo ON cli.blockId = blo.id
+ LEFT JOIN pr_divide divi ON cli.divideId = divi.id
+ LEFT JOIN se_water_type wat ON cli.typeId = wat.id
+ LEFT JOIN se_client_card card ON card.clientId = cli.id
<where>
AND cli.disabled = 0
AND cli.deleted = 0
@@ -335,6 +341,9 @@
<if test = "divideId != null and divideId !=''">
AND cli.divideId = #{divideId}
</if>
+ <if test = "cardNum != null">
+ AND card.cardNum = #{cardNum}
+ </if>
</where>
</select>
@@ -343,19 +352,19 @@
<!--鏍规嵁鎸囧畾鏉′欢鑾峰彇鍐滄埛鏁版嵁-->
<select id="getClients" resultType="com.dy.pipIrrGlobal.voSe.VoClient">
SELECT
- CAST(cli.countyId AS char) AS countyId,
+ cli.countyId,
dis_con.name AS countryName,
- CAST(cli.townId AS char) AS townId,
+ cli.townId,
dis_town.name AS townName,
- CAST(cli.villageId AS char) AS villageId,
+ cli.villageId,
dis_village.name AS villageName,
- CAST(cli.blockId AS char) AS blockId,
+ cli.blockId,
blo.name AS blockName,
- CAST(cli.divideId AS char) AS divideId,
+ cli.divideId,
divi.name AS divideName,
- CAST(cli.typeId AS char) AS typeId,
+ cli.typeId,
wat.typeName AS waterTypeName,
- CAST(cli.id AS char) AS clientId,
+ cli.id AS clientId,
cli.name,
cli.clientNum,
cli.phone,
@@ -366,12 +375,13 @@
cli.remarks,
cli.operateDt
FROM se_client cli
- LEFT JOIN ba_district dis_con ON cli.countyId = dis_con.id
- LEFT JOIN ba_district dis_town ON cli.townId = dis_town.id
- LEFT JOIN ba_district dis_village ON cli.villageId = dis_village.id
- LEFT JOIN ba_block blo ON cli.blockId = blo.id
- LEFT JOIN pr_divide divi ON cli.divideId = divi.id
- LEFT JOIN se_water_type wat ON cli.typeId = wat.id
+ LEFT JOIN ba_district dis_con ON cli.countyId = dis_con.id
+ LEFT JOIN ba_district dis_town ON cli.townId = dis_town.id
+ LEFT JOIN ba_district dis_village ON cli.villageId = dis_village.id
+ LEFT JOIN ba_block blo ON cli.blockId = blo.id
+ LEFT JOIN pr_divide divi ON cli.divideId = divi.id
+ LEFT JOIN se_water_type wat ON cli.typeId = wat.id
+ LEFT JOIN se_client_card card ON card.clientId = cli.id
<where>
AND cli.disabled = 0
AND cli.deleted = 0
@@ -400,6 +410,9 @@
<if test = "divideId != null and divideId !=''">
AND cli.divideId = #{divideId}
</if>
+ <if test = "cardNum != null">
+ AND card.cardNum = #{cardNum}
+ </if>
</where>
ORDER BY cli.operateDt DESC
<trim prefix="limit " >
diff --git a/pipIrr-platform/pipIrr-web/pipIrr-web-sell/src/main/java/com/dy/pipIrrSell/client/QueryVo.java b/pipIrr-platform/pipIrr-web/pipIrr-web-sell/src/main/java/com/dy/pipIrrSell/client/QueryVo.java
index be9285f..3443176 100644
--- a/pipIrr-platform/pipIrr-web/pipIrr-web-sell/src/main/java/com/dy/pipIrrSell/client/QueryVo.java
+++ b/pipIrr-platform/pipIrr-web/pipIrr-web-sell/src/main/java/com/dy/pipIrrSell/client/QueryVo.java
@@ -49,4 +49,9 @@
@Schema(description = "鏉慖D")
public String villageId;
+
+ /**
+ * 姘村崱缂栧彿
+ */
+ public Long cardNum;
}
\ No newline at end of file
--
Gitblit v1.8.0