From 7bcd0d2d7510cb2ba67099cd768e1b2b6d047dc2 Mon Sep 17 00:00:00 2001
From: linwei <872216696@qq.com>
Date: Thu, 22 Feb 2024 17:16:27 +0800
Subject: [PATCH] 投票人员查询优化

---
 src/main/java/org/springblade/modules/place/mapper/PlaceMapper.xml |   12 +++++++++---
 1 files changed, 9 insertions(+), 3 deletions(-)

diff --git a/src/main/java/org/springblade/modules/place/mapper/PlaceMapper.xml b/src/main/java/org/springblade/modules/place/mapper/PlaceMapper.xml
index 94b511e..b016394 100644
--- a/src/main/java/org/springblade/modules/place/mapper/PlaceMapper.xml
+++ b/src/main/java/org/springblade/modules/place/mapper/PlaceMapper.xml
@@ -154,6 +154,10 @@
             and jp.is_front = #{place.isFront}
         </if>
 
+        <if test="place.frontType!=null and place.frontType!=''">
+            and jp.front_type = #{place.frontType}
+        </if>
+
         <if test="place.neiName!=null and place.neiName!=''">
             and br.name like concat('%',#{place.neiName},'%')
         </if>
@@ -476,7 +480,7 @@
         jpe.confirm_flag confirmFlag,
         bus.`name` AS policeName,
         bus.phone AS policePhone,
-        jp.location addressName,
+        jp.location as addressName,
         jpag.pcs_name deptName
         from jczz_place jp
         left join jczz_grid jg on jg.grid_code = jp.grid_code and jg.is_deleted = 0
@@ -515,18 +519,20 @@
         <if test="place.policeName!=null and place.policeName!=''">
             and bus.name like concat('%',#{place.policeName},'%')
         </if>
-
         <if test="nineTypeList!=null and nineTypeList.size()>0">
             and jp.nine_type in
             <foreach collection="nineTypeList" separator="," open="(" close=")" item="nineType">
                 #{nineType}
             </foreach>
         </if>
-
         <if test="place.isFront!=null and place.isFront!=''">
             and jp.is_front = #{place.isFront}
         </if>
 
+        <if test="place.frontType!=null and place.frontType!=''">
+            and jp.front_type = #{place.frontType}
+        </if>
+
         <if test="place.neiName!=null and place.neiName!=''">
             and br.name like concat('%',#{place.neiName},'%')
         </if>

--
Gitblit v1.9.3