Skip to content
This repository has been archived by the owner on Jul 9, 2024. It is now read-only.

Payment selection displays two buttons, and both of them are not working #5

Closed
lmeyer1 opened this issue Feb 17, 2022 · 3 comments
Closed

Comments

@lmeyer1
Copy link

lmeyer1 commented Feb 17, 2022

Describe the bug
When placing an order on Prestashop with Postfinance Checkout, the display of the page is not coherent, there are two buttons labelled I confirm my order, that do not have the same effect.
Additionally neither of both button confirms the order.

To Reproduce
On a default installation (see below for instructions for set up)
Steps to reproduce the behavior:

  1. Open the shop with Chrome

  2. Add a product to the cart

  3. Place the order, on step 5. Paiement, choose Carte Postfinance

  4. Notice the strange display with the two buttons

  5. Hit F12 to open Chrome Dev Console

  6. Click on the first button

  7. Note the error in the Dev console

     checkout.js:90 Uncaught TypeError: Cannot read properties of undefined (reading 'processing')
     at HTMLButtonElement.handler_submit (checkout.js:90:22)
     at HTMLButtonElement.dispatch (jquery-1.11.0.min.js:3:8066)
     at HTMLButtonElement.r.handle (jquery-1.11.0.min.js:3:4767)
    
  8. Click on the second button

  9. An empty page displays, with an error in Dev console
    2022-01-28_152409
    2022-01-28_152420

Expected behavior
We should be able to place an order.

Screenshots
There are two buttons I confirm my order
2022-01-28_152117

Software versions:

  • Prestashop: 1.6.1.24, fresh install, default demo data.
  • Postfinance Checkout: 1.2.17, latest version as of today
  • PHP: 7.1.32

Additional Info

About the Javascript error: the offending lines in file views/js/frontend/checkout.js are:

    handler_submit : function (event) {
        if(!self.processing) {
            var self = event.data.self;
            self.disable_pay_button();

Obviously var self = event.data.self; should precede if(!self.processing) {

Set up a clean installation
If you do not have a test environment to reproduce this issue, this is how to set up a default installation:

  • Get XAMPP Version 7.1.32 portable
  • Unzip Prestashop 1.6.24 in C:\xampp\htdocs\prestashop-1.6.1.24
  • In phpmyadmin create a database and a user
  • Install Prestashop the standard way, choose Switzerland as a country
  • In the BO, got to Transport - Carriers and activate the zone Europe non-EUfor shipping (This is necessary to be able to place orders from Switzerland, we installed Switzerland).
  • Install the latest version of Postfinance Checkout (currently 1.2.17)
@theodorspringwallee
Copy link
Contributor

Dear lmeyer1

Sorry for the late response.

Is this issue still relevant for you?

@lmeyer1
Copy link
Author

lmeyer1 commented Sep 29, 2022

Just a quick look at the code and the is still no translation in french. See #4

Are you kidding? This product is for Switzerland. Do you ignore that Switzerland has four national languages and is not only german speaking?

@lmeyer1
Copy link
Author

lmeyer1 commented Sep 30, 2022

@theodorspringwallee
You closed this issue as Fixed, what is not true. It would have been more honest to close it as Won't fix, wouldn't it ?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

No branches or pull requests

2 participants