test #188

Merged
klaus merged 7 commits from test into main 2024-06-03 22:13:56 +00:00
2 changed files with 0 additions and 34 deletions
Showing only changes of commit 26b8dcee1b - Show all commits

View File

@ -185,19 +185,8 @@ class CreatorCommunityService(
val existOrdered = useCanRepository.isExistOrdered(postId = it.id, memberId = memberId) val existOrdered = useCanRepository.isExistOrdered(postId = it.id, memberId = memberId)
val content = if (it.price > 0 && memberId != it.creatorId) {
if (existOrdered) {
it.content
} else {
it.content.substring(0, 5).plus("...")
}
} else {
it.content
}
it.toCommunityPostListResponse( it.toCommunityPostListResponse(
imageHost = imageHost, imageHost = imageHost,
content = content,
date = getTimeAgoString(it.date), date = getTimeAgoString(it.date),
isLike = isLike, isLike = isLike,
existOrdered = if (memberId == it.creatorId) { existOrdered = if (memberId == it.creatorId) {
@ -251,19 +240,8 @@ class CreatorCommunityService(
val existOrdered = useCanRepository.isExistOrdered(postId = post.id, memberId = memberId) val existOrdered = useCanRepository.isExistOrdered(postId = post.id, memberId = memberId)
val content = if (post.price > 0 && memberId != post.creatorId) {
if (existOrdered) {
post.content
} else {
post.content.substring(0, 5).plus("...")
}
} else {
post.content
}
return post.toCommunityPostListResponse( return post.toCommunityPostListResponse(
imageHost = imageHost, imageHost = imageHost,
content = content,
date = getTimeAgoString(post.date), date = getTimeAgoString(post.date),
isLike = isLike, isLike = isLike,
existOrdered = if (memberId == post.creatorId) { existOrdered = if (memberId == post.creatorId) {
@ -431,19 +409,8 @@ class CreatorCommunityService(
val existOrdered = useCanRepository.isExistOrdered(postId = it.id, memberId = memberId) val existOrdered = useCanRepository.isExistOrdered(postId = it.id, memberId = memberId)
val content = if (it.price > 0 && memberId != it.creatorId) {
if (existOrdered) {
it.content
} else {
it.content.substring(0, 5).plus("...")
}
} else {
it.content
}
it.toCommunityPostListResponse( it.toCommunityPostListResponse(
imageHost = imageHost, imageHost = imageHost,
content = content,
date = getTimeAgoString(it.date), date = getTimeAgoString(it.date),
isLike = isLike, isLike = isLike,
existOrdered = if (memberId == it.creatorId) { existOrdered = if (memberId == it.creatorId) {

View File

@ -17,7 +17,6 @@ data class SelectCommunityPostResponse @QueryProjection constructor(
) { ) {
fun toCommunityPostListResponse( fun toCommunityPostListResponse(
imageHost: String, imageHost: String,
content: String,
date: String, date: String,
isLike: Boolean, isLike: Boolean,
existOrdered: Boolean, existOrdered: Boolean,