라이브 방 후원리스트
- 비밀후원 캔 0보다 크거나 일반후원 캔이 0보다 큰 경우에만 데이터 반환
This commit is contained in:
@@ -1177,6 +1177,7 @@ class LiveRoomService(
|
|||||||
val room = repository.getLiveRoom(roomId) ?: throw SodaException("잘못된 요청입니다.")
|
val room = repository.getLiveRoom(roomId) ?: throw SodaException("잘못된 요청입니다.")
|
||||||
val isLiveCreator = room.member!!.id == memberId
|
val isLiveCreator = room.member!!.id == memberId
|
||||||
val donationList = repository.getDonationList(roomId = room.id!!, isLiveCreator = isLiveCreator)
|
val donationList = repository.getDonationList(roomId = room.id!!, isLiveCreator = isLiveCreator)
|
||||||
|
.filter { it.secretCan > 0 || it.can > 0 }
|
||||||
val totalCan = donationList.sumOf { it.can }
|
val totalCan = donationList.sumOf { it.can }
|
||||||
val totalSecretCan = donationList.sumOf { it.secretCan }
|
val totalSecretCan = donationList.sumOf { it.secretCan }
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user