Skip to content

Ensure PrestaShop 9 compatibility#201

Merged
BitcoinMitchell merged 6 commits into6.xfrom
ps-9
Sep 19, 2025
Merged

Ensure PrestaShop 9 compatibility#201
BitcoinMitchell merged 6 commits into6.xfrom
ps-9

Conversation

@BitcoinMitchell
Copy link
Collaborator

Description

Since PrestaShop has released their latest major version, it is time that we upgrade our module as well.

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Refactor (non-breaking change which improves the codebase)

How Has This Been Tested?

I ran PrestaShop 9 locally (using BTCPay Server Testnet) and kept fixing issues until it worked. I then tested the module on my shop that still runs PrestaShop 8. All good.

Test Configuration:

  • BTCPay Server version: v2.1.5 / v2.2.1+790616d2a
  • PrestaShop version: 9.0.0 / 8.2.1
  • PHP version: 8.4.12 / 8.2.27

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have checked my code and corrected any misspellings

btcpay v6.3.1.zip

@ndeet
Copy link
Contributor

ndeet commented Sep 18, 2025

Great work 🥳

tested successfully with PS 8.2.3 and 9.0 although I have noticed two things I'm unsure about

  1. the invoice is marked as paid and shown like that but the order status does not update automatically to "paid with crypto" (I'm not sure if this was always like that)

  2. on the printed invoice there is also no payment reference, I think from HTML code it looks like it should be there?

image

@BitcoinMitchell
Copy link
Collaborator Author

BitcoinMitchell commented Sep 18, 2025

  1. Seems to work fine for me, which is a horrible thing to say. Please double check your webhooks and if the network works properly.
  2. I just dug up two old invoices and it seems payment reference was never included in the PDF (at least not for PayPal, so probably also not for Bitcoin). Would be nice, but seems to work as before.
image

@ndeet
Copy link
Contributor

ndeet commented Sep 19, 2025

I paid with LN, so the order status is supposed to change automatically? In the "Sources" section of my screenshot you see the webhook callbacks, at least that's what I assumed as it logs the callback request from BTCPay?

For PDF invoice, my bad I assumed the invoice_block.tpl change was for the PDF but seems not. https://github.com/btcpayserver/prestashop-plugin/pull/201/files#diff-3e00442b379f3e02a495e1d09ff8061795a7b231545b076c673b2301830a1a4eR90

@BitcoinMitchell
Copy link
Collaborator Author

"Sources" is a Prestashop tracking thing. Unsure how it exactly works. The actual proper logging for the plugin you can find under Logs in Advanced Settings.

Will have a try with LN on mainnet, since I don't have a testing variant setup.

@ndeet
Copy link
Contributor

ndeet commented Sep 19, 2025

I tested again with LN and now the order status updated properly, maybe it was just some glitch due to my testing. So in that regard all good. If above mentioned invoice_block.tpl is not related to the PDF invoice and there is not supposed to be a listing of payments with transaction ids - we are good 🥳

@BitcoinMitchell
Copy link
Collaborator Author

Glad to hear it did work the second time around. Maybe some webhooks shenanigans. invoice_block.tpl is indeed used for the frontend, not the PDF itself.

Merging and taggin!

@BitcoinMitchell BitcoinMitchell merged commit 1bf5e7c into 6.x Sep 19, 2025
2 checks passed
@BitcoinMitchell BitcoinMitchell deleted the ps-9 branch September 19, 2025 08:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants