Skip to content

Commit

Permalink
Merge pull request #64 from wedevBr/refactor/NewFieldsForBillet
Browse files Browse the repository at this point in the history
[Refactor] Refactoring billet data
  • Loading branch information
adeildo-jr authored Mar 27, 2024
2 parents 1476625 + 7b8c513 commit 4382099
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 6 deletions.
2 changes: 0 additions & 2 deletions src/Rules/BAAS/Billet.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,9 @@ public static function rules(): array
{
return [
'externalId' => ['required'],
'merchantCategoryCode' => ['sometimes', 'required'],
'expirationAfterPayment' => ['required', 'numeric', 'min:1'],
'dueDate' => ['required', 'date', 'after:yesterday'],
'amount' => ['required', 'decimal:0,2'],
'key' => ['required'],
'debtor' => ['required', 'array'],
'debtor.name' => ['required', 'string', 'max: 25'],
'debtor.document' => ['required'],
Expand Down
2 changes: 0 additions & 2 deletions src/Types/BAAS/Billet.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,9 @@
class Billet extends Data
{
public string $externalId;
public ?string $merchantCategoryCode;
public int $expirationAfterPayment;
public string $dueDate;
public float $amount;
public ?string $key;
/**
* @var BilletDebtor
*/
Expand Down
2 changes: 0 additions & 2 deletions tests/Integration/BAAS/CelcoinBASSBilletTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,10 +46,8 @@ public static function billetBodyRequest(): Billet
return new Billet([
"externalId" => "externalId1",
"expirationAfterPayment" => 1,
"merchantCatagoryCode" => "0000",
"dueDate" => now()->format('Y-m-d'),
"amount" => 12.5,
"key" => "[email protected]",
"debtor" => new BilletDebtor([
"name" => "João teste de teste",
"document" => "12345678910",
Expand Down

0 comments on commit 4382099

Please sign in to comment.