Use unique reference_id for Razorpay payment links
All checks were successful
build-and-deploy / build-deploy (push) Successful in 35s
All checks were successful
build-and-deploy / build-deploy (push) Successful in 35s
This commit is contained in:
@@ -93,7 +93,8 @@ class RazorpayPaymentLinksController(
|
||||
"currency" to currency,
|
||||
"description" to (request.description ?: "Booking $bookingId"),
|
||||
"notes" to notes,
|
||||
"reference_id" to bookingId.toString()
|
||||
// Razorpay requires reference_id to be unique per active link
|
||||
"reference_id" to "${bookingId}-${OffsetDateTime.now().toEpochSecond()}"
|
||||
)
|
||||
parseExpiryEpoch(request.expiryDate)?.let { payload["expire_by"] = it }
|
||||
request.isPartialPaymentAllowed?.let { payload["partial_payment"] = it }
|
||||
|
||||
Reference in New Issue
Block a user