test #290

Merged
klaus merged 6 commits from test into main 2025-03-19 07:51:26 +00:00
2 changed files with 20 additions and 14 deletions
Showing only changes of commit 46321dd3c1 - Show all commits

View File

@ -166,7 +166,6 @@ class AudioContentMainTabContentService(
.plusDays(1) .plusDays(1)
var loopCount = 0 var loopCount = 0
var contentCount: Int
var contentList: List<GetAudioContentRankingItem> var contentList: List<GetAudioContentRankingItem>
do { do {
@ -178,9 +177,8 @@ class AudioContentMainTabContentService(
endDate = dailyRankingEndDate, endDate = dailyRankingEndDate,
sortType = sortType sortType = sortType
) )
contentCount = contentList.size
loopCount++ loopCount++
} while (contentCount < 5) } while (contentList.size < 5)
return contentList return contentList
} }

View File

@ -49,17 +49,25 @@ class RankingService(
sortType: String = "매출", sortType: String = "매출",
theme: String = "" theme: String = ""
): List<GetAudioContentRankingItem> { ): List<GetAudioContentRankingItem> {
return repository.getAudioContentRanking( var loopCount = 0L
var contentList: List<GetAudioContentRankingItem>
do {
contentList = repository.getAudioContentRanking(
memberId = memberId, memberId = memberId,
isAdult = isAdult, isAdult = isAdult,
contentType = contentType, contentType = contentType,
startDate = startDate, startDate = startDate.minusWeeks(loopCount),
endDate = endDate, endDate = endDate,
offset = offset, offset = offset,
limit = limit, limit = limit,
sortType = sortType, sortType = sortType,
theme = theme theme = theme
) )
loopCount++
} while (contentList.size < 5)
return contentList
} }
fun getSeriesRanking( fun getSeriesRanking(