feat: add payer_dni field and validation for transfer payments, update related logic and tests
This commit is contained in:
@@ -54,7 +54,7 @@ class TelepagosWebhookService
|
||||
$dni = substr($cuit, 2, -1);
|
||||
|
||||
$compra = Purchase::where('tenant_codigo', $tenantCodigo)
|
||||
->whereRaw("REPLACE(dni, '.', '') = ?", [$dni])
|
||||
->where('payer_dni', $dni)
|
||||
->whereIn('status', [Purchase::STATUS_CREATED, Purchase::STATUS_PENDING_PAYMENT])
|
||||
->where('payment_method', 'transfer')
|
||||
->where('total', $amount)
|
||||
|
||||
Reference in New Issue
Block a user