Skip to content

Commit 0a800a0

Browse files
Release 3.3.8
1 parent 837aba6 commit 0a800a0

File tree

59 files changed

+804
-3354
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

59 files changed

+804
-3354
lines changed

README.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ This repository contains the PostFinance Checkout plugin that enables WooCommerc
1414

1515
## Documentation
1616

17-
* [Documentation](https://plugin-documentation.postfinance-checkout.ch/pfpayments/woocommerce/3.3.7/docs/en/documentation.html)
17+
* [Documentation](https://plugin-documentation.postfinance-checkout.ch/pfpayments/woocommerce/3.3.8/docs/en/documentation.html)
1818

1919
## Support
2020

@@ -31,7 +31,7 @@ ____________________________________________________________________________
3131

3232
## License
3333

34-
Please see the [license file](https://github.com/pfpayments/woocommerce/blob/3.3.7/LICENSE) for more information.
34+
Please see the [license file](https://github.com/pfpayments/woocommerce/blob/3.3.8/LICENSE) for more information.
3535

3636
## Privacy Policy
3737

changelog.txt

+8
Original file line numberDiff line numberDiff line change
@@ -912,3 +912,11 @@ Please ensure that in woocommerce->settings->tax, the "Round tax at subtotal lev
912912
- [Tested Against] Woocommerce 9.7.0
913913
- [Tested Against] PHP SDK 4.6.0
914914

915+
= 3.3.8 - Mar 31 2025 =
916+
- [Bugfix] Fix for taxes wrongly applied when coupons used and different tax rates
917+
- [Bugfix] Fix for incorrect line item names in the portal when discounts and taxes used
918+
- [Tested Against] PHP 8.2
919+
- [Tested Against] Wordpress 6.7
920+
- [Tested Against] Woocommerce 9.7.1
921+
- [Tested Against] PHP SDK 4.8.0
922+

docs/en/documentation.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ <h2>Documentation</h2> </div>
2323
</a>
2424
</li>
2525
<li>
26-
<a href="https://github.com/pfpayments/woocommerce/releases/tag/3.3.7/">
26+
<a href="https://github.com/pfpayments/woocommerce/releases/tag/3.3.8/">
2727
Source
2828
</a>
2929
</li>

includes/admin/class-wc-postfinancecheckout-admin-settings-page.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -205,7 +205,7 @@ public function get_default_settings() {
205205
$settings = array(
206206
array(
207207
'links' => array(
208-
'https://plugin-documentation.postfinance-checkout.ch/pfpayments/woocommerce/3.3.7/docs/en/documentation.html' => esc_html__( 'Documentation', 'woo-postfinancecheckout' ),
208+
'https://plugin-documentation.postfinance-checkout.ch/pfpayments/woocommerce/3.3.8/docs/en/documentation.html' => esc_html__( 'Documentation', 'woo-postfinancecheckout' ),
209209
'https://checkout.postfinance.ch/en-ch/user/signup' => esc_html__( 'Sign Up', 'woo-postfinancecheckout' ),
210210
),
211211
'type' => 'postfinancecheckout_links',

includes/class-wc-postfinancecheckout-migration.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -268,7 +268,7 @@ public static function check_version() {
268268
public static function plugin_row_meta( $links, $file ) {
269269
if ( WC_POSTFINANCECHECKOUT_PLUGIN_BASENAME === $file ) {
270270
$row_meta = array(
271-
'docs' => '<a href="https://plugin-documentation.postfinance-checkout.ch/pfpayments/woocommerce/3.3.7/docs/en/documentation.html" aria-label="' . esc_html__( 'View Documentation', 'woo-postfinancecheckout' ) . '">' . esc_html__( 'Documentation', 'woo-postfinancecheckout' ) . '</a>',
271+
'docs' => '<a href="https://plugin-documentation.postfinance-checkout.ch/pfpayments/woocommerce/3.3.8/docs/en/documentation.html" aria-label="' . esc_html__( 'View Documentation', 'woo-postfinancecheckout' ) . '">' . esc_html__( 'Documentation', 'woo-postfinancecheckout' ) . '</a>',
272272
);
273273

274274
return array_merge( $links, $row_meta );

includes/service/class-wc-postfinancecheckout-service-line-item.php

+7-10
Original file line numberDiff line numberDiff line change
@@ -357,16 +357,13 @@ private function calculate_discount_rates_proportionally( float $total_discount_
357357
$proportional_discount_amount = floor($total_discount_amount * ( $data['total'] / $total_amount ) * 100) / 100;
358358
}
359359

360-
$discounts[] = array(
361-
'rate_id' => $rate_id,
362-
'amount' => $proportional_discount_amount,
363-
'rate_percentage' => $rate_id,
364-
);
365-
$discounts[] = [
366-
'rate_id' => $rate_id,
367-
'amount' => $proportional_discount_amount,
368-
'rate_percentage' => $data['rate_percentage'],
369-
];
360+
if ( $proportional_discount_amount > 0 ) {
361+
$discounts[] = [
362+
'rate_id' => $rate_id,
363+
'amount' => $proportional_discount_amount,
364+
'rate_percentage' => $data['rate_percentage'],
365+
];
366+
}
370367
}
371368

372369
return $discounts;

postfinancecheckout-sdk/LICENSE

+1-1
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@
186186
same "printed page" as the copyright notice for easier
187187
identification within third-party archives.
188188

189-
Copyright 2024 wallee AG
189+
Copyright 2025 wallee AG
190190

191191
Licensed under the Apache License, Version 2.0 (the "License");
192192
you may not use this file except in compliance with the License.

postfinancecheckout-sdk/composer.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "postfinancecheckout/sdk",
3-
"version": "4.6.0",
3+
"version": "4.8.0",
44
"description": "PostFinance Checkout SDK for PHP",
55
"keywords": [
66
"postfinancecheckout",

postfinancecheckout-sdk/lib/ApiClient.php

+2-14
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ final class ApiClient {
4848
* @var array
4949
*/
5050
private $defaultHeaders = [
51-
'x-meta-sdk-version' => "4.6.0",
51+
'x-meta-sdk-version' => "4.8.0",
5252
'x-meta-sdk-language' => 'php',
5353
'x-meta-sdk-provider' => "PostFinance Checkout",
5454
];
@@ -58,7 +58,7 @@ final class ApiClient {
5858
*
5959
* @var string
6060
*/
61-
private $userAgent = 'PHP-Client/4.6.0/php';
61+
private $userAgent = 'PHP-Client/4.8.0/php';
6262

6363
/**
6464
* The path to the certificate authority file.
@@ -585,18 +585,6 @@ public function getAccountService() {
585585
return $this->accountService;
586586
}
587587

588-
protected $analyticsQueryService;
589-
590-
/**
591-
* @return \PostFinanceCheckout\Sdk\Service\AnalyticsQueryService
592-
*/
593-
public function getAnalyticsQueryService() {
594-
if(is_null($this->analyticsQueryService)){
595-
$this->analyticsQueryService = new \PostFinanceCheckout\Sdk\Service\AnalyticsQueryService($this);
596-
}
597-
return $this->analyticsQueryService;
598-
}
599-
600588
protected $applicationUserService;
601589

602590
/**

postfinancecheckout-sdk/lib/Configuration.php

+3-3
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ class Configuration
8080
*
8181
* @var string
8282
*/
83-
protected $userAgent = 'PostFinanceCheckout\Sdk/4.6.0/php';
83+
protected $userAgent = 'PostFinanceCheckout\Sdk/4.8.0/php';
8484

8585
/**
8686
* Debug switch (default set to false)
@@ -388,8 +388,8 @@ public static function toDebugReport()
388388
$report = 'PHP SDK (PostFinanceCheckout\Sdk) Debug Report:' . PHP_EOL;
389389
$report .= ' OS: ' . php_uname() . PHP_EOL;
390390
$report .= ' PHP Version: ' . PHP_VERSION . PHP_EOL;
391-
$report .= ' OpenAPI Spec Version: 4.6.0' . PHP_EOL;
392-
$report .= ' SDK Package Version: 4.6.0' . PHP_EOL;
391+
$report .= ' OpenAPI Spec Version: 4.8.0' . PHP_EOL;
392+
$report .= ' SDK Package Version: 4.8.0' . PHP_EOL;
393393
$report .= ' Temp Folder Path: ' . self::getDefaultConfiguration()->getTempFolderPath() . PHP_EOL;
394394

395395
return $report;

postfinancecheckout-sdk/lib/Model/AbstractWebhookListenerUpdate.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -244,7 +244,7 @@ public function getEnablePayloadSignatureAndState()
244244
/**
245245
* Sets enable_payload_signature_and_state
246246
*
247-
* @param bool $enable_payload_signature_and_state Whether signature header and state property are enabled in webhook payload.
247+
* @param bool $enable_payload_signature_and_state Whether signature header and 'state' property are enabled in webhook payload.
248248
*
249249
* @return $this
250250
*/

0 commit comments

Comments
 (0)