feat: 게시판 관리 반영

dev
minuk926 3 years ago
parent 44ad4143a3
commit 34e8471afd

@ -29,7 +29,7 @@ public class IBoardRepositoryImpl implements IBoardRepositoryCustom{
QueryResults<Long> ciCodes = queryFactory QueryResults<Long> ciCodes = queryFactory
.select(minCivBoard680.ciCode) .select(minCivBoard680.ciCode)
.from(minCivBoard680) .from(minCivBoard680)
.where(ciTitleLike(dto.getCiTitle()), ciNameLike(dto.getCiName())) .where(ciTitleLike(dto.getCiTitle()), ciNameLike(dto.getCiName()), ciContentsLike(dto.getCiContents()))
.orderBy(minCivBoard680.ciRef.desc(), minCivBoard680.ciStep.asc(), minCivBoard680.ciCode.desc()) .orderBy(minCivBoard680.ciRef.desc(), minCivBoard680.ciStep.asc(), minCivBoard680.ciCode.desc())
.offset(pageable.getOffset()) .offset(pageable.getOffset())
.limit(pageable.getPageSize()) .limit(pageable.getPageSize())
@ -75,4 +75,9 @@ public class IBoardRepositoryImpl implements IBoardRepositoryCustom{
return minCivBoard680.ciName.contains(ciName); return minCivBoard680.ciName.contains(ciName);
} }
private BooleanExpression ciContentsLike(String ciContents){
if(Checks.isEmpty(ciContents)) return null;
return minCivBoard680.ciContents.contains(ciContents);
}
} }

Loading…
Cancel
Save