mirror of
https://github.com/vr-payment/shopware-6.git
synced 2026-06-05 11:36:37 +00:00
Compare commits
3 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 55bdb5c640 | |||
| d1a78fedcf | |||
| d7ea44d506 |
@@ -1,3 +1,14 @@
|
|||||||
|
# 7.1.5
|
||||||
|
- Improved analytics
|
||||||
|
- Improved error handling for refunding amount 0 and too many items
|
||||||
|
|
||||||
|
# 7.1.4
|
||||||
|
- Updated SDK to 4.8.1
|
||||||
|
|
||||||
|
# 7.1.3
|
||||||
|
- Fixed issue with radio button/switch settings not saving
|
||||||
|
- Fixed issue with error screen sporadically happening after failed payments
|
||||||
|
|
||||||
# 7.1.2
|
# 7.1.2
|
||||||
- Support the ability to have different spaces for differet sales channels
|
- Support the ability to have different spaces for differet sales channels
|
||||||
- Fixed issue where Twint would not appear sometimes
|
- Fixed issue where Twint would not appear sometimes
|
||||||
|
|||||||
@@ -1,3 +1,14 @@
|
|||||||
|
# 7.1.5
|
||||||
|
- Verbesserte Analysefunktionen
|
||||||
|
- Verbesserte Fehlerbehandlung bei Rückerstattungen von 0 Beträgen und zu vielen Artikeln
|
||||||
|
|
||||||
|
# 7.1.4
|
||||||
|
- Aktualisiertes SDK - 4.8.1
|
||||||
|
|
||||||
|
# 7.1.3
|
||||||
|
– Problem behoben, bei dem die Einstellungen von Optionsfeldern/Schaltern nicht gespeichert wurden.
|
||||||
|
– Problem behoben, bei dem nach fehlgeschlagenen Zahlungen sporadisch ein Fehlerbildschirm angezeigt wurde.
|
||||||
|
|
||||||
# 7.1.2
|
# 7.1.2
|
||||||
- Unterstützung der Möglichkeit, unterschiedliche Bereiche für verschiedene Vertriebskanäle zu nutzen.
|
- Unterstützung der Möglichkeit, unterschiedliche Bereiche für verschiedene Vertriebskanäle zu nutzen.
|
||||||
- Problem behoben, bei dem Twint manchmal nicht angezeigt wurde.
|
- Problem behoben, bei dem Twint manchmal nicht angezeigt wurde.
|
||||||
|
|||||||
@@ -13,10 +13,10 @@ Please note that this plugin is for versions 6.5, 6.6 or 6.7. For the 6.4 plugin
|
|||||||
|
|
||||||
## Documentation
|
## Documentation
|
||||||
|
|
||||||
- For English documentation click [here](https://docs.plugin-documentation.vr-payment.de/vr-payment/shopware-6/7.1.2/docs/en/documentation.html)
|
- For English documentation click [here](https://docs.plugin-documentation.vr-payment.de/vr-payment/shopware-6/7.1.5/docs/en/documentation.html)
|
||||||
- Für die deutsche Dokumentation klicken Sie [hier](https://docs.plugin-documentation.vr-payment.de/vr-payment/shopware-6/7.1.2/docs/de/documentation.html)
|
- Für die deutsche Dokumentation klicken Sie [hier](https://docs.plugin-documentation.vr-payment.de/vr-payment/shopware-6/7.1.5/docs/de/documentation.html)
|
||||||
- Pour la documentation Française, cliquez [ici](https://docs.plugin-documentation.vr-payment.de/vr-payment/shopware-6/7.1.2/docs/fr/documentation.html)
|
- Pour la documentation Française, cliquez [ici](https://docs.plugin-documentation.vr-payment.de/vr-payment/shopware-6/7.1.5/docs/fr/documentation.html)
|
||||||
- Per la documentazione in tedesco, clicca [qui](https://docs.plugin-documentation.vr-payment.de/vr-payment/shopware-6/7.1.2/docs/it/documentation.html)
|
- Per la documentazione in tedesco, clicca [qui](https://docs.plugin-documentation.vr-payment.de/vr-payment/shopware-6/7.1.5/docs/it/documentation.html)
|
||||||
|
|
||||||
## Installation
|
## Installation
|
||||||
|
|
||||||
@@ -48,6 +48,15 @@ bin/console plugin:install --activate --clearCache VRPayment
|
|||||||
1. Navigate to Shopware Admin > Settings > VRPayment.
|
1. Navigate to Shopware Admin > Settings > VRPayment.
|
||||||
2. Enter your Space ID, User ID, and API Key (obtained from the [VR Payment Portal](https://gateway.vr-payment.de/)).
|
2. Enter your Space ID, User ID, and API Key (obtained from the [VR Payment Portal](https://gateway.vr-payment.de/)).
|
||||||
|
|
||||||
|
### VRPayment does not appear in Settings
|
||||||
|
|
||||||
|
1. You should run the following commmand
|
||||||
|
|
||||||
|
```bash
|
||||||
|
Copy
|
||||||
|
bin/build-administration.sh
|
||||||
|
```
|
||||||
|
|
||||||
### Payment Methods
|
### Payment Methods
|
||||||
|
|
||||||
Configure supported methods (e.g., credit cards, Apple Pay) via the [VR Payment Portal](https://gateway.vr-payment.de/).
|
Configure supported methods (e.g., credit cards, Apple Pay) via the [VR Payment Portal](https://gateway.vr-payment.de/).
|
||||||
|
|||||||
+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": "7.1.2"
|
"version": "7.1.5"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -23,7 +23,7 @@
|
|||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a href="https://github.com/vr-payment/shopware-6/releases/tag/7.1.2/">
|
<a href="https://github.com/vr-payment/shopware-6/releases/tag/7.1.5/">
|
||||||
Source
|
Source
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
@@ -183,6 +183,19 @@ php bin/console plugin:install --activate --clearCache VRPayment</code></pre>
|
|||||||
</li>
|
</li>
|
||||||
</ol>
|
</ol>
|
||||||
</div> </div>
|
</div> </div>
|
||||||
|
</div> <div class="section" id="_vrpayment_erscheint_nicht_in_den_einstellungen">
|
||||||
|
<div class="section-title">
|
||||||
|
<h2>
|
||||||
|
<span class="title-number">4.4</span>VRPayment erscheint nicht in den Einstellungen </h2>
|
||||||
|
</div>
|
||||||
|
<div class="section-body">
|
||||||
|
<div class="paragraph">
|
||||||
|
<p>Folgender Befehl muss ausgeführt werden</p>
|
||||||
|
</div><div class="listingblock">
|
||||||
|
<div class="content">
|
||||||
|
<pre class="highlight"><code class="language-bash" data-lang="bash">bin/build-administration.sh</code></pre>
|
||||||
|
</div>
|
||||||
|
</div> </div>
|
||||||
</div> </div>
|
</div> </div>
|
||||||
</div> <div class="chapter" id="portal-startup-guide">
|
</div> <div class="chapter" id="portal-startup-guide">
|
||||||
<div class="chapter-title">
|
<div class="chapter-title">
|
||||||
@@ -888,6 +901,11 @@ A: Ja, das Plugin unterstützt Wallets wie Apple Pay.</p>
|
|||||||
<span class="item-number">4.3</span>
|
<span class="item-number">4.3</span>
|
||||||
<span class="item-title">Via Composer (Recommended)</span>
|
<span class="item-title">Via Composer (Recommended)</span>
|
||||||
</a>
|
</a>
|
||||||
|
</li> <li class="nav-level-2">
|
||||||
|
<a href="#_vrpayment_erscheint_nicht_in_den_einstellungen">
|
||||||
|
<span class="item-number">4.4</span>
|
||||||
|
<span class="item-title">VRPayment erscheint nicht in den Einstellungen</span>
|
||||||
|
</a>
|
||||||
</li> </ul>
|
</li> </ul>
|
||||||
</li> <li class="nav-level-1">
|
</li> <li class="nav-level-1">
|
||||||
<a href="#portal-startup-guide">
|
<a href="#portal-startup-guide">
|
||||||
|
|||||||
@@ -23,7 +23,7 @@
|
|||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a href="https://github.com/vr-payment/shopware-6/releases/tag/7.1.2/">
|
<a href="https://github.com/vr-payment/shopware-6/releases/tag/7.1.5/">
|
||||||
Source
|
Source
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
@@ -179,6 +179,19 @@ php bin/console plugin:install --activate --clearCache VRPayment</code></pre>
|
|||||||
</li>
|
</li>
|
||||||
</ol>
|
</ol>
|
||||||
</div> </div>
|
</div> </div>
|
||||||
|
</div> <div class="section" id="_vrpayment_does_not_appear_in_settings">
|
||||||
|
<div class="section-title">
|
||||||
|
<h2>
|
||||||
|
<span class="title-number">4.4</span>VRPayment does not appear in Settings </h2>
|
||||||
|
</div>
|
||||||
|
<div class="section-body">
|
||||||
|
<div class="paragraph">
|
||||||
|
<p>You should run the following commmand</p>
|
||||||
|
</div><div class="listingblock">
|
||||||
|
<div class="content">
|
||||||
|
<pre class="highlight"><code class="language-bash" data-lang="bash">bin/build-administration.sh</code></pre>
|
||||||
|
</div>
|
||||||
|
</div> </div>
|
||||||
</div> </div>
|
</div> </div>
|
||||||
</div> <div class="chapter" id="portal-startup-guide">
|
</div> <div class="chapter" id="portal-startup-guide">
|
||||||
<div class="chapter-title">
|
<div class="chapter-title">
|
||||||
@@ -905,6 +918,11 @@ tokenization, it can be used for subscriptions. The recurring payment is fully m
|
|||||||
<span class="item-number">4.3</span>
|
<span class="item-number">4.3</span>
|
||||||
<span class="item-title">Manual Installation</span>
|
<span class="item-title">Manual Installation</span>
|
||||||
</a>
|
</a>
|
||||||
|
</li> <li class="nav-level-2">
|
||||||
|
<a href="#_vrpayment_does_not_appear_in_settings">
|
||||||
|
<span class="item-number">4.4</span>
|
||||||
|
<span class="item-title">VRPayment does not appear in Settings</span>
|
||||||
|
</a>
|
||||||
</li> </ul>
|
</li> </ul>
|
||||||
</li> <li class="nav-level-1">
|
</li> <li class="nav-level-1">
|
||||||
<a href="#portal-startup-guide">
|
<a href="#portal-startup-guide">
|
||||||
|
|||||||
@@ -23,7 +23,7 @@
|
|||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a href="https://github.com/vr-payment/shopware-6/releases/tag/7.1.2/">
|
<a href="https://github.com/vr-payment/shopware-6/releases/tag/7.1.5/">
|
||||||
Source
|
Source
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
@@ -170,6 +170,19 @@ php bin/console plugin:install --activate --clearCache VRPayment</code></pre>
|
|||||||
php bin/console plugin:install --activate --clearCache VRPayment</code></pre>
|
php bin/console plugin:install --activate --clearCache VRPayment</code></pre>
|
||||||
</div>
|
</div>
|
||||||
</div> </div>
|
</div> </div>
|
||||||
|
</div> <div class="section" id="_si_vrpayment_n_apparaît_pas_dans_les_paramètres">
|
||||||
|
<div class="section-title">
|
||||||
|
<h2>
|
||||||
|
<span class="title-number">4.4</span>Si VRPayment n’apparaît pas dans les paramètres </h2>
|
||||||
|
</div>
|
||||||
|
<div class="section-body">
|
||||||
|
<div class="paragraph">
|
||||||
|
<p>Vous devez exécuter la commande suivante</p>
|
||||||
|
</div><div class="listingblock">
|
||||||
|
<div class="content">
|
||||||
|
<pre class="highlight"><code class="language-bash" data-lang="bash">bin/build-administration.sh</code></pre>
|
||||||
|
</div>
|
||||||
|
</div> </div>
|
||||||
</div> </div>
|
</div> </div>
|
||||||
</div> <div class="chapter" id="portal-startup-guide">
|
</div> <div class="chapter" id="portal-startup-guide">
|
||||||
<div class="chapter-title">
|
<div class="chapter-title">
|
||||||
@@ -876,6 +889,11 @@ A: Oui, le plugin prend en charge les portefeuilles comme Apple Pay.</p>
|
|||||||
<span class="item-number">4.3</span>
|
<span class="item-number">4.3</span>
|
||||||
<span class="item-title">Via Composer (Recommended)</span>
|
<span class="item-title">Via Composer (Recommended)</span>
|
||||||
</a>
|
</a>
|
||||||
|
</li> <li class="nav-level-2">
|
||||||
|
<a href="#_si_vrpayment_n_apparaît_pas_dans_les_paramètres">
|
||||||
|
<span class="item-number">4.4</span>
|
||||||
|
<span class="item-title">Si VRPayment n&#8217;apparaît pas dans les paramètres</span>
|
||||||
|
</a>
|
||||||
</li> </ul>
|
</li> </ul>
|
||||||
</li> <li class="nav-level-1">
|
</li> <li class="nav-level-1">
|
||||||
<a href="#portal-startup-guide">
|
<a href="#portal-startup-guide">
|
||||||
|
|||||||
@@ -23,7 +23,7 @@
|
|||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<a href="https://github.com/vr-payment/shopware-6/releases/tag/7.1.2/">
|
<a href="https://github.com/vr-payment/shopware-6/releases/tag/7.1.5/">
|
||||||
Source
|
Source
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
@@ -177,6 +177,19 @@ php bin/console plugin:install --activate --clearCache VRPayment</code></pre>
|
|||||||
</li>
|
</li>
|
||||||
</ol>
|
</ol>
|
||||||
</div> </div>
|
</div> </div>
|
||||||
|
</div> <div class="section" id="_vrpayment_non_appare_nelle_impostazioni">
|
||||||
|
<div class="section-title">
|
||||||
|
<h2>
|
||||||
|
<span class="title-number">4.4</span>VRPayment non appare nelle impostazioni </h2>
|
||||||
|
</div>
|
||||||
|
<div class="section-body">
|
||||||
|
<div class="paragraph">
|
||||||
|
<p>Dovrebbe eseguire il seguente comando</p>
|
||||||
|
</div><div class="listingblock">
|
||||||
|
<div class="content">
|
||||||
|
<pre class="highlight"><code class="language-bash" data-lang="bash">bin/build-administration.sh</code></pre>
|
||||||
|
</div>
|
||||||
|
</div> </div>
|
||||||
</div> </div>
|
</div> </div>
|
||||||
</div> <div class="chapter" id="portal-startup-guide">
|
</div> <div class="chapter" id="portal-startup-guide">
|
||||||
<div class="chapter-title">
|
<div class="chapter-title">
|
||||||
@@ -887,6 +900,11 @@ La tokenizzazione non è disponibile per i checkout degli ospiti.
|
|||||||
<span class="item-number">4.3</span>
|
<span class="item-number">4.3</span>
|
||||||
<span class="item-title">Installazione manuale</span>
|
<span class="item-title">Installazione manuale</span>
|
||||||
</a>
|
</a>
|
||||||
|
</li> <li class="nav-level-2">
|
||||||
|
<a href="#_vrpayment_non_appare_nelle_impostazioni">
|
||||||
|
<span class="item-number">4.4</span>
|
||||||
|
<span class="item-title">VRPayment non appare nelle impostazioni</span>
|
||||||
|
</a>
|
||||||
</li> </ul>
|
</li> </ul>
|
||||||
</li> <li class="nav-level-1">
|
</li> <li class="nav-level-1">
|
||||||
<a href="#portal-startup-guide">
|
<a href="#portal-startup-guide">
|
||||||
|
|||||||
@@ -661,6 +661,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);
|
||||||
|
|
||||||
@@ -681,6 +688,22 @@ class PaymentMethodConfigurationService {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private function checkMediaAlreadyExists($paymentMethodUrl, $context) {
|
||||||
|
// detect if collision, return existing id
|
||||||
|
if (preg_match('#/([^/]+)\.[^/.]+$#', $paymentMethodUrl, $matches)) {
|
||||||
|
$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.
|
||||||
*
|
*
|
||||||
|
|||||||
@@ -13,6 +13,7 @@ use Symfony\Component\{
|
|||||||
};
|
};
|
||||||
use VRPaymentPayment\Core\{
|
use VRPaymentPayment\Core\{
|
||||||
Api\Refund\Service\RefundService,
|
Api\Refund\Service\RefundService,
|
||||||
|
Api\Transaction\Service\TransactionService,
|
||||||
Settings\Service\SettingsService
|
Settings\Service\SettingsService
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -41,16 +42,23 @@ class RefundController extends AbstractController
|
|||||||
*/
|
*/
|
||||||
protected $logger;
|
protected $logger;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @var \VRPaymentPayment\Core\Api\Transaction\Service\TransactionService
|
||||||
|
*/
|
||||||
|
protected $transactionService;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* RefundController constructor.
|
* RefundController constructor.
|
||||||
*
|
*
|
||||||
* @param \VRPaymentPayment\Core\Api\Refund\Service\RefundService $refundService
|
* @param \VRPaymentPayment\Core\Api\Refund\Service\RefundService $refundService
|
||||||
* @param \VRPaymentPayment\Core\Settings\Service\SettingsService $settingsService
|
* @param \VRPaymentPayment\Core\Settings\Service\SettingsService $settingsService
|
||||||
|
* @param \VRPaymentPayment\Core\Api\Transaction\Service\TransactionService $transactionService
|
||||||
*/
|
*/
|
||||||
public function __construct(RefundService $refundService, SettingsService $settingsService)
|
public function __construct(RefundService $refundService, SettingsService $settingsService, TransactionService $transactionService)
|
||||||
{
|
{
|
||||||
$this->settingsService = $settingsService;
|
$this->settingsService = $settingsService;
|
||||||
$this->refundService = $refundService;
|
$this->refundService = $refundService;
|
||||||
|
$this->transactionService = $transactionService;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -82,11 +90,23 @@ class RefundController extends AbstractController
|
|||||||
$quantity = (int)$request->request->get('quantity');
|
$quantity = (int)$request->request->get('quantity');
|
||||||
$lineItemId = $request->request->get('lineItemId');
|
$lineItemId = $request->request->get('lineItemId');
|
||||||
|
|
||||||
|
if ($quantity === null || $quantity <= 0) {
|
||||||
|
return new Response('refundQuantityZero', Response::HTTP_BAD_REQUEST);
|
||||||
|
}
|
||||||
|
|
||||||
$settings = $this->settingsService->getSettings($salesChannelId);
|
$settings = $this->settingsService->getSettings($salesChannelId);
|
||||||
$apiClient = $settings->getApiClient();
|
$apiClient = $settings->getApiClient();
|
||||||
|
|
||||||
$transaction = $apiClient->getTransactionService()->read($settings->getSpaceId(), $transactionId);
|
$transaction = $apiClient->getTransactionService()->read($settings->getSpaceId(), $transactionId);
|
||||||
|
|
||||||
|
$maxQuantity = $this->refundService->getMaxRefundableQuantity($transaction, $context, $lineItemId);
|
||||||
|
|
||||||
|
if ($quantity > $maxQuantity) {
|
||||||
|
return new Response('refundExceedsQuantity', Response::HTTP_BAD_REQUEST);
|
||||||
|
}
|
||||||
|
|
||||||
$refund = $this->refundService->create($transaction, $context, $lineItemId, $quantity);
|
$refund = $this->refundService->create($transaction, $context, $lineItemId, $quantity);
|
||||||
|
|
||||||
if ($refund === null) {
|
if ($refund === null) {
|
||||||
return new Response('Refund was not created. Please check the refund amound or if the item was not refunded before', Response::HTTP_BAD_REQUEST);
|
return new Response('Refund was not created. Please check the refund amound or if the item was not refunded before', Response::HTTP_BAD_REQUEST);
|
||||||
}
|
}
|
||||||
@@ -111,10 +131,23 @@ class RefundController extends AbstractController
|
|||||||
$transactionId = $request->request->get('transactionId');
|
$transactionId = $request->request->get('transactionId');
|
||||||
$refundableAmount = $request->request->get('refundableAmount');
|
$refundableAmount = $request->request->get('refundableAmount');
|
||||||
|
|
||||||
|
if ($refundableAmount === null || $refundableAmount <= 0.0) {
|
||||||
|
return new Response('refundAmountZero', Response::HTTP_BAD_REQUEST);
|
||||||
|
}
|
||||||
|
|
||||||
$settings = $this->settingsService->getSettings($salesChannelId);
|
$settings = $this->settingsService->getSettings($salesChannelId);
|
||||||
$apiClient = $settings->getApiClient();
|
$apiClient = $settings->getApiClient();
|
||||||
|
|
||||||
$transaction = $apiClient->getTransactionService()->read($settings->getSpaceId(), $transactionId);
|
$transaction = $apiClient->getTransactionService()->read($settings->getSpaceId(), $transactionId);
|
||||||
|
|
||||||
|
$completed = (float) $transaction->getCompletedAmount();
|
||||||
|
$refunded = (float) $transaction->getRefundedAmount();
|
||||||
|
$maxRefund = round($completed - $refunded, 2);
|
||||||
|
|
||||||
|
if ($refundableAmount > $maxRefund) {
|
||||||
|
return new Response('refundExceedsAmount', Response::HTTP_BAD_REQUEST);
|
||||||
|
}
|
||||||
|
|
||||||
$refund = $this->refundService->createRefundByAmount($transaction, $refundableAmount, $context);
|
$refund = $this->refundService->createRefundByAmount($transaction, $refundableAmount, $context);
|
||||||
|
|
||||||
if ($refund === null) {
|
if ($refund === null) {
|
||||||
|
|||||||
@@ -12,7 +12,11 @@ use Shopware\Core\{
|
|||||||
};
|
};
|
||||||
use VRPayment\Sdk\{
|
use VRPayment\Sdk\{
|
||||||
Model\Refund,
|
Model\Refund,
|
||||||
Model\Transaction
|
Model\Transaction,
|
||||||
|
Model\CriteriaOperator,
|
||||||
|
Model\EntityQueryFilter,
|
||||||
|
Model\EntityQueryFilterType,
|
||||||
|
Model\EntityQuery,
|
||||||
};
|
};
|
||||||
use VRPaymentPayment\Core\{
|
use VRPaymentPayment\Core\{
|
||||||
Api\Refund\Entity\RefundEntity,
|
Api\Refund\Entity\RefundEntity,
|
||||||
@@ -241,4 +245,67 @@ class RefundService
|
|||||||
->first();
|
->first();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get total refunded quantity for transaction's line item by lineItemId.
|
||||||
|
*
|
||||||
|
* @param \VRPayment\Sdk\Model\Transaction $transaction
|
||||||
|
* @param \Shopware\Core\Framework\Context $context
|
||||||
|
* @param string $lineItemId
|
||||||
|
*
|
||||||
|
* @return int
|
||||||
|
*/
|
||||||
|
public function getRefundedQuantity(Transaction $transaction, Context $context, string $lineItemId): int {
|
||||||
|
$transactionEntity = $this->getTransactionEntityByTransactionId($transaction->getId(), $context);
|
||||||
|
$settings = $this->settingsService->getSettings($transactionEntity->getSalesChannel()->getId());
|
||||||
|
$apiClient = $settings->getApiClient();
|
||||||
|
|
||||||
|
$entityQueryFilter = (new EntityQueryFilter())
|
||||||
|
->setType(EntityQueryFilterType::LEAF)
|
||||||
|
->setOperator(CriteriaOperator::EQUALS)
|
||||||
|
->setFieldName('transaction.id')
|
||||||
|
->setValue($transaction->getId());
|
||||||
|
|
||||||
|
$query = (new EntityQuery())->setFilter($entityQueryFilter);
|
||||||
|
|
||||||
|
$refunds = $apiClient->getRefundService()->search($settings->getSpaceId(), $query);
|
||||||
|
|
||||||
|
$refundedQuantity = 0;
|
||||||
|
|
||||||
|
foreach ($refunds as $refund) {
|
||||||
|
foreach ($refund->getReductions() as $reduction) {
|
||||||
|
if ($reduction->getLineItemUniqueId() === $lineItemId) {
|
||||||
|
$refundedQuantity += (int) $reduction->getQuantityReduction();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return $refundedQuantity;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get maximum quantity of available items to refund for line item.
|
||||||
|
*
|
||||||
|
* @param \VRPayment\Sdk\Model\Transaction $transaction
|
||||||
|
* @param \Shopware\Core\Framework\Context $context
|
||||||
|
* @param string $lineItemId
|
||||||
|
*
|
||||||
|
* @return int
|
||||||
|
*/
|
||||||
|
public function getMaxRefundableQuantity(Transaction $transaction, Context $context, string $lineItemId): int {
|
||||||
|
|
||||||
|
$originalQuantity = 0;
|
||||||
|
|
||||||
|
foreach ($transaction->getLineItems() as $lineItem) {
|
||||||
|
if ($lineItem->getUniqueId() === $lineItemId) {
|
||||||
|
$originalQuantity = (int) $lineItem->getQuantity();
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
$refundedQuantity = $this->getRefundedQuantity($transaction, $context, $lineItemId);
|
||||||
|
|
||||||
|
$maxQuantity = $originalQuantity - $refundedQuantity;
|
||||||
|
|
||||||
|
return $maxQuantity;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -45,7 +45,8 @@ use VRPaymentPayment\Core\{
|
|||||||
Settings\Service\SettingsService,
|
Settings\Service\SettingsService,
|
||||||
Util\LocaleCodeProvider,
|
Util\LocaleCodeProvider,
|
||||||
Util\Payload\CustomProducts\CustomProductsLineItemTypes,
|
Util\Payload\CustomProducts\CustomProductsLineItemTypes,
|
||||||
Util\Payload\TransactionPayload
|
Util\Payload\TransactionPayload,
|
||||||
|
Util\Analytics\Analytics
|
||||||
};
|
};
|
||||||
use Shopware\Core\Checkout\Order\Aggregate\OrderLineItem\OrderLineItemEntity;
|
use Shopware\Core\Checkout\Order\Aggregate\OrderLineItem\OrderLineItemEntity;
|
||||||
use Shopware\Core\Framework\Struct\ArrayEntity;
|
use Shopware\Core\Framework\Struct\ArrayEntity;
|
||||||
@@ -221,9 +222,14 @@ class TransactionService
|
|||||||
$spaceId = $settings->getSpaceId();
|
$spaceId = $settings->getSpaceId();
|
||||||
}
|
}
|
||||||
|
|
||||||
$sdkTransaction = $settings->getApiClient()->getTransactionService()->create($spaceId, $sdkTransactionCreate);
|
$apiClient = $settings->getApiClient();
|
||||||
|
Analytics::addHeaders($apiClient, [
|
||||||
|
Analytics::SUBSCRIPTION_TRANSACTION => true
|
||||||
|
]);
|
||||||
|
|
||||||
|
$sdkTransaction = $apiClient->getTransactionService()->create($spaceId, $sdkTransactionCreate);
|
||||||
if ($sdkTransaction->valid()) {
|
if ($sdkTransaction->valid()) {
|
||||||
return $settings->getApiClient()->getTransactionService()->processWithoutUserInteraction($spaceId, $sdkTransaction->getId());
|
return $apiClient->getTransactionService()->processWithoutUserInteraction($spaceId, $sdkTransaction->getId());
|
||||||
}
|
}
|
||||||
|
|
||||||
throw new \Exception("The transacion is not valid and could not be created.");
|
throw new \Exception("The transacion is not valid and could not be created.");
|
||||||
|
|||||||
@@ -133,7 +133,20 @@ class VRPaymentPaymentHandler extends AbstractPaymentHandler
|
|||||||
$salesChannelContextId = $contextSource->getSalesChannelId();
|
$salesChannelContextId = $contextSource->getSalesChannelId();
|
||||||
}
|
}
|
||||||
|
|
||||||
$parameters = new SalesChannelContextServiceParameters($salesChannelContextId, $request->getSession()->get("sw-context-token", Random::getAlphanumericString(32)), originalContext: $context);
|
$orderCustomer = $orderTransaction->getOrder()?->getOrderCustomer();
|
||||||
|
|
||||||
|
if ($orderCustomer) {
|
||||||
|
$customerId = $orderCustomer->getCustomerId();
|
||||||
|
} else {
|
||||||
|
$customerId = null;
|
||||||
|
}
|
||||||
|
|
||||||
|
$parameters = new SalesChannelContextServiceParameters(
|
||||||
|
$salesChannelContextId,
|
||||||
|
$request->getSession()->get("sw-context-token", Random::getAlphanumericString(32)),
|
||||||
|
originalContext: $context,
|
||||||
|
customerId: $customerId
|
||||||
|
);
|
||||||
$salesChannelContext = $this->salesChannelContextService->get($parameters);
|
$salesChannelContext = $this->salesChannelContextService->get($parameters);
|
||||||
$redirectUrl = $transaction->getReturnUrl();
|
$redirectUrl = $transaction->getReturnUrl();
|
||||||
|
|
||||||
@@ -149,7 +162,7 @@ class VRPaymentPaymentHandler extends AbstractPaymentHandler
|
|||||||
$request->getSession()->remove('transactionId');
|
$request->getSession()->remove('transactionId');
|
||||||
$errorMessage = 'An error occurred during the communication with external payment gateway : ' . $e->getMessage();
|
$errorMessage = 'An error occurred during the communication with external payment gateway : ' . $e->getMessage();
|
||||||
$this->logger->critical($errorMessage);
|
$this->logger->critical($errorMessage);
|
||||||
throw PaymentException::customerCanceled($transaction->getOrderTransaction()->getId(), $errorMessage);
|
throw PaymentException::customerCanceled($orderTransactionId, $errorMessage);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -194,7 +207,7 @@ class VRPaymentPaymentHandler extends AbstractPaymentHandler
|
|||||||
]);
|
]);
|
||||||
$request->getSession()->remove('transactionId');
|
$request->getSession()->remove('transactionId');
|
||||||
$this->logger->info($errorMessage);
|
$this->logger->info($errorMessage);
|
||||||
throw PaymentException::customerCanceled($transaction->getOrderTransaction()->getId(), $errorMessage);
|
throw PaymentException::customerCanceled($orderTransactionId, $errorMessage);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
$this->orderTransactionStateHandler->paid($orderTransaction->getId(), $context);
|
$this->orderTransactionStateHandler->paid($orderTransaction->getId(), $context);
|
||||||
|
|||||||
@@ -15,6 +15,7 @@ class Analytics {
|
|||||||
public const SHOP_SYSTEM_VERSION = 'x-meta-shop-system-version';
|
public const SHOP_SYSTEM_VERSION = 'x-meta-shop-system-version';
|
||||||
public const SHOP_SYSTEM_AND_VERSION = 'x-meta-shop-system-and-version';
|
public const SHOP_SYSTEM_AND_VERSION = 'x-meta-shop-system-and-version';
|
||||||
public const PLUGIN_SYSTEM_VERSION = 'x-meta-plugin-version';
|
public const PLUGIN_SYSTEM_VERSION = 'x-meta-plugin-version';
|
||||||
|
public const SUBSCRIPTION_TRANSACTION = 'x-meta-subscription-transaction';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return array
|
* @return array
|
||||||
@@ -25,16 +26,17 @@ class Analytics {
|
|||||||
self::SHOP_SYSTEM => 'shopware',
|
self::SHOP_SYSTEM => 'shopware',
|
||||||
self::SHOP_SYSTEM_VERSION => '6',
|
self::SHOP_SYSTEM_VERSION => '6',
|
||||||
self::SHOP_SYSTEM_AND_VERSION => 'shopware-6',
|
self::SHOP_SYSTEM_AND_VERSION => 'shopware-6',
|
||||||
self::PLUGIN_SYSTEM_VERSION => '7.1.2',
|
self::PLUGIN_SYSTEM_VERSION => '7.1.5',
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param \VRPayment\Sdk\ApiClient $apiClient
|
* @param \VRPayment\Sdk\ApiClient $apiClient
|
||||||
*/
|
*/
|
||||||
public static function addHeaders(ApiClient &$apiClient)
|
public static function addHeaders(ApiClient &$apiClient, array $additionalHeaders = [])
|
||||||
{
|
{
|
||||||
$data = self::getDefaultData();
|
$data = self::getDefaultData();
|
||||||
|
$data = array_merge($data, $additionalHeaders);
|
||||||
foreach ($data as $key => $value) {
|
foreach ($data as $key => $value) {
|
||||||
$apiClient->addDefaultHeader($key, $value);
|
$apiClient->addDefaultHeader($key, $value);
|
||||||
}
|
}
|
||||||
|
|||||||
+9
-6
@@ -70,13 +70,16 @@ Component.register('vrpayment-order-action-refund-by-amount', {
|
|||||||
});
|
});
|
||||||
}).catch((errorResponse) => {
|
}).catch((errorResponse) => {
|
||||||
try {
|
try {
|
||||||
var errorTitle;
|
var errorTitle = errorResponse?.response?.data?.errors?.[0]?.title ?? this.$tc('vrpayment-order.refundAction.refundCreateError.errorTitle')
|
||||||
var errorMessage;
|
var errorMessage;
|
||||||
if (errorResponse.response.data == 'refundExceedsAmount') {
|
switch(errorResponse.response.data) {
|
||||||
errorTitle = this.$tc('vrpayment-order.refundAction.refundExceedsTotalError.title');
|
case 'refundAmountZero':
|
||||||
errorMessage = this.$tc('vrpayment-order.refundAction.refundExceedsTotalError.messageRefundAmountExceedsAvailableBalance');
|
errorMessage = this.$tc('vrpayment-order.refundAction.refundCreateError.messageRefundAmountIsZero');
|
||||||
} else {
|
break;
|
||||||
errorTitle = errorResponse.response.data.errors[0].title;
|
case 'refundExceedsAmount':
|
||||||
|
errorMessage = this.$tc('vrpayment-order.refundAction.refundCreateError.messageRefundAmountExceedsAvailableBalance');
|
||||||
|
break;
|
||||||
|
default:
|
||||||
errorMessage = errorResponse.response.data.errors[0].detail;
|
errorMessage = errorResponse.response.data.errors[0].detail;
|
||||||
}
|
}
|
||||||
this.createNotificationError({
|
this.createNotificationError({
|
||||||
|
|||||||
+1
@@ -9,6 +9,7 @@
|
|||||||
:max="this.$parent.$parent.itemRefundableQuantity"
|
:max="this.$parent.$parent.itemRefundableQuantity"
|
||||||
:min="0"
|
:min="0"
|
||||||
v-model="refundQuantity"
|
v-model="refundQuantity"
|
||||||
|
number-type="int"
|
||||||
:label="$tc('vrpayment-order.refund.refundQuantity.label')">
|
:label="$tc('vrpayment-order.refund.refundQuantity.label')">
|
||||||
</mt-number-field>
|
</mt-number-field>
|
||||||
|
|
||||||
|
|||||||
+14
-2
@@ -68,9 +68,21 @@ Component.register('vrpayment-order-action-refund', {
|
|||||||
});
|
});
|
||||||
}).catch((errorResponse) => {
|
}).catch((errorResponse) => {
|
||||||
try {
|
try {
|
||||||
|
var errorTitle = errorResponse?.response?.data?.errors?.[0]?.title ?? this.$tc('vrpayment-order.refundAction.refundCreateError.errorTitle')
|
||||||
|
var errorMessage;
|
||||||
|
switch(errorResponse.response.data) {
|
||||||
|
case 'refundQuantityZero':
|
||||||
|
errorMessage = this.$tc('vrpayment-order.refundAction.refundCreateError.messageRefundQuantityIsZero');
|
||||||
|
break;
|
||||||
|
case 'refundExceedsQuantity':
|
||||||
|
errorMessage = this.$tc('vrpayment-order.refundAction.refundCreateError.messageRefundQuantityExceedsAvailableBalance');
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
errorMessage = errorResponse.response.data.errors[0].detail;
|
||||||
|
}
|
||||||
this.createNotificationError({
|
this.createNotificationError({
|
||||||
title: errorResponse.response.data.errors[0].title,
|
title: errorTitle,
|
||||||
message: errorResponse.response.data.errors[0].detail,
|
message: errorMessage,
|
||||||
autoClose: false
|
autoClose: false
|
||||||
});
|
});
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
|
|||||||
@@ -78,9 +78,12 @@
|
|||||||
"successTitle": "Erfolg",
|
"successTitle": "Erfolg",
|
||||||
"maxAvailableItemsToRefund": "Maximal Verfügbare Artikel zum Erstatten",
|
"maxAvailableItemsToRefund": "Maximal Verfügbare Artikel zum Erstatten",
|
||||||
"maxAvailableAmountToRefund": "Maximal verfügbarer Erstattungsbetrag",
|
"maxAvailableAmountToRefund": "Maximal verfügbarer Erstattungsbetrag",
|
||||||
"refundExceedsTotalError": {
|
"refundCreateError": {
|
||||||
"title": "Fehler beim Erstellen der Rückerstattung.",
|
"errorTitle": "Fehler beim Erstellen der Rückerstattung.",
|
||||||
"messageRefundAmountExceedsAvailableBalance": "Der Rückerstattungsbetrag übersteigt das verfügbare Guthaben."
|
"messageRefundAmountExceedsAvailableBalance": "Der Rückerstattungsbetrag übersteigt das verfügbare Guthaben.",
|
||||||
|
"messageRefundAmountIsZero": "Der Rückerstattungsbetrag muss größer als 0 sein.",
|
||||||
|
"messageRefundQuantityExceedsAvailableBalance": "Rückerstattung nach Menge überschreitet die maximal verfügbare Anzahl an Artikeln zur Rückerstattung.",
|
||||||
|
"messageRefundQuantityIsZero": "Rückerstattung nach Menge muss größer als 0 sein."
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"transactionHistory": {
|
"transactionHistory": {
|
||||||
|
|||||||
@@ -9,7 +9,6 @@
|
|||||||
"void": "Cancel authorization",
|
"void": "Cancel authorization",
|
||||||
"refund-whole-line-item": "Refund whole line item",
|
"refund-whole-line-item": "Refund whole line item",
|
||||||
"refund-line-item-by-quantity": "Refund by quantity",
|
"refund-line-item-by-quantity": "Refund by quantity",
|
||||||
"refund-line-item-selected": "Rembourser sélectionnés",
|
|
||||||
"refund-line-item-selected": "Refund selected",
|
"refund-line-item-selected": "Refund selected",
|
||||||
"refund-line-item-parial": "Partial refund"
|
"refund-line-item-parial": "Partial refund"
|
||||||
}
|
}
|
||||||
@@ -79,9 +78,12 @@
|
|||||||
"successTitle": "Success",
|
"successTitle": "Success",
|
||||||
"maxAvailableItemsToRefund": "Maximum available items to refund",
|
"maxAvailableItemsToRefund": "Maximum available items to refund",
|
||||||
"maxAvailableAmountToRefund": "Maximum available amount to refund",
|
"maxAvailableAmountToRefund": "Maximum available amount to refund",
|
||||||
"refundExceedsTotalError": {
|
"refundCreateError": {
|
||||||
"title": "Error while creating the refund.",
|
"errorTitle": "Error while creating the refund.",
|
||||||
"messageRefundAmountExceedsAvailableBalance": "Refund amount exceeds available balance."
|
"messageRefundAmountExceedsAvailableBalance": "Refund amount exceeds available balance.",
|
||||||
|
"messageRefundAmountIsZero": "Refund amount must be greater than 0.",
|
||||||
|
"messageRefundQuantityExceedsAvailableBalance": "Refund by quantity exceeds maximum available items to refund.",
|
||||||
|
"messageRefundQuantityIsZero": "Refund by quantity must be greater than 0."
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"transactionHistory": {
|
"transactionHistory": {
|
||||||
|
|||||||
@@ -78,9 +78,12 @@
|
|||||||
"successTitle": "Succès",
|
"successTitle": "Succès",
|
||||||
"maxAvailableItemsToRefund": "Nombre maximum d'articles disponibles pour le remboursement",
|
"maxAvailableItemsToRefund": "Nombre maximum d'articles disponibles pour le remboursement",
|
||||||
"maxAvailableAmountToRefund": "Montant maximal disponible pour le remboursement",
|
"maxAvailableAmountToRefund": "Montant maximal disponible pour le remboursement",
|
||||||
"refundExceedsTotalError": {
|
"refundCreateError": {
|
||||||
"title": "Erreur lors de la création du remboursement.",
|
"errorTitle": "Erreur lors de la création du remboursement.",
|
||||||
"messageRefundAmountExceedsAvailableBalance": "Le montant du remboursement dépasse le solde disponible."
|
"messageRefundAmountExceedsAvailableBalance": "Le montant du remboursement dépasse le solde disponible.",
|
||||||
|
"messageRefundAmountIsZero": "Le montant du remboursement doit être supérieur à 0.",
|
||||||
|
"messageRefundQuantityExceedsAvailableBalance": "Le remboursement par quantité dépasse le nombre maximal d’articles remboursables.",
|
||||||
|
"messageRefundQuantityIsZero": "Le remboursement par quantité doit être supérieur à 0."
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"transactionHistory": {
|
"transactionHistory": {
|
||||||
|
|||||||
@@ -78,9 +78,12 @@
|
|||||||
"successTitle": "Successo",
|
"successTitle": "Successo",
|
||||||
"maxAvailableItemsToRefund": "Numero massimo di articoli disponibili da rimborsare",
|
"maxAvailableItemsToRefund": "Numero massimo di articoli disponibili da rimborsare",
|
||||||
"maxAvailableAmountToRefund": "Importo massimo disponibile per il rimborso",
|
"maxAvailableAmountToRefund": "Importo massimo disponibile per il rimborso",
|
||||||
"refundExceedsTotalError": {
|
"refundCreateError": {
|
||||||
"title": "Errore durante la creazione del rimborso.",
|
"errorTitle": "Errore durante la creazione del rimborso.",
|
||||||
"messageRefundAmountExceedsAvailableBalance": "LL'importo del rimborso supera il saldo disponibile."
|
"messageRefundAmountExceedsAvailableBalance": "LL'importo del rimborso supera il saldo disponibile.",
|
||||||
|
"messageRefundAmountIsZero": "L'importo del rimborso deve essere superiore a 0.",
|
||||||
|
"messageRefundQuantityExceedsAvailableBalance": "Il rimborso per quantità supera il numero massimo di articoli rimborsabili.",
|
||||||
|
"messageRefundQuantityIsZero": "Il rimborso per quantità deve essere maggiore di 0."
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"transactionHistory": {
|
"transactionHistory": {
|
||||||
|
|||||||
+8
-8
@@ -7,16 +7,16 @@
|
|||||||
:inheritedValue="selectedSalesChannelId == null ? null : allConfigs['null'][CONFIG_STOREFRONT_WEBHOOKS_UPDATE_ENABLED]"
|
:inheritedValue="selectedSalesChannelId == null ? null : allConfigs['null'][CONFIG_STOREFRONT_WEBHOOKS_UPDATE_ENABLED]"
|
||||||
:customInheritationCheckFunction="checkBoolFieldInheritance">
|
:customInheritationCheckFunction="checkBoolFieldInheritance">
|
||||||
<template #content="props">
|
<template #content="props">
|
||||||
<mt-switch
|
<sw-switch-field
|
||||||
:name="CONFIG_STOREFRONT_WEBHOOKS_UPDATE_ENABLED"
|
:name="CONFIG_STOREFRONT_WEBHOOKS_UPDATE_ENABLED"
|
||||||
bordered
|
bordered
|
||||||
:mapInheritance="props"
|
:mapInheritance="props"
|
||||||
:label="$tc('vrpayment-settings.settingForm.advancedOptions.webhooksUpdateEnabled.label')"
|
:label="$tc('vrpayment-settings.settingForm.advancedOptions.webhooksUpdateEnabled.label')"
|
||||||
:helpText="$tc('vrpayment-settings.settingForm.advancedOptions.webhooksUpdateEnabled.tooltipText')"
|
:helpText="$tc('vrpayment-settings.settingForm.advancedOptions.webhooksUpdateEnabled.tooltipText')"
|
||||||
:disabled="props.isInherited"
|
:disabled="props.isInherited"
|
||||||
:checked="props.currentValue"
|
:value="props.currentValue"
|
||||||
@update:checked="props.updateCurrentValue">
|
@update:value="props.updateCurrentValue">
|
||||||
</mt-switch>
|
</sw-switch-field>
|
||||||
</template>
|
</template>
|
||||||
</sw-inherit-wrapper>
|
</sw-inherit-wrapper>
|
||||||
|
|
||||||
@@ -25,16 +25,16 @@
|
|||||||
:inheritedValue="selectedSalesChannelId == null ? null : allConfigs['null'][CONFIG_STOREFRONT_PAYMENTS_UPDATE_ENABLED]"
|
:inheritedValue="selectedSalesChannelId == null ? null : allConfigs['null'][CONFIG_STOREFRONT_PAYMENTS_UPDATE_ENABLED]"
|
||||||
:customInheritationCheckFunction="checkBoolFieldInheritance">
|
:customInheritationCheckFunction="checkBoolFieldInheritance">
|
||||||
<template #content="props">
|
<template #content="props">
|
||||||
<mt-switch
|
<sw-switch-field
|
||||||
:name="CONFIG_STOREFRONT_PAYMENTS_UPDATE_ENABLED"
|
:name="CONFIG_STOREFRONT_PAYMENTS_UPDATE_ENABLED"
|
||||||
bordered
|
bordered
|
||||||
:mapInheritance="props"
|
:mapInheritance="props"
|
||||||
:label="$tc('vrpayment-settings.settingForm.advancedOptions.paymentsUpdateEnabled.label')"
|
:label="$tc('vrpayment-settings.settingForm.advancedOptions.paymentsUpdateEnabled.label')"
|
||||||
:helpText="$tc('vrpayment-settings.settingForm.advancedOptions.paymentsUpdateEnabled.tooltipText')"
|
:helpText="$tc('vrpayment-settings.settingForm.advancedOptions.paymentsUpdateEnabled.tooltipText')"
|
||||||
:disabled="props.isInherited"
|
:disabled="props.isInherited"
|
||||||
:checked="props.currentValue"
|
:value="props.currentValue"
|
||||||
@update:checked="props.updateCurrentValue">
|
@update:value="props.updateCurrentValue">
|
||||||
</mt-switch>
|
</sw-switch-field>
|
||||||
</template>
|
</template>
|
||||||
</sw-inherit-wrapper>
|
</sw-inherit-wrapper>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
+1
-1
@@ -15,7 +15,7 @@
|
|||||||
<sw-inherit-wrapper
|
<sw-inherit-wrapper
|
||||||
v-model:value="actualConfigData[CONFIG_SPACE_ID]"
|
v-model:value="actualConfigData[CONFIG_SPACE_ID]"
|
||||||
:inheritedValue="getInheritedValue(CONFIG_SPACE_ID)"
|
:inheritedValue="getInheritedValue(CONFIG_SPACE_ID)"
|
||||||
:customInheritationCheckFunction="checkNumberFieldInheritance">
|
@update:value="onSwitchInput">
|
||||||
<template #content="props">
|
<template #content="props">
|
||||||
<mt-number-field
|
<mt-number-field
|
||||||
:name="CONFIG_SPACE_ID"
|
:name="CONFIG_SPACE_ID"
|
||||||
|
|||||||
+8
-8
@@ -55,16 +55,16 @@
|
|||||||
:inheritedValue="selectedSalesChannelId == null ? null : allConfigs['null'][CONFIG_LINE_ITEM_CONSISTENCY_ENABLED]"
|
:inheritedValue="selectedSalesChannelId == null ? null : allConfigs['null'][CONFIG_LINE_ITEM_CONSISTENCY_ENABLED]"
|
||||||
:customInheritationCheckFunction="checkBoolFieldInheritance">
|
:customInheritationCheckFunction="checkBoolFieldInheritance">
|
||||||
<template #content="props">
|
<template #content="props">
|
||||||
<mt-switch
|
<sw-switch-field
|
||||||
:name="CONFIG_LINE_ITEM_CONSISTENCY_ENABLED"
|
:name="CONFIG_LINE_ITEM_CONSISTENCY_ENABLED"
|
||||||
bordered
|
bordered
|
||||||
:mapInheritance="props"
|
:mapInheritance="props"
|
||||||
:label="$tc('vrpayment-settings.settingForm.options.lineItemConsistencyEnabled.label')"
|
:label="$tc('vrpayment-settings.settingForm.options.lineItemConsistencyEnabled.label')"
|
||||||
:helpText="$tc('vrpayment-settings.settingForm.options.lineItemConsistencyEnabled.tooltipText')"
|
:helpText="$tc('vrpayment-settings.settingForm.options.lineItemConsistencyEnabled.tooltipText')"
|
||||||
:disabled="props.isInherited"
|
:disabled="props.isInherited"
|
||||||
:checked="props.currentValue"
|
:value="props.currentValue"
|
||||||
@update:checked="props.updateCurrentValue">
|
@update:value="props.updateCurrentValue">
|
||||||
</mt-switch>
|
</sw-switch-field>
|
||||||
</template>
|
</template>
|
||||||
</sw-inherit-wrapper>
|
</sw-inherit-wrapper>
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
@@ -75,16 +75,16 @@
|
|||||||
:inheritedValue="selectedSalesChannelId == null ? null : allConfigs['null'][CONFIG_EMAIL_ENABLED]"
|
:inheritedValue="selectedSalesChannelId == null ? null : allConfigs['null'][CONFIG_EMAIL_ENABLED]"
|
||||||
:customInheritationCheckFunction="checkBoolFieldInheritance">
|
:customInheritationCheckFunction="checkBoolFieldInheritance">
|
||||||
<template #content="props">
|
<template #content="props">
|
||||||
<mt-switch
|
<sw-switch-field
|
||||||
:name="CONFIG_EMAIL_ENABLED"
|
:name="CONFIG_EMAIL_ENABLED"
|
||||||
bordered
|
bordered
|
||||||
:mapInheritance="props"
|
:mapInheritance="props"
|
||||||
:label="$tc('vrpayment-settings.settingForm.options.emailEnabled.label')"
|
:label="$tc('vrpayment-settings.settingForm.options.emailEnabled.label')"
|
||||||
:helpText="$tc('vrpayment-settings.settingForm.options.emailEnabled.tooltipText')"
|
:helpText="$tc('vrpayment-settings.settingForm.options.emailEnabled.tooltipText')"
|
||||||
:disabled="props.isInherited"
|
:disabled="props.isInherited"
|
||||||
:checked="props.currentValue"
|
:value="props.currentValue"
|
||||||
@update:checked="props.updateCurrentValue">
|
@update:value="props.updateCurrentValue">
|
||||||
</mt-switch>
|
</sw-switch-field>
|
||||||
</template>
|
</template>
|
||||||
</sw-inherit-wrapper>
|
</sw-inherit-wrapper>
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|||||||
+4
-4
@@ -7,16 +7,16 @@
|
|||||||
:inheritedValue="selectedSalesChannelId == null ? null : allConfigs['null'][CONFIG_STOREFRONT_INVOICE_DOWNLOAD_ENABLED]"
|
:inheritedValue="selectedSalesChannelId == null ? null : allConfigs['null'][CONFIG_STOREFRONT_INVOICE_DOWNLOAD_ENABLED]"
|
||||||
:customInheritationCheckFunction="checkBoolFieldInheritance">
|
:customInheritationCheckFunction="checkBoolFieldInheritance">
|
||||||
<template #content="props">
|
<template #content="props">
|
||||||
<mt-switch
|
<sw-switch-field
|
||||||
:name="CONFIG_STOREFRONT_INVOICE_DOWNLOAD_ENABLED"
|
:name="CONFIG_STOREFRONT_INVOICE_DOWNLOAD_ENABLED"
|
||||||
bordered
|
bordered
|
||||||
:mapInheritance="props"
|
:mapInheritance="props"
|
||||||
:label="$tc('vrpayment-settings.settingForm.storefrontOptions.invoiceDownloadEnabled.label')"
|
:label="$tc('vrpayment-settings.settingForm.storefrontOptions.invoiceDownloadEnabled.label')"
|
||||||
:helpText="$tc('vrpayment-settings.settingForm.storefrontOptions.invoiceDownloadEnabled.tooltipText')"
|
:helpText="$tc('vrpayment-settings.settingForm.storefrontOptions.invoiceDownloadEnabled.tooltipText')"
|
||||||
:disabled="props.isInherited"
|
:disabled="props.isInherited"
|
||||||
:checked="props.currentValue"
|
:value="props.currentValue"
|
||||||
@update:checked="props.updateCurrentValue">
|
@update:value="props.updateCurrentValue">
|
||||||
</mt-switch>
|
</sw-switch-field>
|
||||||
</template>
|
</template>
|
||||||
</sw-inherit-wrapper>
|
</sw-inherit-wrapper>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
+1
File diff suppressed because one or more lines are too long
@@ -10,6 +10,7 @@
|
|||||||
<service id="VRPaymentPayment\Core\Api\Refund\Controller\RefundController" public="true">
|
<service id="VRPaymentPayment\Core\Api\Refund\Controller\RefundController" public="true">
|
||||||
<argument type="service" id="VRPaymentPayment\Core\Api\Refund\Service\RefundService"/>
|
<argument type="service" id="VRPaymentPayment\Core\Api\Refund\Service\RefundService"/>
|
||||||
<argument type="service" id="VRPaymentPayment\Core\Settings\Service\SettingsService"/>
|
<argument type="service" id="VRPaymentPayment\Core\Settings\Service\SettingsService"/>
|
||||||
|
<argument type="service" id="VRPaymentPayment\Core\Api\Transaction\Service\TransactionService"/>
|
||||||
<call method="setLogger">
|
<call method="setLogger">
|
||||||
<argument type="service" id="monolog.logger.vrpayment_payment"/>
|
<argument type="service" id="monolog.logger.vrpayment_payment"/>
|
||||||
</call>
|
</call>
|
||||||
|
|||||||
@@ -0,0 +1,25 @@
|
|||||||
|
{
|
||||||
|
"base": "/bundles/vrpaymentpayment/administration/",
|
||||||
|
"entryPoints": {
|
||||||
|
"v-r-payment-payment": {
|
||||||
|
"css": [
|
||||||
|
"/bundles/vrpaymentpayment/administration/assets/v-r-payment-payment-D4AH6HY2.css"
|
||||||
|
],
|
||||||
|
"dynamic": [],
|
||||||
|
"js": [
|
||||||
|
"/bundles/vrpaymentpayment/administration/assets/v-r-payment-payment-Cp2eQSV_.js"
|
||||||
|
],
|
||||||
|
"legacy": false,
|
||||||
|
"preload": []
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"legacy": false,
|
||||||
|
"metadatas": {},
|
||||||
|
"version": [
|
||||||
|
"7.1.0",
|
||||||
|
7,
|
||||||
|
1,
|
||||||
|
0
|
||||||
|
],
|
||||||
|
"viteServer": null
|
||||||
|
}
|
||||||
@@ -0,0 +1,11 @@
|
|||||||
|
{
|
||||||
|
"main.js": {
|
||||||
|
"file": "assets/v-r-payment-payment-Cp2eQSV_.js",
|
||||||
|
"name": "v-r-payment-payment",
|
||||||
|
"src": "main.js",
|
||||||
|
"isEntry": true,
|
||||||
|
"css": [
|
||||||
|
"assets/v-r-payment-payment-D4AH6HY2.css"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -0,0 +1 @@
|
|||||||
|
.sw-order-detail .sw-tabs{margin-top:40px}.sw-order-detail .sw-order-detail-base .mt-card-view__content{overflow-x:visible;overflow-y:visible}.vrpayment-order-detail__data{display:grid}.vrpayment-order-detail__heading{padding-top:15px}
|
||||||
Reference in New Issue
Block a user