Compare commits

..

No commits in common. "8fffad9d3acab6ecd1439cd13468e4355a6f63f6" and "f4f0f203a25d54caa5550307894d72d3062e9159" have entirely different histories.

3 changed files with 16 additions and 19 deletions

View File

@ -14,8 +14,9 @@ import java.time.LocalDateTime
@Repository
class AdminAdStatisticsRepository(private val queryFactory: JPAQueryFactory) {
fun getAdStatisticsDataTotalCount(): Int {
return queryFactory
.select(adTrackingHistory.id.pid)
return (
queryFactory
.select(adTrackingHistory.id.pid.count())
.from(adTrackingHistory)
.groupBy(
getFormattedDate(adTrackingHistory.id.createdAt),
@ -23,8 +24,8 @@ class AdminAdStatisticsRepository(private val queryFactory: JPAQueryFactory) {
adTrackingHistory.id.pid,
adTrackingHistory.pidName
)
.fetch()
.size
.fetchOne() ?: 0L
).toInt()
}
fun getAdStatisticsDataList(

View File

@ -410,10 +410,8 @@ class AudioContentQueryRepositoryImpl(
where = where.and(audioContentTheme.theme.`in`(theme))
}
where = if (isFree) {
where.and(audioContent.price.loe(0))
} else {
where.and(audioContent.price.gt(0))
if (isFree) {
where = where.and(audioContent.price.loe(0))
}
return queryFactory

View File

@ -35,10 +35,8 @@ class AudioContentThemeQueryRepository(
where = where.and(audioContent.isAdult.isFalse)
}
where = if (isFree) {
where.and(audioContent.price.loe(0))
} else {
where.and(audioContent.price.gt(0))
if (isFree) {
where = where.and(audioContent.price.loe(0))
}
return queryFactory