diff --git a/src/main/resources/mybatis/mapper/addicts/addicts-mapper.xml b/src/main/resources/mybatis/mapper/addicts/addicts-mapper.xml
index fd076df..84dc6f2 100644
--- a/src/main/resources/mybatis/mapper/addicts/addicts-mapper.xml
+++ b/src/main/resources/mybatis/mapper/addicts/addicts-mapper.xml
@@ -163,9 +163,10 @@
t2.telephone
FROM
gen_addicts t1
- LEFT JOIN gen_base_population_info t2 ON t1.id_card_number = t2.id_card_number AND t2.is_delete = '0'
+ LEFT JOIN gen_base_population_info t2 ON t1.id_card_number = t2.id_card_number
WHERE
t1.is_delete = 0
+ AND t2.is_delete = 0
AND t1.addicts_id = #{addictsId}
@@ -197,9 +198,10 @@
CONCAT(t2.current_residence,t2.current_residence_addr) current_residence
FROM
gen_addicts t1
- LEFT JOIN gen_base_population_info t2 ON t1.id_card_number = t2.id_card_number AND t2.is_delete = '0'
+ LEFT JOIN gen_base_population_info t2 ON t1.id_card_number = t2.id_card_number
WHERE
t1.is_delete = 0
+ AND t2.is_delete = 0
AND (
t1.id_card_number LIKE CONCAT('%', #{keywords}, '%')
diff --git a/src/main/resources/mybatis/mapper/aids/aids-mapper.xml b/src/main/resources/mybatis/mapper/aids/aids-mapper.xml
index 1997eb9..e4abf86 100644
--- a/src/main/resources/mybatis/mapper/aids/aids-mapper.xml
+++ b/src/main/resources/mybatis/mapper/aids/aids-mapper.xml
@@ -157,9 +157,10 @@
t2.telephone
FROM
gen_aids t1
- LEFT JOIN gen_base_population_info t2 ON t1.id_card_number = t2.id_card_number AND t2.is_delete = '0'
+ LEFT JOIN gen_base_population_info t2 ON t1.id_card_number = t2.id_card_number
WHERE
t1.is_delete = 0
+ AND t2.is_delete = 0
AND t1.aids_id = #{aidsId}
@@ -190,9 +191,10 @@
CONCAT(t2.current_residence,t2.current_residence_addr) current_residence
FROM
gen_aids t1
- LEFT JOIN gen_base_population_info t2 ON t1.id_card_number = t2.id_card_number AND t2.is_delete = '0'
+ LEFT JOIN gen_base_population_info t2 ON t1.id_card_number = t2.id_card_number
WHERE
t1.is_delete = 0
+ AND t2.is_delete = 0
AND (
t1.id_card_number LIKE CONCAT('%', #{keywords}, '%')
diff --git a/src/main/resources/mybatis/mapper/basepopulationinfo/basepopulationinfo-mapper.xml b/src/main/resources/mybatis/mapper/basepopulationinfo/basepopulationinfo-mapper.xml
index 1c4b178..d00596e 100644
--- a/src/main/resources/mybatis/mapper/basepopulationinfo/basepopulationinfo-mapper.xml
+++ b/src/main/resources/mybatis/mapper/basepopulationinfo/basepopulationinfo-mapper.xml
@@ -320,9 +320,9 @@
t1.is_delete = 0
AND (
- t1.id LIKE CONCAT('%', #{keywords}, '%')
+ t1.full_name LIKE CONCAT('%', #{keywords}, '%')
OR
- t1.base_population_info_id LIKE CONCAT('%', #{keywords}, '%')
+ t1.id_card_number LIKE CONCAT('%', #{keywords}, '%')
)
diff --git a/src/main/resources/mybatis/mapper/communitycorrection/communitycorrection-mapper.xml b/src/main/resources/mybatis/mapper/communitycorrection/communitycorrection-mapper.xml
index 6c9e4d2..34a41a1 100644
--- a/src/main/resources/mybatis/mapper/communitycorrection/communitycorrection-mapper.xml
+++ b/src/main/resources/mybatis/mapper/communitycorrection/communitycorrection-mapper.xml
@@ -295,9 +295,10 @@
t2.telephone
FROM
gen_community_correction t1
- LEFT JOIN gen_base_population_info t2 ON t1.id_card_number = t2.id_card_number AND t2.is_delete = '0'
+ LEFT JOIN gen_base_population_info t2 ON t1.id_card_number = t2.id_card_number
WHERE
t1.is_delete = 0
+ AND t2.is_delete = 0
AND
t1.community_correction_id = #{communityCorrectionId}
@@ -348,9 +349,10 @@
CONCAT(t2.current_residence,t2.current_residence_addr) current_residence
FROM
gen_community_correction t1
- LEFT JOIN gen_base_population_info t2 ON t1.id_card_number = t2.id_card_number AND t2.is_delete = '0'
+ LEFT JOIN gen_base_population_info t2 ON t1.id_card_number = t2.id_card_number
WHERE
t1.is_delete = 0
+ AND t2.is_delete = 0
AND (
t1.id_card_number LIKE CONCAT('%', #{keywords}, '%')
diff --git a/src/main/resources/mybatis/mapper/mentaldisorders/mentaldisorders-mapper.xml b/src/main/resources/mybatis/mapper/mentaldisorders/mentaldisorders-mapper.xml
index ac91a74..20b3878 100644
--- a/src/main/resources/mybatis/mapper/mentaldisorders/mentaldisorders-mapper.xml
+++ b/src/main/resources/mybatis/mapper/mentaldisorders/mentaldisorders-mapper.xml
@@ -207,9 +207,10 @@
t2.telephone
FROM
gen_mental_disorders t1
- LEFT JOIN gen_base_population_info t2 ON t1.id_card_number = t2.id_card_number AND t2.is_delete = '0'
+ LEFT JOIN gen_base_population_info t2 ON t1.id_card_number = t2.id_card_number
WHERE
t1.is_delete = 0
+ AND t2.is_delete = 0
AND
t1.mental_disorders_id = #{mentalDisordersId}
@@ -248,9 +249,10 @@
CONCAT(t2.current_residence,t2.current_residence_addr) current_residence
FROM
gen_mental_disorders t1
- LEFT JOIN gen_base_population_info t2 ON t1.id_card_number = t2.id_card_number AND t2.is_delete = '0'
+ LEFT JOIN gen_base_population_info t2 ON t1.id_card_number = t2.id_card_number
WHERE
t1.is_delete = 0
+ AND t2.is_delete = 0
AND (
t1.id_card_number LIKE CONCAT('%', #{keywords}, '%')
diff --git a/src/main/resources/mybatis/mapper/releaseaftersentence/releaseaftersentence-mapper.xml b/src/main/resources/mybatis/mapper/releaseaftersentence/releaseaftersentence-mapper.xml
index 841317a..38f4715 100644
--- a/src/main/resources/mybatis/mapper/releaseaftersentence/releaseaftersentence-mapper.xml
+++ b/src/main/resources/mybatis/mapper/releaseaftersentence/releaseaftersentence-mapper.xml
@@ -186,9 +186,10 @@
t2.telephone
FROM
gen_release_after_sentence t1
- LEFT JOIN gen_base_population_info t2 ON t1.id_card_number = t2.id_card_number AND t2.is_delete = '0'
+ LEFT JOIN gen_base_population_info t2 ON t1.id_card_number = t2.id_card_number
WHERE
t1.is_delete = 0
+ AND t2.is_delete = 0
AND t1.release_after_sentence_id = #{releaseAfterSentenceId}
@@ -223,9 +224,10 @@
CONCAT(t2.current_residence,t2.current_residence_addr) current_residence
FROM
gen_release_after_sentence t1
- LEFT JOIN gen_base_population_info t2 ON t1.id_card_number = t2.id_card_number AND t2.is_delete = '0'
+ LEFT JOIN gen_base_population_info t2 ON t1.id_card_number = t2.id_card_number
WHERE
t1.is_delete = 0
+ AND t2.is_delete = 0
AND (
t1.id_card_number LIKE CONCAT('%', #{keywords}, '%')