Skip to content

Commit ed5cc71

Browse files
author
root
committed
Release 2.1.7
1 parent 4503cb3 commit ed5cc71

18 files changed

+47
-32
lines changed

Block/Method/Info.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -225,7 +225,7 @@ public function getTransactionState()
225225
public function formatAmount($amount)
226226
{
227227
//NULL was changed to 0 because PHP8.1 does not allow NULL as parameter
228-
return $this->priceCurrency->format($amount, 0, 0, 0, $this->getTransaction()
228+
return $this->priceCurrency->format($amount, 0, PriceCurrencyInterface::DEFAULT_PRECISION, 0, $this->getTransaction()
229229
->getCurrency());
230230
}
231231
/**

Model/Service/Order/TransactionService.php

+2
Original file line numberDiff line numberDiff line change
@@ -515,6 +515,7 @@ public function void(Order $order)
515515

516516
/**
517517
* Marks the delivery indication belonging to the given payment as suitable.
518+
* Note: there are no delivery indication for Authorized transactions
518519
*
519520
* @param Order $order
520521
* @return \PostFinanceCheckout\Sdk\Model\DeliveryIndication
@@ -528,6 +529,7 @@ public function accept(Order $order)
528529

529530
/**
530531
* Marks the delivery indication belonging to the given payment as not suitable.
532+
* Note: there are no delivery indication for Authorized transactions
531533
*
532534
* @param Order $order
533535
* @return \PostFinanceCheckout\Sdk\Model\DeliveryIndication

Model/Webhook/Listener/Transaction/AuthorizedCommand.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ public function execute($entity, Order $order)
6363
$payment->registerAuthorizationNotification($entity->getAuthorizationAmount());
6464

6565
if ($entity->getState() != TransactionState::FULFILL) {
66-
$order->setState(Order::STATE_PAYMENT_REVIEW);
66+
$order->setState(Order::STATE_PENDING_PAYMENT);
6767
$order->addStatusToHistory('pending',
6868
\__('The order should not be fulfilled yet, as the payment is not guaranteed.'));
6969
}

Observer/CollectOrderAttributeMetaData.php

+16-10
Original file line numberDiff line numberDiff line change
@@ -65,15 +65,21 @@ public function execute(Observer $observer)
6565
*/
6666
protected function collectOrderAttributeMetaData(Order $order)
6767
{
68-
$metaData = [];
69-
/* @var \Amasty\Orderattr\Model\ResourceModel\Attribute\Collection $attributeCollection */
70-
$attributeCollection = $this->objectManager->get(
71-
'Amasty\Orderattr\Model\ResourceModel\Attribute\CollectionFactory')->create();
72-
$attributeCollection->addFieldToSelect('attribute_code');
73-
$attributeCollection->addFieldToSelect('frontend_label');
74-
foreach ($attributeCollection->getData() as $attribute) {
75-
$metaData['order_' . $attribute['attribute_code']] = $order->getData($attribute['attribute_code']);
76-
}
77-
return $metaData;
68+
$metaData = [];
69+
/* @var \Amasty\Orderattr\Model\ResourceModel\Attribute\Collection $attributeCollection */
70+
$attributeCollection = $this->objectManager->get(
71+
'Amasty\Orderattr\Model\ResourceModel\Attribute\CollectionFactory')->create();
72+
$attributeCollection->addFieldToSelect('attribute_code');
73+
$attributeCollection->addFieldToSelect('frontend_label');
74+
75+
$i = 0;
76+
foreach ($attributeCollection->getData() as $attribute) {
77+
if ( is_null($order->getData($attribute['attribute_code'])) || $i >= 25) {
78+
continue;
79+
}
80+
$metaData['order_' . $attribute['attribute_code']] = $order->getData($attribute['attribute_code']);
81+
$i++;
82+
}
83+
return $metaData;
7884
}
7985
}

README.md

+9-2
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,20 @@ This repository contains the Magento 2 extension that enables to process payment
1212

1313
## Documentation
1414

