From 445c5ec17342232d631c385ca49644423d9d1c26 Mon Sep 17 00:00:00 2001 From: wangqing <408564126@qq.com> Date: Thu, 14 Mar 2024 09:25:17 +0800 Subject: [PATCH] fix fuzzySearch filter -> unPublished & unEffictive --- luoo_music/src/main/java/com/luoo/music/dao/JournalDao.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/luoo_music/src/main/java/com/luoo/music/dao/JournalDao.java b/luoo_music/src/main/java/com/luoo/music/dao/JournalDao.java index 3882e3d..075cbbd 100644 --- a/luoo_music/src/main/java/com/luoo/music/dao/JournalDao.java +++ b/luoo_music/src/main/java/com/luoo/music/dao/JournalDao.java @@ -86,7 +86,7 @@ public interface JournalDao extends JpaRepository,JpaSpecificati @Query(value = "select * from tb_journal where state='1' and is_publish='1' and journal_no=?1", nativeQuery = true) Journal findValidJournalByJournalNo(String journalNo); - @Query(value = "select * from tb_journal where match(journal_no, title) against(?1 IN BOOLEAN MODE) limit ?2,?3 ", nativeQuery = true) + @Query(value = "select * from tb_journal where match(journal_no, title) against(?1 IN BOOLEAN MODE) and state='1' and is_publish='1' limit ?2,?3 ", nativeQuery = true) List fuzzySearch(String keyword, int offset, int limit); @Query(value = "select journal_no FROM tb_journal where id=?1", nativeQuery = true)