fix(agent-assignment): 소속 크리에이터 조회 시각을 KST로 변환한다
This commit is contained in:
@@ -56,9 +56,19 @@ class AdminAgentReadService(
|
||||
fun getAssignedCreators(agentId: Long, offset: Long, limit: Long): GetAdminAgentAssignedCreatorResponse {
|
||||
validateAgent(agentId)
|
||||
val now = LocalDateTime.now()
|
||||
val items = queryRepository.getAssignedCreators(agentId = agentId, offset = offset, limit = limit, currentTime = now)
|
||||
.map {
|
||||
it.copy(
|
||||
assignedAt = it.assignedAt
|
||||
.atZone(ZoneId.of("UTC"))
|
||||
.withZoneSameInstant(kstZoneId)
|
||||
.toLocalDateTime()
|
||||
)
|
||||
}
|
||||
|
||||
return GetAdminAgentAssignedCreatorResponse(
|
||||
totalCount = queryRepository.getAssignedCreatorTotalCount(agentId = agentId, currentTime = now),
|
||||
items = queryRepository.getAssignedCreators(agentId = agentId, offset = offset, limit = limit, currentTime = now)
|
||||
items = items
|
||||
)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user