mirror of
https://github.com/vr-payment/shopware-6.git
synced 2026-06-15 09:16:52 +00:00
Compare commits
2 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 36ec0cac03 | |||
| 219a13af6e |
@@ -1,3 +1,7 @@
|
|||||||
|
# 6.2.3
|
||||||
|
- Fix issue with cart clearing on payment method change
|
||||||
|
- Fixed issue with missing payment methods
|
||||||
|
|
||||||
# 6.2.1
|
# 6.2.1
|
||||||
- Fixed issue with multiple discount codes
|
- Fixed issue with multiple discount codes
|
||||||
|
|
||||||
|
|||||||
@@ -1,3 +1,7 @@
|
|||||||
|
# 6.2.3
|
||||||
|
- Problem mit dem Leeren des Warenkorbs bei Änderung der Zahlungsmethode behoben
|
||||||
|
- Problem mit fehlenden Zahlungsmethoden behoben
|
||||||
|
|
||||||
# 6.2.1
|
# 6.2.1
|
||||||
- Problem mit mehreren Rabattcodes behoben
|
- Problem mit mehreren Rabattcodes behoben
|
||||||
|
|
||||||
|
|||||||
@@ -13,10 +13,10 @@ The VR Payment Payment Plugin integrates modern payment processing into Shopware
|
|||||||
- **VR Payment Account:** Obtain `Space ID`, `User ID`, and `API Key` from the [VR Payment Dashboard](https://gateway.vr-payment.de/).
|
- **VR Payment Account:** Obtain `Space ID`, `User ID`, and `API Key` from the [VR Payment Dashboard](https://gateway.vr-payment.de/).
|
||||||
|
|
||||||
## Documentation
|
## Documentation
|
||||||
- For English documentation click [here](https://docs.plugin-documentation.vr-payment.de/vr-payment/shopware-6/6.2.1/docs/en/documentation.html)
|
- For English documentation click [here](https://docs.plugin-documentation.vr-payment.de/vr-payment/shopware-6/6.2.3/docs/en/documentation.html)
|
||||||
- Für die deutsche Dokumentation klicken Sie [hier](https://docs.plugin-documentation.vr-payment.de/vr-payment/shopware-6/6.2.1/docs/de/documentation.html)
|
- Für die deutsche Dokumentation klicken Sie [hier](https://docs.plugin-documentation.vr-payment.de/vr-payment/shopware-6/6.2.3/docs/de/documentation.html)
|
||||||
- Pour la documentation Française, cliquez [ici](https://docs.plugin-documentation.vr-payment.de/vr-payment/shopware-6/6.2.1/docs/fr/documentation.html)
|
- Pour la documentation Française, cliquez [ici](https://docs.plugin-documentation.vr-payment.de/vr-payment/shopware-6/6.2.3/docs/fr/documentation.html)
|
||||||
- Per la documentazione in tedesco, clicca [qui](https://docs.plugin-documentation.vr-payment.de/vr-payment/shopware-6/6.2.1/docs/it/documentation.html)
|
- Per la documentazione in tedesco, clicca [qui](https://docs.plugin-documentation.vr-payment.de/vr-payment/shopware-6/6.2.3/docs/it/documentation.html)
|
||||||
|
|
||||||
## Installation
|
## Installation
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -59,5 +59,5 @@
|
|||||||
"vrpayment/sdk": "^4.0.0"
|
"vrpayment/sdk": "^4.0.0"
|
||||||
},
|
},
|
||||||
"type": "shopware-platform-plugin",
|
"type": "shopware-platform-plugin",
|
||||||
"version": "6.2.1"
|
"version": "6.2.3"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -684,6 +684,13 @@ class PaymentMethodConfigurationService {
|
|||||||
], $context);
|
], $context);
|
||||||
|
|
||||||
// Media insert/update
|
// Media insert/update
|
||||||
|
|
||||||
|
// detect if collision, return existing id
|
||||||
|
$existingId = $this->checkMediaAlreadyExists($paymentMethodConfiguration->getResolvedImageUrl(), $context);
|
||||||
|
if ($existingId) {
|
||||||
|
return $existingId;
|
||||||
|
}
|
||||||
|
|
||||||
$mediaDefinition = $this->container->get(MediaDefinition::class);
|
$mediaDefinition = $this->container->get(MediaDefinition::class);
|
||||||
$this->mediaSerializer->setRegistry($this->serializerRegistry);
|
$this->mediaSerializer->setRegistry($this->serializerRegistry);
|
||||||
|
|
||||||
@@ -704,6 +711,32 @@ class PaymentMethodConfigurationService {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Check if the payment method icon is already uploaded.
|
||||||
|
*
|
||||||
|
* @param string $paymentMethodUrl
|
||||||
|
* @param \Shopware\Core\Framework\Context $context
|
||||||
|
*
|
||||||
|
* @return string|bool
|
||||||
|
*/
|
||||||
|
private function checkMediaAlreadyExists($paymentMethodUrl, $context) {
|
||||||
|
// detect if collision, return existing id
|
||||||
|
if (!preg_match('#/([^/]+)\.[^/.]+$#', $paymentMethodUrl, $matches)) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
$filename = $matches[1];
|
||||||
|
|
||||||
|
$criteria = new Criteria();
|
||||||
|
$criteria->addFilter(new EqualsFilter('fileName', $filename));
|
||||||
|
|
||||||
|
$existing = $this->mediaRepository->search($criteria, $context)->first();
|
||||||
|
|
||||||
|
if ($existing) {
|
||||||
|
return $existing->getId();
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Retrieves media default folder for a given payment method configuration.
|
* Retrieves media default folder for a given payment method configuration.
|
||||||
*
|
*
|
||||||
|
|||||||
@@ -698,16 +698,6 @@ class WebHookController extends AbstractController {
|
|||||||
private function unholdAndCancelDelivery(string $orderId, Context $context): void
|
private function unholdAndCancelDelivery(string $orderId, Context $context): void
|
||||||
{
|
{
|
||||||
$order = $this->getOrderEntity($orderId, $context);
|
$order = $this->getOrderEntity($orderId, $context);
|
||||||
try {
|
|
||||||
$this->orderService->orderStateTransition(
|
|
||||||
$order->getId(),
|
|
||||||
StateMachineTransitionActions::ACTION_CANCEL,
|
|
||||||
new ParameterBag(),
|
|
||||||
$context
|
|
||||||
);
|
|
||||||
} catch (\Exception $exception) {
|
|
||||||
$this->logger->info($exception->getMessage(), $exception->getTrace());
|
|
||||||
}
|
|
||||||
|
|
||||||
try {
|
try {
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -378,16 +378,6 @@ abstract class WebHookStrategyBase implements WebHookStrategyInterface {
|
|||||||
protected function unholdAndCancelDelivery(string $orderId, Context $context): void
|
protected function unholdAndCancelDelivery(string $orderId, Context $context): void
|
||||||
{
|
{
|
||||||
$order = $this->getOrderEntity($orderId, $context);
|
$order = $this->getOrderEntity($orderId, $context);
|
||||||
try {
|
|
||||||
$this->orderService->orderStateTransition(
|
|
||||||
$order->getId(),
|
|
||||||
StateMachineTransitionActions::ACTION_CANCEL,
|
|
||||||
new ParameterBag(),
|
|
||||||
$context
|
|
||||||
);
|
|
||||||
} catch (\Exception $exception) {
|
|
||||||
$this->logger->info($exception->getMessage(), $exception->getTrace());
|
|
||||||
}
|
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
|
||||||
|
|||||||
@@ -28,7 +28,7 @@ class Analytics {
|
|||||||
self::SHOP_SYSTEM => 'shopware',
|
self::SHOP_SYSTEM => 'shopware',
|
||||||
self::SHOP_SYSTEM_VERSION => $shopwareVersion,
|
self::SHOP_SYSTEM_VERSION => $shopwareVersion,
|
||||||
self::SHOP_SYSTEM_AND_VERSION => 'shopware-' . $shopwareVersion,
|
self::SHOP_SYSTEM_AND_VERSION => 'shopware-' . $shopwareVersion,
|
||||||
self::PLUGIN_SYSTEM_VERSION => '6.2.1',
|
self::PLUGIN_SYSTEM_VERSION => '6.2.3',
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user