From 9f2ab0fa1a46e68fefb8df8f906ae0f652be31bf Mon Sep 17 00:00:00 2001 From: buerjun Date: Mon, 10 Jul 2023 12:01:30 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8E=A8=E8=8D=90=E6=9F=A5=E8=AF=A2=E4=BF=AE?= =?UTF-8?q?=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/xboe/module/boecase/dao/CasesRecordDao.java | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/servers/boe-server-all/src/main/java/com/xboe/module/boecase/dao/CasesRecordDao.java b/servers/boe-server-all/src/main/java/com/xboe/module/boecase/dao/CasesRecordDao.java index a251471a..672a0885 100644 --- a/servers/boe-server-all/src/main/java/com/xboe/module/boecase/dao/CasesRecordDao.java +++ b/servers/boe-server-all/src/main/java/com/xboe/module/boecase/dao/CasesRecordDao.java @@ -20,8 +20,7 @@ public interface CasesRecordDao extends JpaRepository, JpaSpecifi @Query(nativeQuery = true, value = "select c.* from ( select b.*" + " from boe_cases_recommend_push_record a INNER JOIN boe_cases b on a.case_id = b.id" + - " where b.deleted=0 and a.push_status = 3 and a.push_user_id= :#{#condition.userId}" + - " and if(IFNULL(:#{#condition.refId},'') !='' ,a.recommend_id = :#{#condition.refId},1=1) " + + " where b.deleted=0 and a.push_status = 3 and a.deleted=0 and a.push_user_id= :#{#condition.userId}" + " and if(IFNULL(:#{#condition.keyWord},'')!='',b.title like CONCAT('%',:#{#condition.keyWord},'%')" + " or b.author_name like CONCAT('%',:#{#condition.keyWord},'%')" + " or b.keyword1 like CONCAT('%',:#{#condition.keyWord},'%')" + @@ -37,8 +36,7 @@ public interface CasesRecordDao extends JpaRepository, JpaSpecifi " order by a.sys_create_time DESC, a.read_flag ASC) as c group by c.id", countQuery = "select count(*) FROM (select c.* from ( select b.*" + " from boe_cases_recommend_push_record a INNER JOIN boe_cases b on a.case_id = b.id " + - " where b.deleted=0 and a.push_status = 3 and a.push_user_id= :#{#condition.userId}" + - " and if(IFNULL(:#{#condition.refId},'') !='' ,a.recommend_id = :#{#condition.refId},1=1) " + + " where b.deleted=0 and a.push_status = 3 and a.deleted=0 and a.push_user_id= :#{#condition.userId}" + " and if(IFNULL(:#{#condition.keyWord},'')!='',b.title like CONCAT('%',:#{#condition.keyWord},'%')" + " or b.author_name like CONCAT('%',:#{#condition.keyWord},'%')" + " or b.keyword1 like CONCAT('%',:#{#condition.keyWord},'%')" +