콘텐츠
- 오픈예정인 작품은 새로운 콘텐츠에서 보이지 않도록 수정 - 콘텐츠 상세페이지에 오픈 날짜 추가
This commit is contained in:
@@ -438,19 +438,41 @@ class AudioContentService(
|
||||
0
|
||||
}
|
||||
|
||||
val audioContentUrl = audioContentCloudFront.generateSignedURL(
|
||||
resourcePath = if (
|
||||
isExistsAudioContent ||
|
||||
isExistsBundleAudioContent ||
|
||||
audioContent.member!!.id!! == member.id!! ||
|
||||
audioContent.price <= 0
|
||||
) {
|
||||
audioContent.content!!
|
||||
} else {
|
||||
audioContent.content!!.replace("output/", "preview/")
|
||||
},
|
||||
expirationTime = 1000 * 60 * 60 * (audioContent.duration!!.split(":")[0].toLong() + 2)
|
||||
)
|
||||
val releaseDate = if (
|
||||
audioContent.releaseDate != null &&
|
||||
audioContent.releaseDate!! < LocalDateTime.now() &&
|
||||
creatorId != member.id!!
|
||||
) {
|
||||
audioContent.releaseDate!!
|
||||
.atZone(ZoneId.of("UTC"))
|
||||
.withZoneSameInstant(ZoneId.of("Asia/Seoul"))
|
||||
.toLocalDateTime()
|
||||
.format(DateTimeFormatter.ofPattern("yyyy년 MM월 dd일 HH시 mm분 오픈"))
|
||||
} else {
|
||||
null
|
||||
}
|
||||
|
||||
val audioContentUrl = if (
|
||||
audioContent.releaseDate != null &&
|
||||
audioContent.releaseDate!! < LocalDateTime.now() &&
|
||||
creatorId != member.id!!
|
||||
) {
|
||||
audioContentCloudFront.generateSignedURL(
|
||||
resourcePath = if (
|
||||
isExistsAudioContent ||
|
||||
isExistsBundleAudioContent ||
|
||||
audioContent.member!!.id!! == member.id!! ||
|
||||
audioContent.price <= 0
|
||||
) {
|
||||
audioContent.content!!
|
||||
} else {
|
||||
audioContent.content!!.replace("output/", "preview/")
|
||||
},
|
||||
expirationTime = 1000 * 60 * 60 * (audioContent.duration!!.split(":")[0].toLong() + 2)
|
||||
)
|
||||
} else {
|
||||
""
|
||||
}
|
||||
|
||||
val tag = audioContent.audioContentHashTags
|
||||
.map { it.hashTag!!.tag }
|
||||
@@ -496,6 +518,7 @@ class AudioContentService(
|
||||
tag = tag,
|
||||
price = audioContent.price,
|
||||
duration = audioContent.duration ?: "",
|
||||
releaseDate = releaseDate,
|
||||
isAdult = audioContent.isAdult,
|
||||
isMosaic = audioContent.isAdult && member.auth == null,
|
||||
isOnlyRental = audioContent.isOnlyRental,
|
||||
|
Reference in New Issue
Block a user