15-
* [Documentation](https://plugin-documentation.postfinance-checkout.ch/pfpayments/magento-2/2.1.6/docs/en/documentation.html)
15+
* [Documentation](https://plugin-documentation.postfinance-checkout.ch/pfpayments/magento-2/2.1.7/docs/en/documentation.html)
1616

1717

1818
## Support
1919

2020
Support queries can be issued on the [PostFinance Checkout support site](https://www.postfinance.ch/en/business/support.html).
2121

22+
## Supported versions
23+
24+
| Magento variant | min. supported version | max. supported version |
25+
|------------------------------|------------------------|------------------------|
26+
| Magento 2 Enterprise Edition | Contact us | Contact us |
27+
| Magento 2 Community Edition | 2.4.4 | 2.4.6 |
28+
2229

2330
## Supported One Step Checkouts
2431

@@ -30,4 +37,4 @@ We do provide special integrations for the following one step checkouts:
3037

3138
## License
3239

33-
Please see the [license file](https://github.com/pfpayments/magento-2/blob/2.1.6/LICENSE) for more information.
40+
Please see the [license file](https://github.com/pfpayments/magento-2/blob/2.1.7/LICENSE) for more information.

composer.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
}
1717
],
1818
"type" : "magento2-module",
19-
"version" : "2.1.6",
19+
"version" : "2.1.7",
2020
"require" : {
2121
"php" : "~7.1.3||~7.2.0||~7.3.0||~7.4.0||~8.0||~8.1",
2222
"magento/framework" : "^102.0.0||^103.0.0",

docs/en/documentation.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ <h2>Documentation</h2> </div>
2222
</a>
2323
</li>
2424
<li>
25-
<a href="https://github.com/pfpayments/magento-2/releases/tag/2.1.6/">
25+
<a href="https://github.com/pfpayments/magento-2/releases/tag/2.1.7/">
2626
Source
2727
</a>
2828
</li>

etc/adminhtml/system.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
<resource>PostFinanceCheckout_Payment::config</resource>
1919
<group id="information" translate="label comment" type="text" sortOrder="10" showInDefault="1" showInWebsite="1" showInStore="1">
2020
<label>Information</label>
21-
<comment><![CDATA[If you need help setting up the PostFinance Checkout extension, check out the <a href="https://plugin-documentation.postfinance-checkout.ch/pfpayments/magento-2/2.1.6/docs/en/documentation.html" target="_blank">documentation</a>.]]></comment>
21+
<comment><![CDATA[If you need help setting up the PostFinance Checkout extension, check out the <a href="https://plugin-documentation.postfinance-checkout.ch/pfpayments/magento-2/2.1.7/docs/en/documentation.html" target="_blank">documentation</a>.]]></comment>
2222
<field id="version" translate="label" type="label" sortOrder="10" showInDefault="1" showInWebsite="1" showInStore="1">
2323
<label>Module Version</label>
2424
</field>

etc/config.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
<default>
1515
<postfinancecheckout_payment>
1616
<information>
17-
<version>2.1.6</version>
17+
<version>2.1.7</version>
1818
<sdk_version>3.2.0</sdk_version>
1919
</information>
2020
<general>

etc/db_schema.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@
3838
<column xsi:type="text" name="language" nullable="false" comment="Language"/>
3939
<column xsi:type="text" name="currency" nullable="false" comment="Currency"/>
4040
<column xsi:type="timestamp" name="created_at" on_update="false" nullable="true" default="CURRENT_TIMESTAMP" comment="Created At"/>
41-
<column xsi:type="int" name="authorization_amount" unsigned="false" nullable="false" comment="Authorization Amount"/>
41+
<column xsi:type="decimal" name="authorization_amount" scale="4" precision="20" unsigned="false" nullable="false" comment="Authorization Amount"/>
4242
<column xsi:type="text" name="image" nullable="true" comment="Image"/>
4343
<column xsi:type="longtext" name="labels" nullable="true" comment="Labels"/>
4444
<column xsi:type="longtext" name="failure_reason" nullable="true" comment="Failure Reason"/>

etc/module.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
*/
1212
-->
1313
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:Module/etc/module.xsd">
14-
<module name="PostFinanceCheckout_Payment" setup_version="2.1.6">
14+
<module name="PostFinanceCheckout_Payment" setup_version="2.1.7">
1515
<sequence>
1616
<module name="Magento_Sales"/>
1717
<module name="Magento_Payment"/>

etc/schema.graphqls

+6-6
Original file line numberDiff line numberDiff line change
@@ -2,19 +2,19 @@ type Query {
22
customerOrderTransaction(
33
order_id: String! @doc(description: "Specify the increment id of the order.")
44
integration_type: String! @doc(description: "Sort of integration: 'JAVASCRIPT', 'LIGHTBOX', 'PAYMENTPAGE'.")
5-
): CustomerOrderTransactionOutput @resolver( class: "\\Wallee\\Payment\\Model\\Resolver\\CustomerOrderTransactionSettings") @doc(description: "Customer order transaction's settings") @cache(cacheable: false)
5+
): CustomerOrderTransactionOutput @resolver( class: "\\PostFinanceCheckout\\Payment\\Model\\Resolver\\CustomerOrderTransactionSettings") @doc(description: "Customer order transaction's settings") @cache(cacheable: false)
66
}
77

88
type Mutation {
9-
updateTransactionUrls(input: UpdateTransactionUrlsInput!): UpdateTransactionUrlsOutput @resolver( class: "\\Wallee\\Payment\\Model\\Resolver\\UpdateTransactionUrls") @doc(description: "Update transaction urls to redirect the customer after placing the order")
10-
restoreQuote(input: RestoreQuoteInput!): RestoreQuoteOutput @resolver( class: "\\Wallee\\Payment\\Model\\Resolver\\RestoreQuote") @doc(description: "restores a quote if payment fails or is cancelled")
9+
updateTransactionUrls(input: UpdateTransactionUrlsInput!): UpdateTransactionUrlsOutput @resolver( class: "\\PostFinanceCheckout\\Payment\\Model\\Resolver\\UpdateTransactionUrls") @doc(description: "Update transaction urls to redirect the customer after placing the order")
10+
restoreQuote(input: RestoreQuoteInput!): RestoreQuoteOutput @resolver( class: "\\PostFinanceCheckout\\Payment\\Model\\Resolver\\RestoreQuote") @doc(description: "restores a quote if payment fails or is cancelled")
1111
}
1212

1313
type CustomerOrderTransactionOutput {
1414
order_id: Int @doc(description: "Order id")
15-
transaction_id: Int @doc(description: "WhiteLabelMachineName transaction id")
16-
transaction_state: String @doc(description: "WhiteLabelMachineName transaction state")
17-
payment_url: String @doc(description: "WhiteLabelMachineName payment url to integrate external payment")
15+
transaction_id: Int @doc(description: "PostFinanceCheckout transaction id")
16+
transaction_state: String @doc(description: "PostFinanceCheckout transaction state")
17+
payment_url: String @doc(description: "PostFinanceCheckout payment url to integrate external payment")
1818
integration_type: String @doc(description: "Integration type")
1919
}
2020

i18n/de_DE.csv

+1-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@
5050
"Gift Wrap","Geschenkverpackung"
5151
"Hold Delivery","Lieferung halten"
5252
"ID required","ID erforderlich"
53-
"If you need help setting up the PostFinance Checkout extension, check out the <a href=""https://plugin-documentation.postfinance-checkout.ch/pfpayments/magento-2/2.1.6/docs/en/documentation.html"" target=""_blank"">documentation</a>.","Falls Sie Hilfe benötigen beim Einrichten der PostFinance Checkout-Erweiterung, sehen Sie sich die <a href=""https://plugin-documentation.postfinance-checkout.ch/pfpayments/magento-2/2.1.6/docs/en/documentation.html"" target=""_blank"">Dokumentation</a> an."
53+
"If you need help setting up the PostFinance Checkout extension, check out the <a href=""https://plugin-documentation.postfinance-checkout.ch/pfpayments/magento-2/2.1.7/docs/en/documentation.html"" target=""_blank"">documentation</a>.","Falls Sie Hilfe benötigen beim Einrichten der PostFinance Checkout-Erweiterung, sehen Sie sich die <a href=""https://plugin-documentation.postfinance-checkout.ch/pfpayments/magento-2/2.1.7/docs/en/documentation.html"" target=""_blank"">Dokumentation</a> an."
5454
"Inactive","Inaktiv"
5555
"Information","Informationen"
5656
"Invoice","Rechnung"

i18n/en_US.csv

+1-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@
5050
"Gift Wrap","Gift Wrap"
5151
"Hold Delivery","Hold Delivery"
5252
"ID required","ID required"
53-
"If you need help setting up the PostFinance Checkout extension, check out the <a href=""https://plugin-documentation.postfinance-checkout.ch/pfpayments/magento-2/2.1.6/docs/en/documentation.html"" target=""_blank"">documentation</a>.","If you need help setting up the PostFinance Checkout extension, check out the <a href=""https://plugin-documentation.postfinance-checkout.ch/pfpayments/magento-2/2.1.6/docs/en/documentation.html"" target=""_blank"">documentation</a>."
53+
"If you need help setting up the PostFinance Checkout extension, check out the <a href=""https://plugin-documentation.postfinance-checkout.ch/pfpayments/magento-2/2.1.7/docs/en/documentation.html"" target=""_blank"">documentation</a>.","If you need help setting up the PostFinance Checkout extension, check out the <a href=""https://plugin-documentation.postfinance-checkout.ch/pfpayments/magento-2/2.1.7/docs/en/documentation.html"" target=""_blank"">documentation</a>."
5454
"Inactive","Inactive"
5555
"Information","Information"
5656
"Invoice","Invoice"

i18n/fr_CH.csv

+1-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@
5050
"Gift Wrap","Papier cadeau"
5151
"Hold Delivery","Suspendre la livraison"
5252
"ID required","Pièce d'identité requise"
53-
"If you need help setting up the wallee extension, check out the <a href=""https://plugin-documentation.postfinance-checkout.ch/pfpayments/magento-2/2.1.6/docs/en/documentation.html"" target=""_blank"">documentation</a>.","Si vous avez besoin d'aide pour configurer l'extension wallee, consultez la <a href=""https://plugin-documentation.postfinance-checkout.ch/pfpayments/magento-2/2.1.6/docs/en/documentation.html"" target=""_blank"">documentation</a> an."
53+
"If you need help setting up the wallee extension, check out the <a href=""https://plugin-documentation.postfinance-checkout.ch/pfpayments/magento-2/2.1.7/docs/en/documentation.html"" target=""_blank"">documentation</a>.","Si vous avez besoin d'aide pour configurer l'extension wallee, consultez la <a href=""https://plugin-documentation.postfinance-checkout.ch/pfpayments/magento-2/2.1.7/docs/en/documentation.html"" target=""_blank"">documentation</a> an."
5454
"Inactive","Inactif"
5555
"Information","Information"
5656
"Invoice","Facture"

i18n/fr_FR.csv

+1-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@
5050
"Gift Wrap","Papier cadeau"
5151
"Hold Delivery","Suspendre la livraison"
5252
"ID required","Pièce d'identité requise"
53-
"If you need help setting up the wallee extension, check out the <a href=""https://plugin-documentation.postfinance-checkout.ch/pfpayments/magento-2/2.1.6/docs/en/documentation.html"" target=""_blank"">documentation</a>.","Si vous avez besoin d'aide pour configurer l'extension wallee, consultez la <a href=""https://plugin-documentation.postfinance-checkout.ch/pfpayments/magento-2/2.1.6/docs/en/documentation.html"" target=""_blank"">documentation</a> an."
53+
"If you need help setting up the wallee extension, check out the <a href=""https://plugin-documentation.postfinance-checkout.ch/pfpayments/magento-2/2.1.7/docs/en/documentation.html"" target=""_blank"">documentation</a>.","Si vous avez besoin d'aide pour configurer l'extension wallee, consultez la <a href=""https://plugin-documentation.postfinance-checkout.ch/pfpayments/magento-2/2.1.7/docs/en/documentation.html"" target=""_blank"">documentation</a> an."
5454
"Inactive","Inactif"
5555
"Information","Information"
5656
"Invoice","Facture"

i18n/it_CH.csv

+1-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@
5050
"Gift Wrap","Confezione regalo"
5151
"Hold Delivery","Sospendi la consegna"
5252
"ID required","ID richiesto"
53-
"If you need help setting up the wallee extension, check out the <a href=""https://plugin-documentation.postfinance-checkout.ch/pfpayments/magento-2/2.1.6/docs/en/documentation.html"" target=""_blank"">documentation</a>.","Se hai bisogno di aiuto per configurare l'estensione wallee, consulta la <a href=""https://plugin-documentation.postfinance-checkout.ch/pfpayments/magento-2/2.1.6/docs/en/documentation.html"" target=""_blank"">documentazione</a> an."
53+
"If you need help setting up the wallee extension, check out the <a href=""https://plugin-documentation.postfinance-checkout.ch/pfpayments/magento-2/2.1.7/docs/en/documentation.html"" target=""_blank"">documentation</a>.","Se hai bisogno di aiuto per configurare l'estensione wallee, consulta la <a href=""https://plugin-documentation.postfinance-checkout.ch/pfpayments/magento-2/2.1.7/docs/en/documentation.html"" target=""_blank"">documentazione</a> an."
5454
"Inactive","Inattivo"
5555
"Information","Informazione"
5656
"Invoice","Fattura"

i18n/it_IT.csv

+1-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@
5050
"Gift Wrap","Confezione regalo"
5151
"Hold Delivery","Sospendi la consegna"
5252
"ID required","ID richiesto"
53-
"If you need help setting up the wallee extension, check out the <a href=""https://plugin-documentation.postfinance-checkout.ch/pfpayments/magento-2/2.1.6/docs/en/documentation.html"" target=""_blank"">documentation</a>.","Se hai bisogno di aiuto per configurare l'estensione wallee, consulta la <a href=""https://plugin-documentation.postfinance-checkout.ch/pfpayments/magento-2/2.1.6/docs/en/documentation.html"" target=""_blank"">documentazione</a> an."
53+
"If you need help setting up the wallee extension, check out the <a href=""https://plugin-documentation.postfinance-checkout.ch/pfpayments/magento-2/2.1.7/docs/en/documentation.html"" target=""_blank"">documentation</a>.","Se hai bisogno di aiuto per configurare l'estensione wallee, consulta la <a href=""https://plugin-documentation.postfinance-checkout.ch/pfpayments/magento-2/2.1.7/docs/en/documentation.html"" target=""_blank"">documentazione</a> an."
5454
"Inactive","Inattivo"
5555
"Information","Informazione"
5656
"Invoice","Fattura"

0 commit comments

Comments
 (0)