From da5e34820d43bc1b2241b1827b9b5165b51eafe4 Mon Sep 17 00:00:00 2001 From: Testes Date: Thu, 25 Jul 2024 01:39:09 -0300 Subject: [PATCH] Fix order --- src/MercadoPago/Resources/Payment.php | 6 ++---- src/MercadoPago/Resources/Payment/Order.php | 15 +++++++++++++++ 2 files changed, 17 insertions(+), 4 deletions(-) create mode 100644 src/MercadoPago/Resources/Payment/Order.php diff --git a/src/MercadoPago/Resources/Payment.php b/src/MercadoPago/Resources/Payment.php index 2e86f6c1..114a5d49 100644 --- a/src/MercadoPago/Resources/Payment.php +++ b/src/MercadoPago/Resources/Payment.php @@ -26,11 +26,8 @@ class Payment extends MPResource /** Operation type. */ public ?string $operation_type; - /** Order ID. */ - public ?int $order_id; - /** Order. */ - public ?array $order; + public array|object|null $order; /** Brand ID. */ public ?string $brand_id; @@ -235,6 +232,7 @@ class Payment extends MPResource "payment_method" => "MercadoPago\Resources\Payment\PaymentMethod", "metadata" => "MercadoPago\Resources\Payment\Metadata", "three_ds_info" => "MercadoPago\Resources\Payment\ThreeDSInfo", + "order"=> "MercadoPago\Resources\Payment\Order" ]; /** diff --git a/src/MercadoPago/Resources/Payment/Order.php b/src/MercadoPago/Resources/Payment/Order.php new file mode 100644 index 00000000..1252c063 --- /dev/null +++ b/src/MercadoPago/Resources/Payment/Order.php @@ -0,0 +1,15 @@ +