Skip to content

Commit

Permalink
Add soft deletes to Payment Types
Browse files Browse the repository at this point in the history
  • Loading branch information
mdpoulter committed Oct 13, 2024
1 parent 0adb2e4 commit 9e5b723
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
2 changes: 2 additions & 0 deletions src/TwoZero/Requests/PaymentTypes/ListPaymentTypes.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ public function resolveEndpoint(): string
public function __construct(
protected ?int $after = null,
protected ?int $before = null,
protected ?bool $deleted = null,
protected ?int $pageSize = null,
) {
}
Expand All @@ -27,6 +28,7 @@ public function defaultQuery(): array
return array_filter([
'after' => $this->after,
'before' => $this->before,
'deleted' => $this->deleted,
'page_size' => $this->pageSize,
]);
}
Expand Down
3 changes: 2 additions & 1 deletion src/TwoZero/Resources/PaymentTypes.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,9 @@ class PaymentTypes extends BaseResource
public function listPaymentTypes(
?int $after = null,
?int $before = null,
?bool $deleted = null,
?int $pageSize = null,
): Response {
return $this->connector->send(new ListPaymentTypes($after, $before, $pageSize));
return $this->connector->send(new ListPaymentTypes($after, $before, $deleted, $pageSize));
}
}

0 comments on commit 9e5b723

Please sign in to comment.