콘텐츠 상세
- 50캔 이상의 유료콘텐츠이고 구매하지 않은 콘텐츠 이고 isFullDetailVisible가 false이면 콘텐츠 설명이 최대 10글자까지만 보이도록 수정
This commit is contained in:
parent
fcae1b6770
commit
84804d32ad
|
@ -596,10 +596,26 @@ class AudioContentService(
|
||||||
audioContent.purchaseOption
|
audioContent.purchaseOption
|
||||||
}
|
}
|
||||||
|
|
||||||
|
val contentDetail = if (
|
||||||
|
audioContent.price >= 50 &&
|
||||||
|
!isExistsAudioContent &&
|
||||||
|
!audioContent.isFullDetailVisible
|
||||||
|
) {
|
||||||
|
val length = audioContent.detail.length
|
||||||
|
|
||||||
|
if (length < 20) {
|
||||||
|
"${audioContent.detail.take(length / 2)}..."
|
||||||
|
} else {
|
||||||
|
"${audioContent.detail.take(10)}..."
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
audioContent.detail
|
||||||
|
}
|
||||||
|
|
||||||
return GetAudioContentDetailResponse(
|
return GetAudioContentDetailResponse(
|
||||||
contentId = audioContent.id!!,
|
contentId = audioContent.id!!,
|
||||||
title = audioContent.title,
|
title = audioContent.title,
|
||||||
detail = audioContent.detail,
|
detail = contentDetail,
|
||||||
coverImageUrl = "$coverImageHost/${audioContent.coverImage!!}",
|
coverImageUrl = "$coverImageHost/${audioContent.coverImage!!}",
|
||||||
contentUrl = audioContentUrl,
|
contentUrl = audioContentUrl,
|
||||||
themeStr = audioContent.theme!!.theme,
|
themeStr = audioContent.theme!!.theme,
|
||||||
|
|
Loading…
Reference in New Issue