게시판 통합검색(작성자,내용,제목) 추가

This commit is contained in:
nevermoregb 2025-03-18 15:59:07 +09:00
parent 4d208ae802
commit e411a0a567

View File

@ -15,7 +15,11 @@
LEFT JOIN netmember m ON b.MEMBERSEQ = m.MEMBERSEQ LEFT JOIN netmember m ON b.MEMBERSEQ = m.MEMBERSEQ
WHERE LOCBRDTYP = '300103' WHERE LOCBRDTYP = '300103'
<if test="searchKeyword != null and searchKeyword != ''"> <if test="searchKeyword != null and searchKeyword != ''">
AND LOCBRDTTL LIKE CONCAT('%', #{searchKeyword}, '%') AND (
LOCBRDTTL LIKE CONCAT('%', #{searchKeyword}, '%')
OR LOCBRDCON LIKE CONCAT('%', #{searchKeyword}, '%')
OR MEMBERNAM LIKE CONCAT('%', #{searchKeyword}, '%')
)
</if> </if>
ORDER BY LOCBRDUDT DESC ORDER BY LOCBRDUDT DESC
</select> </select>
@ -33,7 +37,11 @@
LEFT JOIN netmember m ON b.MEMBERSEQ = m.MEMBERSEQ LEFT JOIN netmember m ON b.MEMBERSEQ = m.MEMBERSEQ
WHERE b.LOCBRDTYP IN ('300101', '300102') WHERE b.LOCBRDTYP IN ('300101', '300102')
<if test="searchKeyword != null and searchKeyword != ''"> <if test="searchKeyword != null and searchKeyword != ''">
AND b.LOCBRDTTL LIKE CONCAT('%', #{searchKeyword}, '%') AND (
LOCBRDTTL LIKE CONCAT('%', #{searchKeyword}, '%')
OR LOCBRDCON LIKE CONCAT('%', #{searchKeyword}, '%')
OR MEMBERNAM LIKE CONCAT('%', #{searchKeyword}, '%')
)
</if> </if>
ORDER BY ORDER BY
<choose> <choose>