Compare commits
No commits in common. "4abe1730a7dc65120c1dbb8e5a2515720db581e0" and "626f0e698966b7f4ae1e4f789573a9264786ad90" have entirely different histories.
4abe1730a7
...
626f0e6989
|
@ -34,7 +34,6 @@ class AdminCalculateQueryRepository(private val queryFactory: JPAQueryFactory) {
|
|||
liveRoom.title,
|
||||
liveRoom.price,
|
||||
useCan.canUsage,
|
||||
useCanCalculate.id.count(),
|
||||
useCanCalculate.can.sum()
|
||||
)
|
||||
)
|
||||
|
|
|
@ -26,17 +26,11 @@ class AdminCalculateService(private val repository: AdminCalculateQueryRepositor
|
|||
.asSequence()
|
||||
.map {
|
||||
val canUsageStr = if (it.canUsage == CanUsage.LIVE) {
|
||||
"유료"
|
||||
"유료방 참여"
|
||||
} else {
|
||||
"후원"
|
||||
}
|
||||
|
||||
val numberOfPeople = if (it.canUsage == CanUsage.LIVE) {
|
||||
it.memberCount.toInt()
|
||||
} else {
|
||||
0
|
||||
}
|
||||
|
||||
// 원화 = totalCoin * 100 ( 캔 1개 = 100원 )
|
||||
val totalKrw = it.totalAmount * 100
|
||||
|
||||
|
@ -58,8 +52,7 @@ class AdminCalculateService(private val repository: AdminCalculateQueryRepositor
|
|||
date = it.date,
|
||||
title = it.title,
|
||||
entranceFee = it.entranceFee,
|
||||
canUsageStr = canUsageStr,
|
||||
numberOfPeople = numberOfPeople,
|
||||
coinUsageStr = canUsageStr,
|
||||
totalAmount = it.totalAmount,
|
||||
totalKrw = totalKrw,
|
||||
paymentFee = paymentFee.roundToInt(),
|
||||
|
|
|
@ -12,8 +12,6 @@ data class GetCalculateLiveQueryData @QueryProjection constructor(
|
|||
val entranceFee: Int,
|
||||
// 코인 사용 구분
|
||||
val canUsage: CanUsage,
|
||||
// 참여인원
|
||||
val memberCount: Long,
|
||||
// 합계
|
||||
val totalAmount: Int
|
||||
)
|
||||
|
|
|
@ -7,10 +7,8 @@ data class GetCalculateLiveResponse(
|
|||
val title: String,
|
||||
// 유료방 입장 금액
|
||||
val entranceFee: Int,
|
||||
// 캔 사용 구분
|
||||
val canUsageStr: String,
|
||||
// 인원
|
||||
val numberOfPeople: Int,
|
||||
// 코인 사용 구분
|
||||
val coinUsageStr: String,
|
||||
// 합계
|
||||
val totalAmount: Int,
|
||||
// 원화
|
||||
|
|
Loading…
Reference in New Issue