Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
38 changes: 3 additions & 35 deletions UPGRADE.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
### UPGRADE FROM 1.6.1 to 1.6.2
### UPGRADE FROM 1.6.0 to 1.6.1

1. The following constructor signatures have been changed:

`Sylius\PayPalPlugin\Controller\CreatePayPalOrderFromCartAction`:
`Sylius\PayPalPlugin\Controller\CreatePayPalOrderFromCartAction`:
```diff
public function __construct(
private readonly ?Payum $payum,
Expand All @@ -16,23 +16,7 @@
)
```

### UPGRADE FROM 1.6.0 to 1.6.1

1. The following constructor signatures have been changed:

`Sylius\PayPalPlugin\Controller\UpdatePayPalOrderAction`:
```diff
public function __construct(
private readonly PaymentProviderInterface $paymentProvider,
private readonly CacheAuthorizeClientApiInterface $authorizeClientApi,
- private readonly OrderDetailsApiInterface $orderDetailsApi,
private readonly UpdateOrderApiInterface $updateOrderApi,
private readonly AddressFactoryInterface $addressFactory,
private readonly OrderProcessorInterface $orderProcessor,
)
```

`Sylius\PayPalPlugin\Model\PayPalPurchaseUnit`:
`Sylius\PayPalPlugin\Model\PayPalPurchaseUnit`:
```diff
public function __construct(
private readonly string $referenceId,
Expand All @@ -52,22 +36,6 @@
)
```

`Sylius\PayPalPlugin\Controller\ProcessPayPalOrderAction`:
```diff
public function __construct(
- private readonly OrderRepositoryInterface $orderRepository,
private readonly CustomerRepositoryInterface $customerRepository,
private readonly FactoryInterface $customerFactory,
private readonly AddressFactoryInterface $addressFactory,
private readonly ObjectManager $orderManager,
private readonly StateMachineFactoryInterface|StateMachineInterface $stateMachineFactory,
private readonly PaymentStateManagerInterface $paymentStateManager,
private readonly CacheAuthorizeClientApiInterface $authorizeClientApi,
private readonly OrderDetailsApiInterface $orderDetailsApi,
private readonly OrderProviderInterface $orderProvider,
)
```

### UPGRADE FROM 1.5.1 to 1.6.0

1. Support for Sylius 1.13 has been added, it is now the recommended Sylius version to use.
Expand Down
2 changes: 2 additions & 0 deletions src/Controller/ProcessPayPalOrderAction.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
use Sylius\Component\Core\Model\PaymentMethodInterface;
use Sylius\Component\Core\OrderCheckoutTransitions;
use Sylius\Component\Core\Repository\CustomerRepositoryInterface;
use Sylius\Component\Core\Repository\OrderRepositoryInterface;
use Sylius\Component\Resource\Factory\FactoryInterface;
use Sylius\PayPalPlugin\Api\CacheAuthorizeClientApiInterface;
use Sylius\PayPalPlugin\Api\OrderDetailsApiInterface;
Expand All @@ -35,6 +36,7 @@
final class ProcessPayPalOrderAction
{
public function __construct(
private readonly OrderRepositoryInterface $orderRepository,
private readonly CustomerRepositoryInterface $customerRepository,
private readonly FactoryInterface $customerFactory,
private readonly AddressFactoryInterface $addressFactory,
Expand Down
2 changes: 2 additions & 0 deletions src/Controller/UpdatePayPalOrderAction.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
use Sylius\Component\Core\Model\PaymentMethodInterface;
use Sylius\Component\Order\Processor\OrderProcessorInterface;
use Sylius\PayPalPlugin\Api\CacheAuthorizeClientApiInterface;
use Sylius\PayPalPlugin\Api\OrderDetailsApiInterface;
use Sylius\PayPalPlugin\Api\UpdateOrderApiInterface;
use Sylius\PayPalPlugin\Provider\PaymentProviderInterface;
use Symfony\Component\HttpFoundation\JsonResponse;
Expand All @@ -31,6 +32,7 @@ final class UpdatePayPalOrderAction
public function __construct(
private readonly PaymentProviderInterface $paymentProvider,
private readonly CacheAuthorizeClientApiInterface $authorizeClientApi,
private readonly OrderDetailsApiInterface $orderDetailsApi,
private readonly UpdateOrderApiInterface $updateOrderApi,
private readonly AddressFactoryInterface $addressFactory,
private readonly OrderProcessorInterface $orderProcessor,
Expand Down
1 change: 1 addition & 0 deletions src/Resources/config/services/controller.xml
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,7 @@
<service id="Sylius\PayPalPlugin\Controller\UpdatePayPalOrderAction">
<argument type="service" id="Sylius\PayPalPlugin\Provider\PaymentProviderInterface" />
<argument type="service" id="Sylius\PayPalPlugin\Api\CacheAuthorizeClientApiInterface" />
<argument type="service" id="Sylius\PayPalPlugin\Api\OrderDetailsApiInterface" />
<argument type="service" id="Sylius\PayPalPlugin\Api\UpdateOrderApiInterface" />
<argument type="service" id="sylius.factory.address" />
<argument type="service" id="sylius.order_processing.order_processor" />
Expand Down