회원정보 count 수정
This commit is contained in:
@@ -134,8 +134,14 @@ public class MembersRepositoryImpl implements MembersRepositoryCustom {
|
|||||||
.orderBy(memberEntity.createdDttm.desc())
|
.orderBy(memberEntity.createdDttm.desc())
|
||||||
.fetch();
|
.fetch();
|
||||||
|
|
||||||
long total = queryFactory.select(memberEntity).from(memberEntity).where(builder).fetchCount();
|
long total =
|
||||||
|
Optional.ofNullable(
|
||||||
|
queryFactory
|
||||||
|
.select(memberEntity.count())
|
||||||
|
.from(memberEntity)
|
||||||
|
.where(builder)
|
||||||
|
.fetchOne())
|
||||||
|
.orElse(0L);
|
||||||
return new PageImpl<>(content, pageable, total);
|
return new PageImpl<>(content, pageable, total);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user