It seems that customer's address information is not sent to Paytrail correctly. I was creating a custom hook to change the description and when I logged the API request I noticed that city (Espoo) is the current language code (en):

    [invoicingAddress] => stdClass Object
        (
            [streetAddress] => Metsäkukantie 4 F 11
            [postalCode] => 02330
            [city] => en
            [country] => FI
        )

And when I look at the two latest actual transactions (834372417 and 834210659) from the Paytrail Merchant Portal the address and the phone number fields are empty.

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

kaipipek created an issue. See original summary.

tuutti made their first commit to this issue’s fork.

tuutti’s picture

Status: Active » Fixed

Looks like I've autocompleted ->getLocality() to ->getLocale() at some point 🙈

The phone number is not set because Commerce doesn't have a standardized way to handle it, so any attempt to support it would just be guesswork.

This should be fixed in the latest 3.x and 4.x releases.

kaipipek’s picture

Thank you for the quick fix again!

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.