From f91ade4296b591f007f34b828ffadf01f7651ae1 Mon Sep 17 00:00:00 2001 From: Simon Schurter Date: Mon, 3 Dec 2018 17:12:57 +0100 Subject: [PATCH] Release 1.0.36 --- README.md | 4 ++-- Subscriber/Webhook/AbstractOrderRelatedSubscriber.php | 6 ++---- composer.json | 2 +- docs/en/documentation.html | 2 +- plugin.xml | 2 +- 5 files changed, 7 insertions(+), 9 deletions(-) diff --git a/README.md b/README.md index f2b5f59..bbd323b 100644 --- a/README.md +++ b/README.md @@ -10,8 +10,8 @@ This repository contains the Shopware plugin that enables to process payments wi ## Documentation -* [Documentation](https://plugin-documentation.postfinance-checkout.ch/pfpayments/shopware-composer/1.0.35/docs/en/documentation.html) +* [Documentation](https://plugin-documentation.postfinance-checkout.ch/pfpayments/shopware-composer/1.0.36/docs/en/documentation.html) ## License -Please see the [license file](https://github.com/pfpayments/shopware-composer/blob/1.0.35/LICENSE) for more information. \ No newline at end of file +Please see the [license file](https://github.com/pfpayments/shopware-composer/blob/1.0.36/LICENSE) for more information. \ No newline at end of file diff --git a/Subscriber/Webhook/AbstractOrderRelatedSubscriber.php b/Subscriber/Webhook/AbstractOrderRelatedSubscriber.php index eb20cdb..ca2eba8 100644 --- a/Subscriber/Webhook/AbstractOrderRelatedSubscriber.php +++ b/Subscriber/Webhook/AbstractOrderRelatedSubscriber.php @@ -16,6 +16,7 @@ use Shopware\Components\Model\ModelManager; use Shopware\Models\Order\Order; use PostFinanceCheckoutPayment\Models\OrderTransactionMapping; +use Doctrine\DBAL\LockMode; abstract class AbstractOrderRelatedSubscriber extends AbstractSubscriber { @@ -56,10 +57,7 @@ public function process($entity) if (! ($orderTransactionMapping instanceof OrderTransactionMapping) || $orderTransactionMapping->getTransactionId() != $this->getTransactionId($entity)) { return; } - $this->modelManager->getRepository(OrderTransactionMapping::class)->createNamedQuery('lock')->setParameter('orderId', $order->getId())->execute(); - - $order = $this->modelManager->getRepository(Order::class)->find($order->getId()); - + $order = $this->modelManager->getRepository(Order::class)->find($order->getId(), LockMode::PESSIMISTIC_WRITE); $this->handleOrderRelatedInner($order, $entity); } diff --git a/composer.json b/composer.json index 4afc8ce..9b56a47 100644 --- a/composer.json +++ b/composer.json @@ -16,7 +16,7 @@ } ], "type": "shopware-plugin", - "version" : "1.0.35", + "version" : "1.0.36", "require": { "postfinancecheckout/sdk": "1.1.12" }, diff --git a/docs/en/documentation.html b/docs/en/documentation.html index 0cbf160..45ac52a 100644 --- a/docs/en/documentation.html +++ b/docs/en/documentation.html @@ -21,7 +21,7 @@

Documentation

  • - + Source
  • diff --git a/plugin.xml b/plugin.xml index 52df0b0..5f3d374 100644 --- a/plugin.xml +++ b/plugin.xml @@ -14,7 +14,7 @@ - 1.0.35 + 1.0.36 (c) by customweb ltd. ASL 2.0 https://www.postfinance.ch