27 lines
704 B
PHP
27 lines
704 B
PHP
<?php
|
|
|
|
namespace App\Libraries;
|
|
|
|
class RefundEligibilityResult
|
|
{
|
|
public function __construct(
|
|
public int $sourceCreditCents,
|
|
public int $completedPayoutCents,
|
|
public int $reservedAmountCents,
|
|
public int $availableAmountCents,
|
|
public array $reasonCodes = []
|
|
) {
|
|
}
|
|
|
|
public function toArray(): array
|
|
{
|
|
return [
|
|
'sourceCreditCents' => $this->sourceCreditCents,
|
|
'completedPayoutCents' => $this->completedPayoutCents,
|
|
'reservedAmountCents' => $this->reservedAmountCents,
|
|
'availableAmountCents' => $this->availableAmountCents,
|
|
'reasonCodes' => $this->reasonCodes,
|
|
];
|
|
}
|
|
}
|