Include issuer info in card prepare response
All checks were successful
build-and-deploy / build-deploy (push) Successful in 33s
All checks were successful
build-and-deploy / build-deploy (push) Successful in 33s
This commit is contained in:
@@ -48,7 +48,7 @@ class IssuedCards(
|
||||
@AuthenticationPrincipal principal: MyPrincipal?,
|
||||
@RequestBody request: CardPrepareRequest
|
||||
): CardPrepareResponse {
|
||||
requireIssueActor(propertyId, principal)
|
||||
val actor = requireIssueActor(propertyId, principal)
|
||||
val stay = roomStayRepo.findById(roomStayId).orElseThrow {
|
||||
ResponseStatusException(HttpStatus.NOT_FOUND, "Room stay not found")
|
||||
}
|
||||
@@ -73,7 +73,10 @@ class IssuedCards(
|
||||
key = payload.key,
|
||||
timeData = payload.timeData,
|
||||
issuedAt = issuedAt.toString(),
|
||||
expiresAt = expiresAt.toString()
|
||||
expiresAt = expiresAt.toString(),
|
||||
issuerUserId = actor.id,
|
||||
issuerFirebaseUid = actor.firebaseUid,
|
||||
issuerName = actor.name
|
||||
)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user