From 690432d6ee705d69b5ffc9fee7dc6c46520d247a Mon Sep 17 00:00:00 2001 From: Klaus Date: Tue, 18 Nov 2025 19:21:15 +0900 Subject: [PATCH] =?UTF-8?q?fix(latest-content):=20=EC=B5=9C=EC=8B=A0=20?= =?UTF-8?q?=EC=BD=98=ED=85=90=EC=B8=A0=20=EC=A0=84=EC=B2=B4=EB=B3=B4?= =?UTF-8?q?=EA=B8=B0=EC=97=90=EC=84=9C=20=EC=9C=A0/=EB=AC=B4=EB=A3=8C=20?= =?UTF-8?q?=EB=AA=A8=EB=91=90=20=EC=A1=B0=ED=9A=8C=EB=90=98=EB=8F=84?= =?UTF-8?q?=EB=A1=9D=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../sodalive/content/AudioContentRepository.kt | 12 ------------ .../content/main/AudioContentMainController.kt | 2 -- .../content/main/AudioContentMainService.kt | 15 +-------------- 3 files changed, 1 insertion(+), 28 deletions(-) diff --git a/src/main/kotlin/kr/co/vividnext/sodalive/content/AudioContentRepository.kt b/src/main/kotlin/kr/co/vividnext/sodalive/content/AudioContentRepository.kt index 6b93c4d..8dbeaf4 100644 --- a/src/main/kotlin/kr/co/vividnext/sodalive/content/AudioContentRepository.kt +++ b/src/main/kotlin/kr/co/vividnext/sodalive/content/AudioContentRepository.kt @@ -109,7 +109,6 @@ interface AudioContentQueryRepository { ): Int fun findByThemeFor2Weeks( - isFree: Boolean = false, cloudfrontHost: String, memberId: Long, theme: List = emptyList(), @@ -120,7 +119,6 @@ interface AudioContentQueryRepository { ): List fun totalCountNewContentFor2Weeks( - isFree: Boolean = false, theme: List = emptyList(), memberId: Long, isAdult: Boolean, @@ -695,7 +693,6 @@ class AudioContentQueryRepositoryImpl( } override fun totalCountNewContentFor2Weeks( - isFree: Boolean, theme: List, memberId: Long, isAdult: Boolean, @@ -732,10 +729,6 @@ class AudioContentQueryRepositoryImpl( where = where.and(audioContentTheme.theme.`in`(theme)) } - if (isFree) { - where = where.and(audioContent.price.loe(0)) - } - return queryFactory .select(audioContent.id) .from(audioContent) @@ -747,7 +740,6 @@ class AudioContentQueryRepositoryImpl( } override fun findByThemeFor2Weeks( - isFree: Boolean, cloudfrontHost: String, memberId: Long, theme: List, @@ -787,10 +779,6 @@ class AudioContentQueryRepositoryImpl( where = where.and(audioContentTheme.theme.`in`(theme)) } - if (isFree) { - where = where.and(audioContent.price.loe(0)) - } - return queryFactory .select( QGetAudioContentMainItem( diff --git a/src/main/kotlin/kr/co/vividnext/sodalive/content/main/AudioContentMainController.kt b/src/main/kotlin/kr/co/vividnext/sodalive/content/main/AudioContentMainController.kt index 3ff5f8d..c534be5 100644 --- a/src/main/kotlin/kr/co/vividnext/sodalive/content/main/AudioContentMainController.kt +++ b/src/main/kotlin/kr/co/vividnext/sodalive/content/main/AudioContentMainController.kt @@ -99,7 +99,6 @@ class AudioContentMainController( @GetMapping("/new/all") fun getNewContentAllByTheme( - @RequestParam("isFree", required = false) isFree: Boolean? = null, @RequestParam("theme") theme: String, @RequestParam("isAdultContentVisible", required = false) isAdultContentVisible: Boolean? = null, @RequestParam("contentType", required = false) contentType: ContentType? = null, @@ -110,7 +109,6 @@ class AudioContentMainController( ApiResponse.ok( service.getNewContentFor2WeeksByTheme( - isFree = isFree ?: false, theme = theme, isAdultContentVisible = isAdultContentVisible ?: true, contentType = contentType ?: ContentType.ALL, diff --git a/src/main/kotlin/kr/co/vividnext/sodalive/content/main/AudioContentMainService.kt b/src/main/kotlin/kr/co/vividnext/sodalive/content/main/AudioContentMainService.kt index a24c8f8..72a025e 100644 --- a/src/main/kotlin/kr/co/vividnext/sodalive/content/main/AudioContentMainService.kt +++ b/src/main/kotlin/kr/co/vividnext/sodalive/content/main/AudioContentMainService.kt @@ -54,7 +54,6 @@ class AudioContentMainService( @Transactional(readOnly = true) fun getNewContentFor2WeeksByTheme( - isFree: Boolean, theme: String, isAdultContentVisible: Boolean, contentType: ContentType, @@ -65,31 +64,19 @@ class AudioContentMainService( val themeList = if (theme.isBlank()) { audioContentThemeRepository.getActiveThemeOfContent( isAdult = isAdult, - isFree = isFree, contentType = contentType - ).filter { - it != "모닝콜" && - it != "알람" && - it != "슬립콜" && - it != "다시듣기" && - it != "ASMR" && - it != "릴레이" && - it != "챌린지" && - it != "자기소개" - } + ) } else { listOf(theme) } val totalCount = repository.totalCountNewContentFor2Weeks( - isFree, themeList, memberId = member.id!!, isAdult = isAdult, contentType = contentType ) val items = repository.findByThemeFor2Weeks( - isFree, cloudfrontHost = imageHost, memberId = member.id!!, theme = themeList,